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

Fix operator in EVENT/UTIL namespaces #66

Merged
merged 1 commit into from
Oct 30, 2019

Conversation

rete
Copy link
Contributor

@rete rete commented Oct 27, 2019

BEGINRELEASENOTES

  • Moved all stream operator overloads of EVENT class types into EVENT namespace (moved out from UTIL namespace)
    ENDRELEASENOTES

@petricm
Copy link
Contributor

petricm commented Oct 28, 2019

Did you recompile all of iLCSoft after this change to see if you break something?

@rete
Copy link
Contributor Author

rete commented Oct 28, 2019

Yes, it doesn't change anything for the current iLCSoft version.

The motivation is for the new streamlog interface. The current logging object in streamlog is std::ostream, but in the new version I use a custom one, derived from std::ostream. In this case I can't print LCIO objects using streamlog.

See: https://stackoverflow.com/questions/3891402/operator-overloading-and-namespaces

The stream operators for a class should be defined in the same namespace as the class definition.

@rete rete merged commit 568e207 into iLCSoft:master Oct 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants