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


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

Re: [v3] concept check macros, excess-errors


[list moved from gcc-pcatches to libstdc++]

On Tue, Apr 17, 2001 at 06:03:30PM -0700, Benjamin Kosnik wrote:
>    Now, _GLIBCPP_CONCEPT_CHECKS means the concept checking code will
>    be exercised. Having it undefined means it's not active. This

Works for me.

> Phil if you'd like to write configure bits to turn on/off the macro
> (and have it off by default), I think this is a good idea.

This was easy, but one thing remains before checkin:

>    In addition, concept checking code in the Makefiles (!) was
>    removed. 
[...]
> *** 306,312 ****
>   # the concept-checking symbols.  So we must disable the checks while
>   # actually building the library.
>   AM_CXXFLAGS = \
> ! 	-fno-implicit-templates -D_GLIBCPP_NO_CONCEPT_CHECKS \
>   	$(LIBSUPCXX_CXXFLAGS) \
>   	$(WARN_CXXFLAGS) \
>   	$(OPTIMIZE_CXXFLAGS) \
> --- 306,312 ----
>   # the concept-checking symbols.  So we must disable the checks while
>   # actually building the library.
>   AM_CXXFLAGS = \
> ! 	-fno-implicit-templates \
>   	$(LIBSUPCXX_CXXFLAGS) \
>   	$(WARN_CXXFLAGS) \
>   	$(OPTIMIZE_CXXFLAGS) \

...when the user configures with --enable-concept-checks, we still need a
way to turn them off while building the library itself.  I have no problem
with not doing this in the makefiles, but we should decide on how.

Maybe the enabling macro test in concept_check.h should be augmented with
something like system.h's IN_GCC macro, signifying that we're not yet in
user-land but still building ourselves.  We haven't needed such a thing yet,
and it'd be nice to keep going without one.

Or put a -D back in the makefile and change the test to

  #if !defined(_GLIBCPP_CONCEPT_CHECKS)
      || defined (NO_WAY_IN_HELL_DO_WE_WANT_THESE_ON_RIGHT_NOW)
  ...empty defines...

Or etc, etc.  Opinions solicited; choose yer poison.  :-)


Phil

-- 
pedwards at disaster dot jaj dot com  |  pme at sources dot redhat dot com
devphil at several other less interesting addresses in various dot domains
The gods do not protect fools.  Fools are protected by more capable fools.


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