C++ Logo

std-proposals

Advanced search

Re: [std-proposals] Supporting f-strings in C++: draft-R1

From: Jens Maurer <jens.maurer_at_[hidden]>
Date: Mon, 16 Oct 2023 19:51:57 +0200
On 16/10/2023 18.10, Hadriel Kaplan wrote:
>> From: Std-Proposals <std-proposals-bounces_at_[hidden]> on behalf of Jens Maurer via Std-Proposals <std-proposals_at_[hidden]>
>
>> In which phase are these F or X strings supposed to be turned into
>> something else that presumably ends up as a phase 7 C++ expression
>> performing some formatting when evaluated?
>
> That is the big question.
>
> Currently the proposal says between phase 6 and 7. But with a note that says: "It may be more appropriate to perform the f/x-string conversion before phase 6, such as immediately following phase 4 preprocessing. (TBD)".
>
> But that was under my assumption we couldn't/shouldn't touch the preprocessor without WG14. If it's really a practical-possibility to modify preprocessing, then this could of course be done in phase 4.

Changing the preprocessor will need more rationale than adding
some syntax elsewhere in the language, but given sufficiently
convincing rationale, we should ignore WG14 for the moment.

However, additional points for showing how these F or X strings
could be useful for C as well.

> There are pro's and con's for pretty much anywhere, I think.
>
> I guess I should just list the pro's and con's that I know of in the proposal, and ask for EWG guidance?

What's the most user-friendly and technically sound solution?
That's what you should propose.

Jens

Received on 2023-10-16 17:52:08