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

Remove std::size_t from all header files. #23

Closed
bmunkholm opened this issue May 1, 2012 · 1 comment
Closed

Remove std::size_t from all header files. #23

bmunkholm opened this issue May 1, 2012 · 1 comment

Comments

@bmunkholm
Copy link
Contributor

Use:
using std::size_t
using std::time_t

@ghost ghost assigned kspangsege May 1, 2012
@kspangsege
Copy link
Contributor

Good looks is less important that correctness.

The problem with not using std::size_t and std::time_t in headers, is that some compilers (including GCC) are lenient in this regard, so if we specify 'using std::size_t' in some header, but forget to include that header in some other header, then there is an error, but the error is probably not reported, and the error is hard to spot, when you are not looking for it.

One solution might be to require that every header, that use size_t, must themselves specify 'using std::size_t'. This can be checked by a script.

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

No branches or pull requests

2 participants