Skip to content

Commit

Permalink
Merge pull request #514 from dartsim/grey/fix_jacobian_final
Browse files Browse the repository at this point in the history
Enable compiler optimization by using 'final' keyword for Jacobian functions
  • Loading branch information
jslee02 committed Oct 5, 2015
2 parents 5ae5de5 + 9fb7d0c commit 26a155b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions dart/dynamics/BodyNode.h
Original file line number Diff line number Diff line change
Expand Up @@ -636,14 +636,14 @@ class BodyNode :

/// Return the generalized Jacobian targeting the origin of this BodyNode. The
/// Jacobian is expressed in the Frame of this BodyNode.
const math::Jacobian& getJacobian() const override;
const math::Jacobian& getJacobian() const override final;

// Prevent the inherited getJacobian functions from being shadowed
using TemplatedJacobianNode<BodyNode>::getJacobian;

/// Return the generalized Jacobian targeting the origin of this BodyNode. The
/// Jacobian is expressed in the World Frame.
const math::Jacobian& getWorldJacobian() const;
const math::Jacobian& getWorldJacobian() const override final;

// Prevent the inherited getWorldJacobian functions from being shadowed
using TemplatedJacobianNode<BodyNode>::getWorldJacobian;
Expand All @@ -656,7 +656,7 @@ class BodyNode :
/// spatial vectors. If you are using classical linear and angular
/// acceleration vectors, then use getJacobianClassicDeriv(),
/// getLinearJacobianDeriv(), or getAngularJacobianDeriv() instead.
const math::Jacobian& getJacobianSpatialDeriv() const override;
const math::Jacobian& getJacobianSpatialDeriv() const override final;

// Prevent the inherited getJacobianSpatialDeriv functions from being shadowed
using TemplatedJacobianNode<BodyNode>::getJacobianSpatialDeriv;
Expand All @@ -668,7 +668,7 @@ class BodyNode :
/// NOTE: Since this is a classical time derivative, it should be used with
/// classical linear and angular vectors. If you are using spatial vectors,
/// use getJacobianSpatialDeriv() instead.
const math::Jacobian& getJacobianClassicDeriv() const override;
const math::Jacobian& getJacobianClassicDeriv() const override final;

// Prevent the inherited getJacobianClassicDeriv functions from being shadowed
using TemplatedJacobianNode<BodyNode>::getJacobianClassicDeriv;
Expand Down
8 changes: 4 additions & 4 deletions dart/dynamics/EndEffector.h
Original file line number Diff line number Diff line change
Expand Up @@ -227,25 +227,25 @@ class EndEffector : public FixedFrame,
//----------------------------------------------------------------------------

// Documentation inherited
const math::Jacobian& getJacobian() const override;
const math::Jacobian& getJacobian() const override final;

// Prevent the inherited getJacobian functions from being shadowed
using TemplatedJacobianNode<EndEffector>::getJacobian;

// Documentation inherited
const math::Jacobian& getWorldJacobian() const override;
const math::Jacobian& getWorldJacobian() const override final;

// Prevent the inherited getWorldJacobian functions from being shadowed
using TemplatedJacobianNode<EndEffector>::getWorldJacobian;

// Documentation inherited
const math::Jacobian& getJacobianSpatialDeriv() const override;
const math::Jacobian& getJacobianSpatialDeriv() const override final;

// Prevent the inherited getJacobianSpatialDeriv functions from being shadowed
using TemplatedJacobianNode<EndEffector>::getJacobianSpatialDeriv;

// Documentation inherited
const math::Jacobian& getJacobianClassicDeriv() const override;
const math::Jacobian& getJacobianClassicDeriv() const override final;

// Prevent the inherited getJacobianClassicDeriv functions from being shadowed
using TemplatedJacobianNode<EndEffector>::getJacobianClassicDeriv;
Expand Down

0 comments on commit 26a155b

Please sign in to comment.