[cfe-dev] [PATCH] MS compatibility flag implies delayed parsing

dawn at burble.org dawn at burble.org
Thu Nov 24 00:06:16 PST 2011


If it's good enough for MSVC compatibility, then it's probably good
enough for Borland's MSVC compatibility mode as well :).  Borland's C++
compiler actually implements a bizzarre combination of delayed and
2-phase lookup (long story).  But in general, it tries to be compatibile
with MSVC, so I'm hoping that being able to set this option independent
of MSVC will be good enough.

-Dawn

On Fri, Nov 18, 2011 at 04:51:28PM -0500, Francois Pichet wrote:
> On Thu, Nov 17, 2011 at 2:46 PM,  <dawn at burble.org> wrote:
> > Please let this be a separate option from the ms-mode option.  See comment
> > below.
> >
> > On Sat, Nov 12, 2011 at 03:08:43PM -0600, Aaron Ballman wrote:
> >> On Tue, Nov 8, 2011 at 8:51 PM, Douglas Gregor <dgregor at apple.com> wrote:
> >> >
> >> > On Nov 8, 2011, at 6:56 AM, Aaron Ballman wrote:
> >> >
> >> >> On Mon, Nov 7, 2011 at 4:55 PM, Eli Friedman <eli.friedman at gmail.com> wrote:
> >> >>> I don't see why the changes to lib/Frontend/CompilerInvocation.cpp and
> >> >>> include/clang/Driver/CC1Options.td are necessary.  The changes to
> >> >>> lib/Driver/Tools.cpp look fine.
> >> >>
> >> >> I'm not certain I understand why the two are separate from one
> >> >> another.  Can you give me a quite education on the topic?
> >> >>
> >> >> On Mon, Nov 7, 2011 at 5:02 PM, Francois Pichet <pichet2000 at gmail.com> wrote:
> >> >>> How about we remove --fdelayed-template-parsing altogether and check
> >> >>> for fms-compatibility to do late template parsing?
> >> >>>
> >> >>> Anybody else needs delayed template parsing without microsoft compatibility?
> >
> > We do!  And we don't want them to be tied to ms-mode, because we want to
> > be able to set ms-mode (to get ms language extensions) but allow 2-phase
> > lookup by default.  For legacy code however, we want to allow users to
> > be able to disable 2-phase lookup.
> 
> Just to be clear, -fdelayed-template-parsing doesn't disable 2-phase
> lookup. It just delay phase 1 lookup until the end of the translation
> unit with the effect of making more symbols available then. In
> practice that's enough to get very good compatibility with MSVC
> template code.



More information about the cfe-dev mailing list