|
[Rivet] Bug: namespace and include pollution in Rivet namespace (minor)Andy Buckley andy.buckley at cern.chTue Sep 30 09:43:11 BST 2014
On 23/07/14 19:53, David Bjergaard wrote: > Hi, > > I know that there are some irregular design considerations to make Rivet > more friendly to non-C++ experts, however these two quirks have been > bothering me, so I'm reporting them. I understand if nothing is done to > change them, I just want them off my conscience: Hi David, Just realised that I never replied to this (it's low priority stuff, as you know!) > 1. Rivet namespace includes 'namespace std' (or at least std::cout and > std::endl) Yep, that is for convenience. As I understand it's up to the "owner" of a given namespace what they put in it -- we aren't polluting anyone else's namespace, and clean code / user convenience is something we put fairly high up the priority list. > 2. assert() can be used without "#include <cassert>" Is that a bad thing? We include it in Rivet/Tools/RivetSTL.hh, along with the various "using std::*". User convenience again. The header chain needs to be cleaned up (any good tools to help with disentangling #include messes?) but that's a separate issue. Andy -- Dr Andy Buckley, Royal Society University Research Fellow Particle Physics Expt Group, University of Glasgow / PH Dept, CERN
More information about the Rivet mailing list |