]> git.madduck.net Git - etc/vim.git/blobdiff - tests/data/python37.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:

Add compatible configuration files. (psf#1789) (#1792)
[etc/vim.git] / tests / data / python37.py
index ae20ade097dc4a4226174d588188575a9e66672d..dab8b404a739c57f5258694e28ebe65bd9714462 100644 (file)
@@ -1,7 +1,34 @@
 #!/usr/bin/env python3.7
 
+
 def f():
-    return (i*2 async for i in arange(42))
+    return (i * 2 async for i in arange(42))
+
+
+def g():
+    return (
+        something_long * something_long
+        async for something_long in async_generator(with_an_argument)
+    )
+
+
+async def func():
+    if test:
+        out_batched = [
+            i
+            async for i in aitertools._async_map(
+                self.async_inc, arange(8), batch_size=3
+            )
+        ]
+
+
+def awaited_generator_value(n):
+    return (await awaitable for awaitable in awaitable_list)
+
+
+def make_arange(n):
+    return (i * 2 for i in range(n) if await wrap(i))
+
 
 # output
 
@@ -11,3 +38,28 @@ def f():
 
 def f():
     return (i * 2 async for i in arange(42))
+
+
+def g():
+    return (
+        something_long * something_long
+        async for something_long in async_generator(with_an_argument)
+    )
+
+
+async def func():
+    if test:
+        out_batched = [
+            i
+            async for i in aitertools._async_map(
+                self.async_inc, arange(8), batch_size=3
+            )
+        ]
+
+
+def awaited_generator_value(n):
+    return (await awaitable for awaitable in awaitable_list)
+
+
+def make_arange(n):
+    return (i * 2 for i in range(n) if await wrap(i))