Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 12 Nov 2013 22:46:38 +0100
From:      Dimitry Andric <dim@FreeBSD.org>
To:        Tijl Coosemans <tijl@coosemans.org>
Cc:        freebsd-current@FreeBSD.org, David Chisnall <theraven@FreeBSD.org>, Steve Kargl <sgk@troutmask.apl.washington.edu>
Subject:   Re: Are clang++ and libc++ compatible?
Message-ID:  <9169A1F8-5773-459F-9763-5B50B4452D16@FreeBSD.org>
In-Reply-To: <20131112221946.78602db0@kalimero.tijl.coosemans.org>
References:  <20131112163219.GA2834@troutmask.apl.washington.edu> <77CB2B92-216A-4C80-B033-7E582B5F0DFC@FreeBSD.org> <20131112165422.GA2939@troutmask.apl.washington.edu> <E0FE40D9-726C-4501-B31A-3622510C1C68@FreeBSD.org> <20131112175556.GA3319@troutmask.apl.washington.edu> <20131112201922.GA4330@troutmask.apl.washington.edu> <20131112221946.78602db0@kalimero.tijl.coosemans.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--Apple-Mail=_71532245-877E-43D3-8257-567251A582E0
Content-Transfer-Encoding: 7bit
Content-Type: text/plain;
	charset=us-ascii

On 12 Nov 2013, at 22:19, Tijl Coosemans <tijl@coosemans.org> wrote:
...
There's a similar problem with graphics/blender.  There's a class
> TreeElement which links to its parent TreeElement like this:
> 
> std::map<std::string, TreeElement>::const_iterator parent;
> 
> Works with libstdc++, fails with libc++.  If the standard doesn't
> specify this it would still be a very convenient extension.

The standard explicitly says this is undefined, except for a few
specific (non-container) classes in C++11.  So to write portable code,
you should not rely on this "feature" to be available.

Besides, it is relatively easy to work around.  Except for the case of
pan, where it is abused all over the place, and it seems tricky to fix
without overhauling a lot of code... :-/

-Dimitry


--Apple-Mail=_71532245-877E-43D3-8257-567251A582E0
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename=signature.asc
Content-Type: application/pgp-signature;
	name=signature.asc
Content-Description: Message signed with OpenPGP using GPGMail

-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.22 (Darwin)

iEYEARECAAYFAlKCocYACgkQsF6jCi4glqMnXwCfebZAyTrZDE6onQPIYv4yCZMq
9mQAoIMVXZCILkkytPfWvlOGMoTSBRh/
=l7hj
-----END PGP SIGNATURE-----

--Apple-Mail=_71532245-877E-43D3-8257-567251A582E0--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?9169A1F8-5773-459F-9763-5B50B4452D16>