[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: insert-header-preprocessor-definition
From: |
Emanuel Berg |
Subject: |
Re: insert-header-preprocessor-definition |
Date: |
Sun, 15 Apr 2018 21:46:56 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux) |
Yuri Khan wrote:
> The practical solution is, of course, the
> same as with all name conflict issues:
> Namespacing. That is, in your project, you
> start all preprocessor defines with the name
> of your project.
Woah, is *that* what people mean with
"namespacing"? I thought that was something
more advanced!
I remember people using it in C++ and I removed
it telling everyone it was a bad idea and
instead one should use the whole path to
identify things.
Looking back y'all, I don't know if that was
the right thing to say/do, but what I remember
everyone did it and in the end the software
worked :)
But that was not namespacing in this sense,
which is rather a naming convention, like
a poor-man's Hungarian notation or actually
what we do in Elisp all the time!
Maybe the supposedly "advanced" C++ way is
actually nothing more than syntax to automate
this and make people confused at the same time?
> On the other hand, the two or three compilers
> out there that are most likely to be used to
> compile your project already support
> #pragma once.
I'm on gcc 4.9. Should I get away with the
guards and use '#pragma once' instead?
--
underground experts united
http://user.it.uu.se/~embe8573
- Re: insert-header-preprocessor-definition, (continued)
- Re: insert-header-preprocessor-definition, Ben Bacarisse, 2018/04/11
- Re: insert-header-preprocessor-definition, Emanuel Berg, 2018/04/11
- Re: insert-header-preprocessor-definition, Ben Bacarisse, 2018/04/11
- Re: insert-header-preprocessor-definition, Emanuel Berg, 2018/04/11
- Re: insert-header-preprocessor-definition, Emanuel Berg, 2018/04/14
- Re: insert-header-preprocessor-definition, Ben Bacarisse, 2018/04/14
- Re: insert-header-preprocessor-definition, Yuri Khan, 2018/04/15
- Re: insert-header-preprocessor-definition, Emanuel Berg, 2018/04/15
- Re: insert-header-preprocessor-definition, Ben Bacarisse, 2018/04/15
- Re: insert-header-preprocessor-definition, Emanuel Berg, 2018/04/15
- Message not available
- Re: insert-header-preprocessor-definition,
Emanuel Berg <=
- Re: insert-header-preprocessor-definition, Yuri Khan, 2018/04/16
- Message not available
- Re: insert-header-preprocessor-definition, Emanuel Berg, 2018/04/16