This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFC] fold Reorganization Plan


Mark Mitchell writes:
 >  > 
 > 1. Front ends should build up trees, calling fold only when/if they 
 > want.  For example, in C++, we would want to call fold when we finish 
 > processing an "integral constant expression", which is a term of art in 
 > C++.  (Though that operation would be recursive, that doesn't say 
 > anything about whether or not the code in fold.c must be recursive.  The 
 > C++ front end can always handle the recursion itself, if it so desires.)

There's one other thing to bear in mind when considering the way that
fold relates to language front ends.  We've seen problems in Java
where fold() returned tree nodes that Java didn't recognize: one time,
for example, it returned a BITFIELD_EXPR.

Andrew.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]