Skip to content

Reduce the use of std::shared_ptr<> where possible #23

@maxwellpirtle

Description

@maxwellpirtle

We use the C++11 std::shared_ptr<T> templated type to achieve some level of automatic reference counting. While storing references to transitions and objects benefits from the use of shared pointer, we should eliminate passing shared pointers, where possible, as arguments to functions and methods and instead pass the raw value directly. This will make the function declarations smaller and reduce any unnecessary reference counting inside each of the function calls. Furthermore, dereferencing the shared pointers requires one or two extra steps of indirection which would be avoided with raw pointers

Metadata

Metadata

Assignees

No one assigned

    Labels

    effort: 3Requires average effort to completepriority: soonUse for urgent problemstype: performance-improvementThe issue, when solved, comes with a performance boostwork: complicatedCynefin complicated: the work involves problems without necessarily one preferred method

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions