Boost logo

Boost :

From: Iain K. Hanson (ikh_at_[hidden])
Date: 2005-04-30 19:39:02


Hi Eric,

On Sat, Apr 30, 2005 at 10:24:20AM -0700, Eric Niebler wrote:
> Iain K. Hanson wrote:
> >
> > I really don't like macros.
>
>
> Can you say why? I ask only because FOREACH doesn't suffer from many of
> the problems macros typically suffer from.
>
I'm aware of how funcky the work you have done in C++ inside foreach is. I
followed the work of you and Dave and Jonathan to try to detect lvalues
and rvalues at compile time. I dislike macros not just because of side
effects ( and I take your word that this is safe and side-effect free ) but
because they obscifate code. II have seen far too much code that is very hard
to understand because of macros.

If we accept a macro as a lib into boost we are sending a message to the C++
community that macros are o.k. Not only that but we are effective extending
the language. And where do we stop. Why not accept awk, perl, and python
scripts to re-write our programs. I see little difference.
 
>
> > I have a hard time accepting boost PP but at
> > least we have never before used macros in a way that means that they proliferate
> > into user code.
> >
> > I can not see why this has even come up for formal review.
>
>
> Because a number of people have found it useful.
>
>
> > If this is auseful
> > feature then surely it should be taken up as a core language feature.
>
>
> FOREACH is useful /today/.

No matter how useful, we are condoneing textual re-writing of our code.
>
>
> >
> > I would not have such a problem if we had an experimental track and then people
> > could try ideas before making a proposal.
>
>
> We do. It's called boost-sandbox. Many of the reviewers have been using
> FOREACH for a year or more. The code has been publically available in
> one form or another since 2003.
>
Yep. But now FOREACH is up for review into the main part of boost. The IETF
have an experimental track for RFC's so nobody can confuse something
experimental with standards track protocols. boost does not have this.

This will be the first time we accept a macro into boost ( aside from boost PP)
and I just think this sends the wrong message.

Thanks for your reply and I do appreciate the work you do for boost.

/ikh


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk