C++ Logo

sg16

Advanced search

Re: Request for discussion on C++ synchronization with WG 14 N3145: $ in Identifiers

From: Jens Maurer <jens.maurer_at_[hidden]>
Date: Thu, 6 Jul 2023 09:20:46 +0200
On 06/07/2023 00.01, Steve Downey via SG16 wrote:
> My understanding is that it is now implementation defined if $ is in the identifier set, after having been removed entirely.
> See https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3145.pdf <https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3145.pdf>

Ah, that's different, and apparently that was a difference between C and C++
ever since, because C always allowed additional identifier characters and
C++ didn't.

So, "keeping in sync" actually means "make C++ converge on long-standing
C rules" for identifier characters.

Jens


> On Wed, Jul 5, 2023, 12:28 Hubert Tong via SG16 <sg16_at_[hidden] <mailto:sg16_at_[hidden]>> wrote:
>
> We adopted, in Varna, a paper that adds $ to the basic character set. The week after, the C committee decided (for the C23 DIS) that $ can be used within identifiers (including in the initial position).
>
> We should consider keeping C and C++ in sync.
>
> Note that we already have examples of u"text", etc. where identifier non-digits form the initial portion of non-identifier pp-tokens.
>
> -- HT
>
> --
> SG16 mailing list
> SG16_at_[hidden] <mailto:SG16_at_[hidden]>
> https://lists.isocpp.org/mailman/listinfo.cgi/sg16 <https://lists.isocpp.org/mailman/listinfo.cgi/sg16>
>
>

Received on 2023-07-06 07:20:52