shellsim 0.1.20__tar.gz → 0.1.22__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (318) hide show
  1. {shellsim-0.1.20 → shellsim-0.1.22}/Cargo.lock +3 -1
  2. {shellsim-0.1.20 → shellsim-0.1.22}/Cargo.toml +3 -1
  3. {shellsim-0.1.20 → shellsim-0.1.22}/PKG-INFO +3 -3
  4. {shellsim-0.1.20 → shellsim-0.1.22}/README.md +1 -1
  5. {shellsim-0.1.20 → shellsim-0.1.22}/pyproject.toml +2 -2
  6. {shellsim-0.1.20 → shellsim-0.1.22}/python/native/Cargo.lock +4 -2
  7. {shellsim-0.1.20 → shellsim-0.1.22}/python/native/Cargo.toml +1 -1
  8. {shellsim-0.1.20 → shellsim-0.1.22}/python/shellsim/_api.py +1 -1
  9. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/ast.rs +13 -1
  10. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/bytecode.rs +74 -16
  11. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/compiler.rs +193 -112
  12. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/complex.rs +67 -163
  13. shellsim-0.1.22/src/python/cpython_names.rs +505 -0
  14. shellsim-0.1.22/src/python/exception_types.rs +197 -0
  15. shellsim-0.1.22/src/python/float_text.rs +144 -0
  16. shellsim-0.1.22/src/python/hash.rs +273 -0
  17. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/heap.rs +257 -48
  18. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/lexer.rs +128 -23
  19. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/mapping.rs +32 -6
  20. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/mod.rs +99 -175
  21. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/native.rs +412 -93
  22. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/number.rs +759 -67
  23. shellsim-0.1.22/src/python/object_model.rs +1947 -0
  24. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/parser.rs +371 -75
  25. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/protocol.rs +394 -136
  26. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/slice.rs +43 -23
  27. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/core.rs +2443 -430
  28. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/enum.rs +2 -2
  29. shellsim-0.1.22/src/python/stdlib/frozen.rs +106 -0
  30. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/importlib.rs +17 -2
  31. shellsim-0.1.22/src/python/stdlib/introspect.rs +52 -0
  32. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/json.rs +52 -13
  33. shellsim-0.1.22/src/python/stdlib/mapping_views.rs +464 -0
  34. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/math.rs +407 -5
  35. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/mod.rs +24 -2
  36. shellsim-0.1.22/src/python/stdlib/numpy/args.rs +318 -0
  37. shellsim-0.1.22/src/python/stdlib/numpy/array.rs +646 -0
  38. shellsim-0.1.22/src/python/stdlib/numpy/construct.rs +739 -0
  39. shellsim-0.1.22/src/python/stdlib/numpy/convert.rs +829 -0
  40. shellsim-0.1.22/src/python/stdlib/numpy/dtype.rs +776 -0
  41. shellsim-0.1.22/src/python/stdlib/numpy/dtype_object.rs +259 -0
  42. shellsim-0.1.22/src/python/stdlib/numpy/element.rs +601 -0
  43. shellsim-0.1.22/src/python/stdlib/numpy/errstate.rs +73 -0
  44. shellsim-0.1.22/src/python/stdlib/numpy/format.rs +152 -0
  45. shellsim-0.1.22/src/python/stdlib/numpy/index.rs +716 -0
  46. shellsim-0.1.22/src/python/stdlib/numpy/io.rs +215 -0
  47. shellsim-0.1.22/src/python/stdlib/numpy/layout.rs +255 -0
  48. shellsim-0.1.22/src/python/stdlib/numpy/linalg/dense.rs +1585 -0
  49. shellsim-0.1.22/src/python/stdlib/numpy/linalg.rs +846 -0
  50. shellsim-0.1.22/src/python/stdlib/numpy/math.rs +188 -0
  51. shellsim-0.1.22/src/python/stdlib/numpy/mod.rs +429 -0
  52. shellsim-0.1.22/src/python/stdlib/numpy/ndarray.rs +968 -0
  53. shellsim-0.1.22/src/python/stdlib/numpy/ops.rs +1138 -0
  54. shellsim-0.1.22/src/python/stdlib/numpy/products.rs +625 -0
  55. shellsim-0.1.22/src/python/stdlib/numpy/random/bitgen.rs +85 -0
  56. shellsim-0.1.22/src/python/stdlib/numpy/random/discrete.rs +242 -0
  57. shellsim-0.1.22/src/python/stdlib/numpy/random/gamma.rs +85 -0
  58. shellsim-0.1.22/src/python/stdlib/numpy/random/integers.rs +41 -0
  59. shellsim-0.1.22/src/python/stdlib/numpy/random/normal.rs +32 -0
  60. shellsim-0.1.22/src/python/stdlib/numpy/random/sequence.rs +45 -0
  61. shellsim-0.1.22/src/python/stdlib/numpy/random.rs +422 -0
  62. shellsim-0.1.22/src/python/stdlib/numpy/reduce.rs +1607 -0
  63. shellsim-0.1.22/src/python/stdlib/numpy/scalar.rs +803 -0
  64. shellsim-0.1.22/src/python/stdlib/numpy/select.rs +264 -0
  65. shellsim-0.1.22/src/python/stdlib/numpy/shape/broadcast.rs +74 -0
  66. shellsim-0.1.22/src/python/stdlib/numpy/shape/diagonal.rs +116 -0
  67. shellsim-0.1.22/src/python/stdlib/numpy/shape/join.rs +200 -0
  68. shellsim-0.1.22/src/python/stdlib/numpy/shape/repeat.rs +134 -0
  69. shellsim-0.1.22/src/python/stdlib/numpy/shape.rs +601 -0
  70. shellsim-0.1.22/src/python/stdlib/numpy/sort/bincount.rs +107 -0
  71. shellsim-0.1.22/src/python/stdlib/numpy/sort/search.rs +214 -0
  72. shellsim-0.1.22/src/python/stdlib/numpy/sort.rs +1003 -0
  73. shellsim-0.1.22/src/python/stdlib/numpy/ufunc/masked.rs +136 -0
  74. shellsim-0.1.22/src/python/stdlib/numpy/ufunc.rs +2732 -0
  75. shellsim-0.1.22/src/python/stdlib/numpy/underflow.rs +96 -0
  76. shellsim-0.1.22/src/python/stdlib/operator.rs +47 -0
  77. shellsim-0.1.22/src/python/stdlib/pytest.rs +48 -0
  78. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/re.rs +20 -2
  79. shellsim-0.1.22/src/python/stdlib/scipy/mod.rs +25 -0
  80. shellsim-0.1.22/src/python/stdlib/scipy/special/erf.rs +259 -0
  81. shellsim-0.1.22/src/python/stdlib/scipy/special/gamma.rs +235 -0
  82. shellsim-0.1.22/src/python/stdlib/scipy/special/ibeta.rs +267 -0
  83. shellsim-0.1.22/src/python/stdlib/scipy/special/igam.rs +244 -0
  84. shellsim-0.1.22/src/python/stdlib/scipy/special/meter.rs +94 -0
  85. shellsim-0.1.22/src/python/stdlib/scipy/special/mod.rs +249 -0
  86. shellsim-0.1.22/src/python/stdlib/scipy/special/zeta.rs +72 -0
  87. shellsim-0.1.22/src/python/stdlib/source/collections.py +386 -0
  88. shellsim-0.1.22/src/python/stdlib/source/contextlib.py +173 -0
  89. shellsim-0.1.22/src/python/stdlib/source/fractions.py +362 -0
  90. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/importlib.py +24 -3
  91. shellsim-0.1.22/src/python/stdlib/source/inspect.py +190 -0
  92. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/io.py +88 -19
  93. shellsim-0.1.22/src/python/stdlib/source/keyword.py +54 -0
  94. shellsim-0.1.22/src/python/stdlib/source/numpy/__init__.py +312 -0
  95. shellsim-0.1.22/src/python/stdlib/source/numpy/_creation.py +552 -0
  96. shellsim-0.1.22/src/python/stdlib/source/numpy/_errors.py +262 -0
  97. shellsim-0.1.22/src/python/stdlib/source/numpy/_io.py +575 -0
  98. shellsim-0.1.22/src/python/stdlib/source/numpy/_math.py +975 -0
  99. shellsim-0.1.22/src/python/stdlib/source/numpy/_printing.py +704 -0
  100. shellsim-0.1.22/src/python/stdlib/source/numpy/_products.py +274 -0
  101. shellsim-0.1.22/src/python/stdlib/source/numpy/_sets.py +173 -0
  102. shellsim-0.1.22/src/python/stdlib/source/numpy/_shapes.py +629 -0
  103. shellsim-0.1.22/src/python/stdlib/source/numpy/_stats.py +507 -0
  104. shellsim-0.1.22/src/python/stdlib/source/numpy/exceptions.py +38 -0
  105. shellsim-0.1.22/src/python/stdlib/source/numpy/fft.py +426 -0
  106. shellsim-0.1.22/src/python/stdlib/source/numpy/linalg.py +706 -0
  107. shellsim-0.1.22/src/python/stdlib/source/numpy/random.py +668 -0
  108. shellsim-0.1.22/src/python/stdlib/source/numpy/testing.py +243 -0
  109. shellsim-0.1.22/src/python/stdlib/source/operator.py +364 -0
  110. shellsim-0.1.22/src/python/stdlib/source/pytest.py +243 -0
  111. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/random.py +69 -0
  112. shellsim-0.1.22/src/python/stdlib/source/scipy/__init__.py +17 -0
  113. shellsim-0.1.22/src/python/stdlib/source/scipy/integrate.py +659 -0
  114. shellsim-0.1.22/src/python/stdlib/source/scipy/interpolate.py +826 -0
  115. shellsim-0.1.22/src/python/stdlib/source/scipy/linalg.py +793 -0
  116. shellsim-0.1.22/src/python/stdlib/source/scipy/optimize.py +625 -0
  117. shellsim-0.1.22/src/python/stdlib/source/scipy/spatial/__init__.py +10 -0
  118. shellsim-0.1.22/src/python/stdlib/source/scipy/spatial/distance.py +455 -0
  119. shellsim-0.1.22/src/python/stdlib/source/scipy/special.py +364 -0
  120. shellsim-0.1.22/src/python/stdlib/source/scipy/stats/__init__.py +65 -0
  121. shellsim-0.1.22/src/python/stdlib/source/scipy/stats/_describe.py +359 -0
  122. shellsim-0.1.22/src/python/stdlib/source/scipy/stats/_distributions.py +625 -0
  123. shellsim-0.1.22/src/python/stdlib/source/scipy/stats/_tests.py +279 -0
  124. shellsim-0.1.22/src/python/stdlib/source/warnings.py +284 -0
  125. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/zipfile.py +46 -16
  126. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/sys.rs +49 -5
  127. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/typing.rs +40 -2
  128. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/unittest.rs +43 -3
  129. shellsim-0.1.22/src/python/stdlib/warnings.rs +35 -0
  130. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/string.rs +5 -1
  131. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/token.rs +3 -0
  132. shellsim-0.1.22/src/python/unicode/tables.rs +2519 -0
  133. shellsim-0.1.22/src/python/unicode.rs +234 -0
  134. shellsim-0.1.22/src/python/vm/calls.rs +2199 -0
  135. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/vm/dispatch.rs +109 -4
  136. shellsim-0.1.22/src/python/vm/equality.rs +277 -0
  137. shellsim-0.1.22/src/python/vm/format.rs +744 -0
  138. shellsim-0.1.22/src/python/vm/hashing.rs +216 -0
  139. shellsim-0.1.22/src/python/vm/iteration.rs +1047 -0
  140. shellsim-0.1.22/src/python/vm/mappings.rs +52 -0
  141. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/vm/namespace.rs +413 -199
  142. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/vm/native_runtime.rs +801 -214
  143. shellsim-0.1.22/src/python/vm/objects.rs +4243 -0
  144. shellsim-0.1.22/src/python/vm/operations.rs +953 -0
  145. shellsim-0.1.22/src/python/vm/summation.rs +187 -0
  146. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/vm.rs +310 -121
  147. {shellsim-0.1.20 → shellsim-0.1.22}/src/resources.rs +1 -1
  148. shellsim-0.1.20/src/python/object_model.rs +0 -1113
  149. shellsim-0.1.20/src/python/stdlib/frozen.rs +0 -49
  150. shellsim-0.1.20/src/python/stdlib/numpy.rs +0 -5122
  151. shellsim-0.1.20/src/python/stdlib/pytest.rs +0 -100
  152. shellsim-0.1.20/src/python/stdlib/source/collections.py +0 -181
  153. shellsim-0.1.20/src/python/stdlib/source/numpy_random.py +0 -99
  154. shellsim-0.1.20/src/python/stdlib/source/pytest.py +0 -36
  155. shellsim-0.1.20/src/python/vm/calls.rs +0 -1603
  156. shellsim-0.1.20/src/python/vm/format.rs +0 -352
  157. shellsim-0.1.20/src/python/vm/iteration.rs +0 -470
  158. shellsim-0.1.20/src/python/vm/objects.rs +0 -2090
  159. shellsim-0.1.20/src/python/vm/operations.rs +0 -461
  160. {shellsim-0.1.20 → shellsim-0.1.22}/LICENSE +0 -0
  161. {shellsim-0.1.20 → shellsim-0.1.22}/python/native/src/lib.rs +0 -0
  162. {shellsim-0.1.20 → shellsim-0.1.22}/python/shellsim/__init__.py +0 -0
  163. {shellsim-0.1.20 → shellsim-0.1.22}/python/shellsim/__main__.py +0 -0
  164. {shellsim-0.1.20 → shellsim-0.1.22}/python/shellsim/_cli.py +0 -0
  165. {shellsim-0.1.20 → shellsim-0.1.22}/python/shellsim/py.typed +0 -0
  166. {shellsim-0.1.20 → shellsim-0.1.22}/python/shellsim/python.py +0 -0
  167. {shellsim-0.1.20 → shellsim-0.1.22}/rust-toolchain.toml +0 -0
  168. {shellsim-0.1.20 → shellsim-0.1.22}/src/arith.rs +0 -0
  169. {shellsim-0.1.20 → shellsim-0.1.22}/src/bin/shellsim-python.rs +0 -0
  170. {shellsim-0.1.20 → shellsim-0.1.22}/src/clock.rs +0 -0
  171. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/archives.rs +0 -0
  172. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/arcmd.rs +0 -0
  173. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/awk/ast.rs +0 -0
  174. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/awk/eval.rs +0 -0
  175. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/awk/lexer.rs +0 -0
  176. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/awk/parser.rs +0 -0
  177. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/awk.rs +0 -0
  178. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/bc.rs +0 -0
  179. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/builtins.rs +0 -0
  180. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/dd.rs +0 -0
  181. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/diff.rs +0 -0
  182. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/echo.rs +0 -0
  183. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/expr.rs +0 -0
  184. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/find.rs +0 -0
  185. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/format.rs +0 -0
  186. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/fs.rs +0 -0
  187. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/apply.rs +0 -0
  188. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/commit.rs +0 -0
  189. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/compare.rs +0 -0
  190. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/config.rs +0 -0
  191. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/conflict.rs +0 -0
  192. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/diff.rs +0 -0
  193. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/ignore.rs +0 -0
  194. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/import.rs +0 -0
  195. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/log.rs +0 -0
  196. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/merge.rs +0 -0
  197. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/mod.rs +0 -0
  198. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/plumbing.rs +0 -0
  199. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/rebase.rs +0 -0
  200. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/refs.rs +0 -0
  201. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/repo.rs +0 -0
  202. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/stash.rs +0 -0
  203. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/switch.rs +0 -0
  204. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/git/worktree.rs +0 -0
  205. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/grep.rs +0 -0
  206. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/hashing.rs +0 -0
  207. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/makecmd.rs +0 -0
  208. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/mod.rs +0 -0
  209. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/net.rs +0 -0
  210. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/options.rs +0 -0
  211. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/patch.rs +0 -0
  212. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/pkg.rs +0 -0
  213. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/printf.rs +0 -0
  214. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/proc.rs +0 -0
  215. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/regex_compat.rs +0 -0
  216. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/rgcmd.rs +0 -0
  217. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/sed.rs +0 -0
  218. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/sort.rs +0 -0
  219. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/streams.rs +0 -0
  220. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/system.rs +0 -0
  221. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/tarcmd.rs +0 -0
  222. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/text.rs +0 -0
  223. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/unavailable.rs +0 -0
  224. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/util.rs +0 -0
  225. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/wasm.rs +0 -0
  226. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/xargs.rs +0 -0
  227. {shellsim-0.1.20 → shellsim-0.1.22}/src/commands/zipcmd.rs +0 -0
  228. {shellsim-0.1.20 → shellsim-0.1.22}/src/corpus.rs +0 -0
  229. {shellsim-0.1.20 → shellsim-0.1.22}/src/descriptors.rs +0 -0
  230. {shellsim-0.1.20 → shellsim-0.1.22}/src/display.rs +0 -0
  231. {shellsim-0.1.20 → shellsim-0.1.22}/src/exec.rs +0 -0
  232. {shellsim-0.1.20 → shellsim-0.1.22}/src/expand.rs +0 -0
  233. {shellsim-0.1.20 → shellsim-0.1.22}/src/harness.rs +0 -0
  234. {shellsim-0.1.20 → shellsim-0.1.22}/src/harness_manager.rs +0 -0
  235. {shellsim-0.1.20 → shellsim-0.1.22}/src/hashes.rs +0 -0
  236. {shellsim-0.1.20 → shellsim-0.1.22}/src/host_ingest.rs +0 -0
  237. {shellsim-0.1.20 → shellsim-0.1.22}/src/interp.rs +0 -0
  238. {shellsim-0.1.20 → shellsim-0.1.22}/src/jqcmd.rs +0 -0
  239. {shellsim-0.1.20 → shellsim-0.1.22}/src/lib.rs +0 -0
  240. {shellsim-0.1.20 → shellsim-0.1.22}/src/main.rs +0 -0
  241. {shellsim-0.1.20 → shellsim-0.1.22}/src/mcp.rs +0 -0
  242. {shellsim-0.1.20 → shellsim-0.1.22}/src/net.rs +0 -0
  243. {shellsim-0.1.20 → shellsim-0.1.22}/src/netcmd.rs +0 -0
  244. {shellsim-0.1.20 → shellsim-0.1.22}/src/process.rs +0 -0
  245. {shellsim-0.1.20 → shellsim-0.1.22}/src/profile.rs +0 -0
  246. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/cat.rs +0 -0
  247. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/env.rs +0 -0
  248. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/find.rs +0 -0
  249. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/head.rs +0 -0
  250. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/make.rs +0 -0
  251. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/nice.rs +0 -0
  252. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/nohup.rs +0 -0
  253. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/sleep.rs +0 -0
  254. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/tee.rs +0 -0
  255. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/timeout.rs +0 -0
  256. {shellsim-0.1.20 → shellsim-0.1.22}/src/program/xargs.rs +0 -0
  257. {shellsim-0.1.20 → shellsim-0.1.22}/src/program.rs +0 -0
  258. {shellsim-0.1.20 → shellsim-0.1.22}/src/pseudo_fs.rs +0 -0
  259. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/filesystem.rs +0 -0
  260. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/http.rs +0 -0
  261. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/process.rs +0 -0
  262. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/source.rs +0 -0
  263. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/argparse.rs +0 -0
  264. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/asyncio.rs +0 -0
  265. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/base64.rs +0 -0
  266. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/bisect.rs +0 -0
  267. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/collections.rs +0 -0
  268. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/dataclasses.rs +0 -0
  269. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/functools.rs +0 -0
  270. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/hashlib.rs +0 -0
  271. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/heapq.rs +0 -0
  272. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/http.rs +0 -0
  273. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/itertools.rs +0 -0
  274. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/os.rs +0 -0
  275. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/abc.py +0 -0
  276. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/asyncio.py +0 -0
  277. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/base64.py +0 -0
  278. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/cmath.py +0 -0
  279. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/codecs.py +0 -0
  280. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/copy.py +0 -0
  281. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/csv.py +0 -0
  282. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/datetime.py +0 -0
  283. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/functools.py +0 -0
  284. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/glob.py +0 -0
  285. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/hashlib.py +0 -0
  286. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/http.py +0 -0
  287. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/http_client.py +0 -0
  288. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/json.py +0 -0
  289. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/logging.py +0 -0
  290. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/os.py +0 -0
  291. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/pathlib.py +0 -0
  292. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/shutil.py +0 -0
  293. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/signal.py +0 -0
  294. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/statistics.py +0 -0
  295. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/struct.py +0 -0
  296. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/subprocess.py +0 -0
  297. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/tempfile.py +0 -0
  298. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/textwrap.py +0 -0
  299. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/urllib.py +0 -0
  300. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/urllib_error.py +0 -0
  301. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/urllib_request.py +0 -0
  302. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/uuid.py +0 -0
  303. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/source/zlib.py +0 -0
  304. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/string.rs +0 -0
  305. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/struct.rs +0 -0
  306. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/subprocess.rs +0 -0
  307. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/time.rs +0 -0
  308. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/vfs.rs +0 -0
  309. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/stdlib/zlib.rs +0 -0
  310. {shellsim-0.1.20 → shellsim-0.1.22}/src/python/vm/host.rs +0 -0
  311. {shellsim-0.1.20 → shellsim-0.1.22}/src/realtime.rs +0 -0
  312. {shellsim-0.1.20 → shellsim-0.1.22}/src/sandbox.rs +0 -0
  313. {shellsim-0.1.20 → shellsim-0.1.22}/src/scenario.rs +0 -0
  314. {shellsim-0.1.20 → shellsim-0.1.22}/src/scheduler.rs +0 -0
  315. {shellsim-0.1.20 → shellsim-0.1.22}/src/shell.rs +0 -0
  316. {shellsim-0.1.20 → shellsim-0.1.22}/src/syscalls.rs +0 -0
  317. {shellsim-0.1.20 → shellsim-0.1.22}/src/telemetry.rs +0 -0
  318. {shellsim-0.1.20 → shellsim-0.1.22}/src/vfs.rs +0 -0
@@ -861,14 +861,16 @@ dependencies = [
861
861
 
862
862
  [[package]]
863
863
  name = "shellsim"
864
- version = "0.1.20"
864
+ version = "0.1.22"
865
865
  dependencies = [
866
866
  "base64",
867
867
  "crc32fast",
868
868
  "flate2",
869
869
  "glob",
870
870
  "libc",
871
+ "libm",
871
872
  "md-5",
873
+ "memchr",
872
874
  "num-bigint",
873
875
  "num-traits",
874
876
  "regex",
@@ -1,6 +1,6 @@
1
1
  [package]
2
2
  name = "shellsim"
3
- version = "0.1.20"
3
+ version = "0.1.22"
4
4
  edition = "2021"
5
5
  description = "In-process BusyBox-like environment for RL rollouts and agent tests"
6
6
  license = "Apache-2.0"
@@ -39,9 +39,11 @@ md-5 = "0.10"
39
39
  base64 = "0.22"
40
40
  crc32fast = "1"
41
41
  flate2 = "1"
42
+ memchr = "2"
42
43
  wasmtime = { version = "49.0.0", default-features = false, features = ["runtime", "cranelift", "gc-null", "std", "async", "call-hook"] }
43
44
  num-bigint = "0.4"
44
45
  num-traits = "0.2"
46
+ libm = "0.2"
45
47
 
46
48
  # Process-level syscall sandbox (Linux only): a startup seccomp filter that denies
47
49
  # network/exec/fork so no Python-level trick can reach the real OS for those. shellsim
@@ -1,8 +1,7 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: shellsim
3
- Version: 0.1.20
3
+ Version: 0.1.22
4
4
  Classifier: Development Status :: 3 - Alpha
5
- Classifier: License :: OSI Approved :: Apache Software License
6
5
  Classifier: Operating System :: MacOS :: MacOS X
7
6
  Classifier: Operating System :: Microsoft :: Windows
8
7
  Classifier: Operating System :: POSIX :: Linux
@@ -15,6 +14,7 @@ License-File: LICENSE
15
14
  Summary: In-process BusyBox-like environment for RL rollouts and agent tests
16
15
  Keywords: agents,containers,reinforcement-learning,sandbox,simulation,testing
17
16
  Author: The shellsim authors
17
+ License-Expression: Apache-2.0
18
18
  Requires-Python: >=3.9
19
19
  Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
20
20
  Project-URL: Homepage, https://github.com/rjpower/shellsim
@@ -216,7 +216,7 @@ printf '%s\n' \
216
216
  ## Resource model
217
217
 
218
218
  CPU is deterministic fuel, memory is modeled working set, disk is current virtual-filesystem
219
- usage, and output bounds materialized stdout and stderr. The defaults are 10,000,000 CPU units,
219
+ usage, and output bounds materialized stdout and stderr. The defaults are 100,000,000 CPU units,
220
220
  64 MiB memory, 64 MiB disk, and 4 MiB output. Costs use simple, stable approximations intended to
221
221
  be correct within an order of magnitude. They bound runaway work and make runs comparable; they
222
222
  do not model allocator layouts or instruction timing exactly. Exhaustion is observable and never
@@ -193,7 +193,7 @@ printf '%s\n' \
193
193
  ## Resource model
194
194
 
195
195
  CPU is deterministic fuel, memory is modeled working set, disk is current virtual-filesystem
196
- usage, and output bounds materialized stdout and stderr. The defaults are 10,000,000 CPU units,
196
+ usage, and output bounds materialized stdout and stderr. The defaults are 100,000,000 CPU units,
197
197
  64 MiB memory, 64 MiB disk, and 4 MiB output. Costs use simple, stable approximations intended to
198
198
  be correct within an order of magnitude. They bound runaway work and make runs comparable; they
199
199
  do not model allocator layouts or instruction timing exactly. Exhaustion is observable and never
@@ -8,11 +8,11 @@ dynamic = ["version"]
8
8
  description = "In-process BusyBox-like environment for RL rollouts and agent tests"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.9"
11
- license = { file = "LICENSE" }
11
+ license = "Apache-2.0"
12
+ license-files = ["LICENSE"]
12
13
  authors = [{ name = "The shellsim authors" }]
13
14
  classifiers = [
14
15
  "Development Status :: 3 - Alpha",
15
- "License :: OSI Approved :: Apache Software License",
16
16
  "Operating System :: MacOS :: MacOS X",
17
17
  "Operating System :: Microsoft :: Windows",
18
18
  "Operating System :: POSIX :: Linux",
@@ -925,14 +925,16 @@ dependencies = [
925
925
 
926
926
  [[package]]
927
927
  name = "shellsim"
928
- version = "0.1.20"
928
+ version = "0.1.22"
929
929
  dependencies = [
930
930
  "base64",
931
931
  "crc32fast",
932
932
  "flate2",
933
933
  "glob",
934
934
  "libc",
935
+ "libm",
935
936
  "md-5",
937
+ "memchr",
936
938
  "num-bigint",
937
939
  "num-traits",
938
940
  "regex",
@@ -947,7 +949,7 @@ dependencies = [
947
949
 
948
950
  [[package]]
949
951
  name = "shellsim-python-bindings"
950
- version = "0.1.20"
952
+ version = "0.1.22"
951
953
  dependencies = [
952
954
  "pyo3",
953
955
  "serde",
@@ -2,7 +2,7 @@
2
2
 
3
3
  [package]
4
4
  name = "shellsim-python-bindings"
5
- version = "0.1.20"
5
+ version = "0.1.22"
6
6
  edition = "2021"
7
7
  description = "Python bindings for shellsim"
8
8
  license = "Apache-2.0"
@@ -19,7 +19,7 @@ _MAX_U64 = (1 << 64) - 1
19
19
  class Limits:
20
20
  """Cumulative resource limits for one simulated environment."""
21
21
 
22
- cpu: int = 10_000_000
22
+ cpu: int = 100_000_000
23
23
  memory: int = 64 * 1024 * 1024
24
24
  disk: int = 64 * 1024 * 1024
25
25
  output: int = 4 * 1024 * 1024
@@ -23,6 +23,10 @@ pub enum StatementKind {
23
23
  module: String,
24
24
  names: Vec<(String, String)>,
25
25
  },
26
+ /// `from module import *` binds the module's public names; only valid at module level.
27
+ ImportStar {
28
+ module: String,
29
+ },
26
30
  Assign {
27
31
  targets: Vec<AssignmentTarget>,
28
32
  value: Expression,
@@ -92,7 +96,11 @@ pub enum StatementKind {
92
96
  otherwise: Vec<Statement>,
93
97
  finalbody: Vec<Statement>,
94
98
  },
95
- Raise(Option<Expression>),
99
+ /// `raise [exception [from cause]]`.
100
+ Raise {
101
+ exception: Option<Expression>,
102
+ cause: Option<Expression>,
103
+ },
96
104
  With {
97
105
  context: Expression,
98
106
  target: Option<AssignmentTarget>,
@@ -286,6 +294,8 @@ pub struct Parameter {
286
294
 
287
295
  #[derive(Clone, Copy, Debug, PartialEq, Eq)]
288
296
  pub enum ParameterKind {
297
+ /// A parameter before a `/` marker, which callers cannot pass by keyword.
298
+ PositionalOnly,
289
299
  Positional,
290
300
  Variadic,
291
301
  KeywordOnly,
@@ -295,6 +305,8 @@ pub enum ParameterKind {
295
305
  #[derive(Clone, Debug, PartialEq)]
296
306
  pub enum Constant {
297
307
  None,
308
+ /// The `...` literal, which evaluates to the `Ellipsis` singleton.
309
+ Ellipsis,
298
310
  Bool(bool),
299
311
  Integer(i64),
300
312
  BigInteger(String),
@@ -39,7 +39,7 @@ side_table_id!(CallId);
39
39
  side_table_id!(FunctionId);
40
40
  side_table_id!(ClassId);
41
41
  side_table_id!(FormatId);
42
- side_table_id!(DictId);
42
+ side_table_id!(UnpackId);
43
43
  side_table_id!(ErrorId);
44
44
 
45
45
  #[derive(Clone, Debug, PartialEq)]
@@ -57,7 +57,8 @@ pub struct Code {
57
57
  functions: Box<[FunctionSpec]>,
58
58
  classes: Box<[ClassSpec]>,
59
59
  formats: Box<[FormatSpec]>,
60
- dicts: Box<[Box<[bool]>]>,
60
+ /// Per-operand unpacking flags shared by dictionary and starred sequence displays.
61
+ unpack_flags: Box<[Box<[bool]>]>,
61
62
  errors: Box<[String]>,
62
63
  }
63
64
 
@@ -101,8 +102,8 @@ impl Code {
101
102
  &self.formats[id.index()]
102
103
  }
103
104
 
104
- pub fn dict_entries(&self, id: DictId) -> &[bool] {
105
- &self.dicts[id.index()]
105
+ pub fn unpack_flags(&self, id: UnpackId) -> &[bool] {
106
+ &self.unpack_flags[id.index()]
106
107
  }
107
108
 
108
109
  pub fn error(&self, id: ErrorId) -> &str {
@@ -119,6 +120,7 @@ pub struct Parameter {
119
120
 
120
121
  #[derive(Clone, Copy, Debug, PartialEq, Eq)]
121
122
  pub enum ParameterKind {
123
+ PositionalOnly,
122
124
  Positional,
123
125
  Variadic,
124
126
  KeywordOnly,
@@ -181,6 +183,7 @@ pub enum Opcode {
181
183
  StoreGlobal(NameId),
182
184
  StoreAttribute(NameId),
183
185
  StoreSubscript,
186
+ DeleteAttribute(NameId),
184
187
  DeleteName(NameId),
185
188
  DeleteLocal(usize),
186
189
  DeleteGlobal(NameId),
@@ -189,6 +192,10 @@ pub enum Opcode {
189
192
  name: NameId,
190
193
  bind_root: bool,
191
194
  },
195
+ /// `from module import name`, with the module on top of the stack; it stays there.
196
+ ImportFrom(NameId),
197
+ /// `from module import *`: pop the module and bind its public names in the current scope.
198
+ ImportStar,
192
199
  LoadAttribute(NameId),
193
200
  LoadSubscript,
194
201
  BuildSlice {
@@ -198,8 +205,13 @@ pub enum Opcode {
198
205
  },
199
206
  BuildList(usize),
200
207
  BuildTuple(usize),
201
- BuildDict(DictId),
208
+ BuildDict(UnpackId),
202
209
  BuildSet(usize),
210
+ /// A list, tuple, or set display with at least one `*iterable` operand.
211
+ BuildUnpacked {
212
+ kind: DisplayKind,
213
+ starred: UnpackId,
214
+ },
203
215
  UnpackSequence {
204
216
  count: usize,
205
217
  star_index: Option<usize>,
@@ -210,6 +222,8 @@ pub enum Opcode {
210
222
  ForIterator(usize),
211
223
  Unary(UnaryOperator),
212
224
  Binary(BinaryOperator),
225
+ /// Augmented assignment: the left operand's in-place method, else the binary operator.
226
+ InPlaceBinary(BinaryOperator),
213
227
  FormatValue(FormatId),
214
228
  Compare(ComparisonOperator),
215
229
  Call(CallId),
@@ -231,7 +245,9 @@ pub enum Opcode {
231
245
  ClearException,
232
246
  Reraise,
233
247
  Raise(bool),
248
+ RaiseFrom,
234
249
  Yield,
250
+ YieldFromSend(usize),
235
251
  AwaitResult,
236
252
  WithEnter,
237
253
  WithExit,
@@ -260,6 +276,7 @@ pub enum Operation {
260
276
  StoreGlobal(String),
261
277
  StoreAttribute(String),
262
278
  StoreSubscript,
279
+ DeleteAttribute(String),
263
280
  DeleteName(String),
264
281
  DeleteLocal(usize),
265
282
  DeleteGlobal(String),
@@ -268,6 +285,8 @@ pub enum Operation {
268
285
  name: String,
269
286
  bind_root: bool,
270
287
  },
288
+ ImportFrom(String),
289
+ ImportStar,
271
290
  LoadAttribute(String),
272
291
  LoadSubscript,
273
292
  BuildSlice {
@@ -281,6 +300,11 @@ pub enum Operation {
281
300
  /// consumes one key/value pair.
282
301
  BuildDict(Vec<bool>),
283
302
  BuildSet(usize),
303
+ /// Build a list, tuple, or set from source-ordered operands; `true` expands an iterable.
304
+ BuildUnpacked {
305
+ kind: DisplayKind,
306
+ starred: Vec<bool>,
307
+ },
284
308
  UnpackSequence {
285
309
  count: usize,
286
310
  star_index: Option<usize>,
@@ -301,6 +325,8 @@ pub enum Operation {
301
325
  ForIterator(usize),
302
326
  Unary(UnaryOperator),
303
327
  Binary(BinaryOperator),
328
+ /// Augmented assignment: the left operand's in-place method, else the binary operator.
329
+ InPlaceBinary(BinaryOperator),
304
330
  FormatValue {
305
331
  conversion: Option<char>,
306
332
  format_spec: String,
@@ -331,8 +357,15 @@ pub enum Operation {
331
357
  ClearException,
332
358
  Reraise,
333
359
  Raise(bool),
360
+ /// `raise exception from cause`: pops the cause, then the exception.
361
+ RaiseFrom,
334
362
  /// Suspend a generator frame and return the value on top of the stack.
335
363
  Yield,
364
+ /// One step of `yield from`: pop the value sent into the generator and pass it to the
365
+ /// subiterator below it. A yielded value suspends the frame at this same instruction, so the
366
+ /// next `send` repeats the step; when the subiterator finishes, it is replaced by its return
367
+ /// value and control jumps to the target.
368
+ YieldFromSend(usize),
336
369
  /// Unwrap the scheduler outcome sent into a suspended coroutine.
337
370
  AwaitResult,
338
371
  WithEnter,
@@ -344,6 +377,14 @@ pub enum Operation {
344
377
  Halt,
345
378
  }
346
379
 
380
+ /// The container a sequence display builds.
381
+ #[derive(Clone, Copy, Debug, PartialEq, Eq)]
382
+ pub enum DisplayKind {
383
+ List,
384
+ Tuple,
385
+ Set,
386
+ }
387
+
347
388
  #[derive(Default)]
348
389
  pub struct CodeBuilder {
349
390
  names: Vec<Arc<str>>,
@@ -353,7 +394,7 @@ pub struct CodeBuilder {
353
394
  functions: Vec<FunctionSpec>,
354
395
  classes: Vec<ClassSpec>,
355
396
  formats: Vec<FormatSpec>,
356
- dicts: Vec<Box<[bool]>>,
397
+ unpack_flags: Vec<Box<[bool]>>,
357
398
  errors: Vec<String>,
358
399
  }
359
400
 
@@ -369,6 +410,12 @@ impl CodeBuilder {
369
410
  id
370
411
  }
371
412
 
413
+ fn unpack_flags(&mut self, flags: Vec<bool>) -> UnpackId {
414
+ let id = UnpackId::new(self.unpack_flags.len());
415
+ self.unpack_flags.push(flags.into_boxed_slice());
416
+ id
417
+ }
418
+
372
419
  pub fn lower(&mut self, operation: Operation) -> Opcode {
373
420
  match operation {
374
421
  Operation::LoadConstant(value) => {
@@ -389,6 +436,7 @@ impl CodeBuilder {
389
436
  Operation::StoreGlobal(name) => Opcode::StoreGlobal(self.name(name)),
390
437
  Operation::StoreAttribute(name) => Opcode::StoreAttribute(self.name(name)),
391
438
  Operation::StoreSubscript => Opcode::StoreSubscript,
439
+ Operation::DeleteAttribute(name) => Opcode::DeleteAttribute(self.name(name)),
392
440
  Operation::DeleteName(name) => Opcode::DeleteName(self.name(name)),
393
441
  Operation::DeleteLocal(slot) => Opcode::DeleteLocal(slot),
394
442
  Operation::DeleteGlobal(name) => Opcode::DeleteGlobal(self.name(name)),
@@ -397,6 +445,8 @@ impl CodeBuilder {
397
445
  name: self.name(name),
398
446
  bind_root,
399
447
  },
448
+ Operation::ImportFrom(name) => Opcode::ImportFrom(self.name(name)),
449
+ Operation::ImportStar => Opcode::ImportStar,
400
450
  Operation::LoadAttribute(name) => Opcode::LoadAttribute(self.name(name)),
401
451
  Operation::LoadSubscript => Opcode::LoadSubscript,
402
452
  Operation::BuildSlice {
@@ -410,12 +460,12 @@ impl CodeBuilder {
410
460
  },
411
461
  Operation::BuildList(count) => Opcode::BuildList(count),
412
462
  Operation::BuildTuple(count) => Opcode::BuildTuple(count),
413
- Operation::BuildDict(entries) => {
414
- let id = DictId::new(self.dicts.len());
415
- self.dicts.push(entries.into_boxed_slice());
416
- Opcode::BuildDict(id)
417
- }
463
+ Operation::BuildDict(entries) => Opcode::BuildDict(self.unpack_flags(entries)),
418
464
  Operation::BuildSet(count) => Opcode::BuildSet(count),
465
+ Operation::BuildUnpacked { kind, starred } => Opcode::BuildUnpacked {
466
+ kind,
467
+ starred: self.unpack_flags(starred),
468
+ },
419
469
  Operation::UnpackSequence { count, star_index } => {
420
470
  Opcode::UnpackSequence { count, star_index }
421
471
  }
@@ -455,6 +505,7 @@ impl CodeBuilder {
455
505
  Operation::ForIterator(target) => Opcode::ForIterator(target),
456
506
  Operation::Unary(operator) => Opcode::Unary(operator),
457
507
  Operation::Binary(operator) => Opcode::Binary(operator),
508
+ Operation::InPlaceBinary(operator) => Opcode::InPlaceBinary(operator),
458
509
  Operation::FormatValue {
459
510
  conversion,
460
511
  format_spec,
@@ -504,7 +555,9 @@ impl CodeBuilder {
504
555
  Operation::ClearException => Opcode::ClearException,
505
556
  Operation::Reraise => Opcode::Reraise,
506
557
  Operation::Raise(cause) => Opcode::Raise(cause),
558
+ Operation::RaiseFrom => Opcode::RaiseFrom,
507
559
  Operation::Yield => Opcode::Yield,
560
+ Operation::YieldFromSend(target) => Opcode::YieldFromSend(target),
508
561
  Operation::AwaitResult => Opcode::AwaitResult,
509
562
  Operation::WithEnter => Opcode::WithEnter,
510
563
  Operation::WithExit => Opcode::WithExit,
@@ -526,12 +579,17 @@ impl CodeBuilder {
526
579
  ) -> CodeRef {
527
580
  let positional_count = parameters
528
581
  .iter()
529
- .take_while(|parameter| parameter.kind == ParameterKind::Positional)
582
+ .take_while(|parameter| {
583
+ matches!(
584
+ parameter.kind,
585
+ ParameterKind::PositionalOnly | ParameterKind::Positional
586
+ )
587
+ })
530
588
  .count();
531
589
  let call_signature = CallSignature {
532
- is_generator: instructions
533
- .iter()
534
- .any(|instruction| matches!(instruction.opcode, Opcode::Yield)),
590
+ is_generator: instructions.iter().any(|instruction| {
591
+ matches!(instruction.opcode, Opcode::Yield | Opcode::YieldFromSend(_))
592
+ }),
535
593
  is_coroutine,
536
594
  positional_count,
537
595
  variadic_slot: parameters
@@ -559,7 +617,7 @@ impl CodeBuilder {
559
617
  functions: self.functions.into_boxed_slice(),
560
618
  classes: self.classes.into_boxed_slice(),
561
619
  formats: self.formats.into_boxed_slice(),
562
- dicts: self.dicts.into_boxed_slice(),
620
+ unpack_flags: self.unpack_flags.into_boxed_slice(),
563
621
  errors: self.errors.into_boxed_slice(),
564
622
  })
565
623
  }