{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "6a70904e-dbfe-441c-99ec-12e6cf57f8ba",
   "metadata": {},
   "outputs": [],
   "source": [
    "async def elements(n): yield n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "5412fc2f-76eb-42c0-8db1-b5af6fdc46aa",
   "metadata": {},
   "outputs": [],
   "source": [
    "[x async for x in elements(5)]  # okay, async at top level"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "dc3c94a7-2e64-42de-9351-260b3f41c3fd",
   "metadata": {
    "scrolled": true
   },
   "outputs": [],
   "source": [
    "[[x async for x in elements(5)] for i in range(5)]  # error on 3.10, okay after"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.10.16"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
