PEP 750: Tag Strings For Writing Domain-Specific Languages

If introduce backtick, please support multiline string with dedent.

Main problem with d-string is it making string prefix and lexer too complex.
So new string quote is very important chance to introduce new multiline string behavior.

    body = ```
        <body>
        <div>hello</div>
        </body>
    ```
  • First newline right after ``` is dropped.
  • Minimum common indent is stripped. In this example, last line (closing ```) indicates how many indent is removed.
6 Likes