[cfe-dev] On the preferred use of C++ in the clang source code
Michael Marcin
mmarcin at method-solutions.com
Thu Jan 3 16:19:35 PST 2008
Chris Lattner wrote:
> On Nov 9, 2007, at 8:55 AM, James Widman wrote:
>
>> I've heard that clang is meant to be implemented in a "subset of C+
>> +" (which I guess means that some core language features are barred
>> from use).
>>
>> Is there a document anywhere that describes and motivates that subset?
>
> It is pretty subjective. We do use almost all C++ features somewhere
> in the (greater llvm) code base. It's really more about making clear
> and simple code than it is about banning specific language features.
> Some coding guidelines are available here:
> http://llvm.org/docs/CodingStandards.html
>
> That said, there are two features we don't like: RTTI and EH. This
> is because they violate the "don't pay for it if you don't use it"
> principle.
Is this violation intrinsic to the concepts and requirements of RTTI
and/or EH or is this an implementation issue?
I have no personal attachment to RTTI but EH and its associated safety
guarantees allow me to read, write and reason about code much better.
If these /are/ implementation issues does CLang plan to do better in its
C++ implementation?
Thanks,
Michael Marcin
P.S. Sorry for dredging up such an old post but I'm really behind
reading this list :)
More information about the cfe-dev
mailing list