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

Minor QOL fixes #34

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Minor QOL fixes #34

wants to merge 2 commits into from

Conversation

nappa85
Copy link

@nappa85 nappa85 commented Jan 12, 2022

Those changes aren't groundbreaking.
One avoids allocating a new String every time a Network is converted to his string representation, a user can always call to_owned or clone on the static string to get the owned String.
The other one returns a reference to Network instead of copying it every time, I feel this is more correct since, for example, constants::hrp asks for a reference, therefore we can short circuit the two things without creating a temporary reference to a temporary copy only for this

Copy link
Member

@clarkmoody clarkmoody left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These look good to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants