You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Currently, the delimiters for multiline strings are m%"/"%m (or with more consecutive %, as long as the numbers of % of the opening and the closing delimiter match).
Repeating the m is not very useful (having the % is though, to avoid having to escape " inside multiline strings). New team members also sometimes didn't remember if the closing delimiters were "%m or "m%.
This syntax scheme also doesn't scale well for other type of strings: we can imagine having raw strings at some point, using the same scheme r%", but also language-specific strings to enable highlighting in the editor, such as cpp-lang%", as well as another multicharacters delimiter with #948. With several alphanumeric characters in the delimiter, this scheme becomes really clunky.
Describe the solution you'd like
For multiline strings, and all future special strings literals, have the same closing delimiter "% or "%...%, dropping the m. This is backward-incompatible. We could still allow both "%m and "% to remedy this, but honestly we're at a stage were we can afford to do such breaking changes, and this will prove much better in the long term than having to put up with a legacy alternative syntax.
For the record, this what Rust does with raw strings r#"..."#, as well as C++ (where you don't have to repeat the R or the u8 at the end of special strings).
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
Currently, the delimiters for multiline strings are
m%"
/"%m
(or with more consecutive%
, as long as the numbers of%
of the opening and the closing delimiter match).Repeating the
m
is not very useful (having the%
is though, to avoid having to escape"
inside multiline strings). New team members also sometimes didn't remember if the closing delimiters were"%m
or"m%
.This syntax scheme also doesn't scale well for other type of strings: we can imagine having raw strings at some point, using the same scheme
r%"
, but also language-specific strings to enable highlighting in the editor, such ascpp-lang%"
, as well as another multicharacters delimiter with #948. With several alphanumeric characters in the delimiter, this scheme becomes really clunky.Describe the solution you'd like
For multiline strings, and all future special strings literals, have the same closing delimiter
"%
or"%...%
, dropping them
. This is backward-incompatible. We could still allow both"%m
and"%
to remedy this, but honestly we're at a stage were we can afford to do such breaking changes, and this will prove much better in the long term than having to put up with a legacy alternative syntax.For the record, this what Rust does with raw strings
r#"..."#
, as well as C++ (where you don't have to repeat theR
or theu8
at the end of special strings).The text was updated successfully, but these errors were encountered: