]> git.madduck.net Git - etc/vim.git/blobdiff - tests/data/fstring.py

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

Prepare release 22.3.0 (#2968)
[etc/vim.git] / tests / data / fstring.py
index b288cbc413003446a1c3c0e82e2616a873b9ae95..4b33231c01c08701c1f2fa47de9cfe8a1f0388c9 100644 (file)
@@ -1,5 +1,21 @@
 f"f-string without formatted values is just a string"
 f"{{NOT a formatted value}}"
+f"{{NOT 'a' \"formatted\" \"value\"}}"
 f"some f-string with {a} {few():.2f} {formatted.values!r}"
-f"{f'{nested} inner'} outer"
+f'some f-string with {a} {few(""):.2f} {formatted.values!r}'
+f"{f'''{'nested'} inner'''} outer"
+f"\"{f'{nested} inner'}\" outer"
 f"space between opening braces: { {a for a in (1, 2, 3)}}"
+f'Hello \'{tricky + "example"}\''
+
+# output
+
+f"f-string without formatted values is just a string"
+f"{{NOT a formatted value}}"
+f'{{NOT \'a\' "formatted" "value"}}'
+f"some f-string with {a} {few():.2f} {formatted.values!r}"
+f'some f-string with {a} {few(""):.2f} {formatted.values!r}'
+f"{f'''{'nested'} inner'''} outer"
+f"\"{f'{nested} inner'}\" outer"
+f"space between opening braces: { {a for a in (1, 2, 3)}}"
+f'Hello \'{tricky + "example"}\''