Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass shared PietText by ref instead of cloning #1205

Merged
merged 1 commit into from
Sep 9, 2020
Merged

Commits on Sep 9, 2020

  1. Pass shared PietText by ref instead of cloning

    Currently we create a copy of the PietText object every time we
    need one. This changes that so that there is a single instance
    in the ContextState, and the various contexts just pass out
    a reference to this object as needed.
    
    This should have few practical implications, except that in
    trees with lots of text we will save a few microseconds. It's
    mostly an API improvement, since the methods that tend to use
    a PietText object generally want it passed by ref anyway.
    cmyr committed Sep 9, 2020
    Configuration menu
    Copy the full SHA
    7046fa9 View commit details
    Browse the repository at this point in the history