|
Boost : |
From: Tobias Schwinger (tschwinger_at_[hidden])
Date: 2005-07-16 09:53:45
Does the macro's name describe what the macro generates (e.g.
BOOST_XYZ_EXPRESSION) or does the macro's name describe a purpose (e.g.
BOOST_REGISTER_XYZ)?
Name describes expansion : semicolon must not be added by the user
Name describes purpose : semicolon must be added by the user
It indirectly depends on the design of the particular library:
If you want the user to look at the macro as part of the interface use "purpose
naming" (imperative) and have the user supply a semicolon.
If you want the user to look at the macro as a code generator (e.g.
convenience-shortcuts with a documented alternative that could be written
manually) use "expansion naming" (noun/perfect) and put the semicolon inside the
macro.
Regards,
Tobias
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk