[prev in list] [next in list] [prev in thread] [next in thread]
List: cfe-dev
Subject: Re: [cfe-dev] integer constant expression oh my!
From: "Nuno Lopes" <nunoplopes () sapo ! pt>
Date: 2008-11-18 16:38:23
Message-ID: B61F30AA968E4F2BBC21101D95FF8134 () pc07654
[Download RAW message or body]
> On Sun, Nov 16, 2008 at 1:51 PM, Chris Lattner <clattner@apple.com> wrote:
>> I wrote up some thoughts about how I think that constants should
>> eventually be handled in clang:
>> http://clang.llvm.org/docs/InternalsManual.html#Constants
>>
>> The goal is for Expr::isConstantExpr and many other things to
>> eventually go away, and only have one piece of code that does the
>> constant folding tree walk. Before we get too far along this path, I
>> thought it would be good to see if this makes sense to others... so,
>> what say you all? :)
This is great as it's horrible to find the same bug over and over again in
slightly different places because the code is duplicated.
One thing I would like to add (that I was discussing yesterday in IRC) is a
Expr::EvaluateToBool() (just export the HandleConversionToBool() from
ExprConstant.cpp). This function is important to fix a few bugs in codegen
and sema. What do you think?
Nuno
_______________________________________________
cfe-dev mailing list
cfe-dev@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic