fable-library 5.2.0__tar.gz → 5.4.0__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 (92) hide show
  1. {fable_library-5.2.0 → fable_library-5.4.0}/Cargo.lock +10 -11
  2. {fable_library-5.2.0 → fable_library-5.4.0}/Cargo.toml +1 -1
  3. {fable_library-5.2.0 → fable_library-5.4.0}/PKG-INFO +2 -2
  4. fable_library-5.4.0/fable_library/_version.py +1 -0
  5. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/fsharp_core.py +2 -1
  6. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/list.py +36 -35
  7. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/map.py +5 -4
  8. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/mutable_map.py +17 -16
  9. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/mutable_set.py +7 -7
  10. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/range.py +12 -12
  11. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/result.py +2 -2
  12. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/seq.py +22 -21
  13. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/seq2.py +20 -20
  14. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/set.py +8 -8
  15. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/system.py +77 -63
  16. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/system_collections_generic.py +2 -1
  17. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/types.py +17 -0
  18. {fable_library-5.2.0 → fable_library-5.4.0}/pyproject.toml +2 -2
  19. {fable_library-5.2.0 → fable_library-5.4.0}/src/array.rs +24 -54
  20. {fable_library-5.2.0 → fable_library-5.4.0}/uv.lock +1 -1
  21. fable_library-5.2.0/fable_library/_version.py +0 -1
  22. {fable_library-5.2.0 → fable_library-5.4.0}/README.md +0 -0
  23. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/__init__.py +0 -0
  24. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/array_.py +0 -0
  25. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/async_.py +0 -0
  26. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/async_builder.py +0 -0
  27. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/bases.py +0 -0
  28. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/big_int.py +0 -0
  29. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/bit_converter.py +0 -0
  30. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/boolean.py +0 -0
  31. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/char.py +0 -0
  32. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/choice.py +0 -0
  33. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/core/__init__.py +0 -0
  34. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/core/__init__.pyi +0 -0
  35. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/core/_core.pyi +0 -0
  36. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/core/array.pyi +0 -0
  37. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/core/floats.pyi +0 -0
  38. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/core/ints.pyi +0 -0
  39. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/core/option.pyi +0 -0
  40. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/core/strings.pyi +0 -0
  41. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/core/types.pyi +0 -0
  42. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/curry.py +0 -0
  43. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/date.py +0 -0
  44. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/date_offset.py +0 -0
  45. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/date_only.py +0 -0
  46. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/decimal_.py +0 -0
  47. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/diagnostics.py +0 -0
  48. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/double.py +0 -0
  49. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/encoding.py +0 -0
  50. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/event.py +0 -0
  51. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/exceptions.py +0 -0
  52. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/file.py +0 -0
  53. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/floats.py +0 -0
  54. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/fsharp_collections.py +0 -0
  55. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/global_.py +0 -0
  56. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/guid.py +0 -0
  57. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/int32.py +0 -0
  58. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/long.py +0 -0
  59. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/mailbox_processor.py +0 -0
  60. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/map_util.py +0 -0
  61. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/native.py +0 -0
  62. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/numeric.py +0 -0
  63. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/observable.py +0 -0
  64. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/option.py +0 -0
  65. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/path.py +0 -0
  66. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/protocols.py +0 -0
  67. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/quotation.py +0 -0
  68. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/record.py +0 -0
  69. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/reflection.py +0 -0
  70. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/reg_exp.py +0 -0
  71. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/resize_array.py +0 -0
  72. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/singleton_local_time_zone.py +0 -0
  73. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/string_.py +0 -0
  74. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/system_text.py +0 -0
  75. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/task.py +0 -0
  76. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/task_builder.py +0 -0
  77. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/thread.py +0 -0
  78. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/time_only.py +0 -0
  79. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/time_span.py +0 -0
  80. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/timer.py +0 -0
  81. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/union.py +0 -0
  82. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/uri.py +0 -0
  83. {fable_library-5.2.0 → fable_library-5.4.0}/fable_library/util.py +0 -0
  84. {fable_library-5.2.0 → fable_library-5.4.0}/py.typed +0 -0
  85. {fable_library-5.2.0 → fable_library-5.4.0}/src/floats.rs +0 -0
  86. {fable_library-5.2.0 → fable_library-5.4.0}/src/ints.rs +0 -0
  87. {fable_library-5.2.0 → fable_library-5.4.0}/src/lib.rs +0 -0
  88. {fable_library-5.2.0 → fable_library-5.4.0}/src/native_array.rs +0 -0
  89. {fable_library-5.2.0 → fable_library-5.4.0}/src/options.rs +0 -0
  90. {fable_library-5.2.0 → fable_library-5.4.0}/src/strings.rs +0 -0
  91. {fable_library-5.2.0 → fable_library-5.4.0}/src/types.rs +0 -0
  92. {fable_library-5.2.0 → fable_library-5.4.0}/src/util.rs +0 -0
@@ -179,9 +179,9 @@ dependencies = [
179
179
 
180
180
  [[package]]
181
181
  name = "pyo3"
182
- version = "0.28.3"
182
+ version = "0.29.0"
183
183
  source = "registry+https://github.com/rust-lang/crates.io-index"
184
- checksum = "91fd8e38a3b50ed1167fb981cd6fd60147e091784c427b8f7183a7ee32c31c12"
184
+ checksum = "cd274650b21d4bfc26a0a47587962c1edb425f69287324355cd040c3ea66071c"
185
185
  dependencies = [
186
186
  "chrono",
187
187
  "libc",
@@ -194,18 +194,18 @@ dependencies = [
194
194
 
195
195
  [[package]]
196
196
  name = "pyo3-build-config"
197
- version = "0.28.3"
197
+ version = "0.29.0"
198
198
  source = "registry+https://github.com/rust-lang/crates.io-index"
199
- checksum = "e368e7ddfdeb98c9bca7f8383be1648fd84ab466bf2bc015e94008db6d35611e"
199
+ checksum = "c5e2a7d2f0d013342f295c048ad19237add5154a55b1c5a254c0ec93d4109078"
200
200
  dependencies = [
201
201
  "target-lexicon",
202
202
  ]
203
203
 
204
204
  [[package]]
205
205
  name = "pyo3-ffi"
206
- version = "0.28.3"
206
+ version = "0.29.0"
207
207
  source = "registry+https://github.com/rust-lang/crates.io-index"
208
- checksum = "7f29e10af80b1f7ccaf7f69eace800a03ecd13e883acfacc1e5d0988605f651e"
208
+ checksum = "ca85c467da1bbc8d866eea5deff9cf29ea5f7785054a17da36e65bda9c05845b"
209
209
  dependencies = [
210
210
  "libc",
211
211
  "pyo3-build-config",
@@ -213,9 +213,9 @@ dependencies = [
213
213
 
214
214
  [[package]]
215
215
  name = "pyo3-macros"
216
- version = "0.28.3"
216
+ version = "0.29.0"
217
217
  source = "registry+https://github.com/rust-lang/crates.io-index"
218
- checksum = "df6e520eff47c45997d2fc7dd8214b25dd1310918bbb2642156ef66a67f29813"
218
+ checksum = "9ac53762fd065daa3194dd09337a38bd793a188100fd1a9304c4ab312d901771"
219
219
  dependencies = [
220
220
  "proc-macro2",
221
221
  "pyo3-macros-backend",
@@ -225,13 +225,12 @@ dependencies = [
225
225
 
226
226
  [[package]]
227
227
  name = "pyo3-macros-backend"
228
- version = "0.28.3"
228
+ version = "0.29.0"
229
229
  source = "registry+https://github.com/rust-lang/crates.io-index"
230
- checksum = "c4cdc218d835738f81c2338f822078af45b4afdf8b2e33cbb5916f108b813acb"
230
+ checksum = "4ca3a1557399783172dc5bf39cfca835157732532cba56b71d2292161e53b362"
231
231
  dependencies = [
232
232
  "heck",
233
233
  "proc-macro2",
234
- "pyo3-build-config",
235
234
  "quote",
236
235
  "syn",
237
236
  ]
@@ -12,7 +12,7 @@ name = "_core"
12
12
  crate-type = ["cdylib"]
13
13
 
14
14
  [dependencies]
15
- pyo3 = { version = "0.28.3", features = ["extension-module", "chrono"] }
15
+ pyo3 = { version = "0.29.0", features = ["extension-module", "chrono"] }
16
16
  byteorder = "1.5.0"
17
17
  chrono = "0.4.45"
18
18
  regex = "1.12.4"
@@ -1,9 +1,9 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fable-library
3
- Version: 5.2.0
3
+ Version: 5.4.0
4
4
  Summary: Fable library for Python
5
5
  Author-email: Dag Brattli <dag@brattli.net>
6
- License-Expression: MIT License
6
+ License-Expression: MIT
7
7
  Requires-Python: >=3.10, <4.0
8
8
  Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
9
9
  Project-URL: Homepage, https://fable.io
@@ -0,0 +1 @@
1
+ __version__ = "5.4.0"
@@ -10,6 +10,7 @@ from .option import value as value_1
10
10
  from .protocols import IComparer_1, IDisposable, IEqualityComparer, IEqualityComparer_1
11
11
  from .system import ArgumentNullException__ctor_Z721C83C5, NullReferenceException__ctor
12
12
  from .system_text import StringBuilder__Append_Z721C83C5
13
+ from .types import ExceptionBase
13
14
  from .util import UNIT, Unit, dispose, equals, ignore, structural_hash
14
15
 
15
16
 
@@ -52,7 +53,7 @@ def LanguagePrimitives_FastGenericEqualityComparerFromTable[T](__unit: Unit = UN
52
53
 
53
54
 
54
55
  def Operators_Failure(message: str) -> Exception:
55
- return Exception(message)
56
+ return ExceptionBase(message)
56
57
 
57
58
 
58
59
  def Operators_FailurePattern(exn: Exception) -> str | None:
@@ -42,6 +42,7 @@ from .protocols import IComparer_1, IEnumerable_1, IEnumerator, IEqualityCompare
42
42
  from .record import Record
43
43
  from .reflection import TypeInfo, class_type, option_type, record_type
44
44
  from .string_ import join
45
+ from .types import ExceptionBase
45
46
  from .util import (
46
47
  UNIT,
47
48
  Disposable,
@@ -269,7 +270,7 @@ def FSharpList__get_Head[T](xs: FSharpList[T]) -> T:
269
270
  return xs.head_
270
271
 
271
272
  else:
272
- raise Exception((SR_inputWasEmpty + "\\nParameter name: ") + "list")
273
+ raise Exception(SR_inputWasEmpty + " (Parameter 'list')")
273
274
 
274
275
 
275
276
  def FSharpList__get_Tail[T](xs: FSharpList[T]) -> FSharpList[T]:
@@ -278,7 +279,7 @@ def FSharpList__get_Tail[T](xs: FSharpList[T]) -> FSharpList[T]:
278
279
  return match_value
279
280
 
280
281
  else:
281
- raise Exception((SR_inputWasEmpty + "\\nParameter name: ") + "list")
282
+ raise Exception(SR_inputWasEmpty + " (Parameter 'list')")
282
283
 
283
284
 
284
285
  def FSharpList__get_Item_Z524259A4[T](xs: FSharpList[T], index: int32) -> T:
@@ -296,7 +297,7 @@ def FSharpList__get_Item_Z524259A4[T](xs: FSharpList[T], index: int32) -> T:
296
297
  continue
297
298
 
298
299
  else:
299
- raise Exception((SR_indexOutOfBounds + "\\nParameter name: ") + "index")
300
+ raise Exception(SR_indexOutOfBounds + " (Parameter 'index')")
300
301
 
301
302
  break
302
303
 
@@ -304,7 +305,7 @@ def FSharpList__get_Item_Z524259A4[T](xs: FSharpList[T], index: int32) -> T:
304
305
 
305
306
 
306
307
  def index_not_found[_A](__unit: Unit = UNIT) -> _A:
307
- raise Exception(SR_keyNotFoundAlt)
308
+ raise ExceptionBase(SR_keyNotFoundAlt)
308
309
 
309
310
 
310
311
  def empty[_A](__unit: Unit = UNIT) -> FSharpList[_A]:
@@ -820,10 +821,10 @@ def map_fold[STATE, T, RESULT](
820
821
  def map_fold_back[T, STATE, RESULT](
821
822
  mapping: Callable[[T, STATE], tuple[RESULT, STATE]], xs: FSharpList[T], state: STATE
822
823
  ) -> tuple[FSharpList[RESULT], STATE]:
823
- def _arrow44(acc: STATE, x: T, mapping: Any = mapping) -> tuple[RESULT, STATE]:
824
+ def _arrow48(acc: STATE, x: T, mapping: Any = mapping) -> tuple[RESULT, STATE]:
824
825
  return mapping(x, acc)
825
826
 
826
- return map_fold(_arrow44, state, reverse(xs))
827
+ return map_fold(_arrow48, state, reverse(xs))
827
828
 
828
829
 
829
830
  def try_pick[T, _A](f: Callable[[T], Option[_A]], xs: FSharpList[T]) -> Option[_A]:
@@ -857,10 +858,10 @@ def pick[_A, _B](f: Callable[[_A], Option[_B]], xs: FSharpList[_A]) -> _B:
857
858
 
858
859
 
859
860
  def try_find[_A](f: Callable[[_A], bool], xs: FSharpList[_A]) -> Option[_A]:
860
- def _arrow45(x: _A = UNIT, f: Any = f) -> Option[_A]:
861
+ def _arrow56(x: _A = UNIT, f: Any = f) -> Option[_A]:
861
862
  return some(x) if f(x) else None
862
863
 
863
- return try_pick(_arrow45, xs)
864
+ return try_pick(_arrow56, xs)
864
865
 
865
866
 
866
867
  def find[_A](f: Callable[[_A], bool], xs: FSharpList[_A]) -> _A:
@@ -983,21 +984,21 @@ def partition[T](f: Callable[[T], bool], xs: FSharpList[T]) -> tuple[FSharpList[
983
984
  racc: FSharpList[Any] = tupled_arg[1]
984
985
  if f(x):
985
986
 
986
- def _arrow46(x: Any = x) -> FSharpList[T]:
987
+ def _arrow57(x: Any = x) -> FSharpList[T]:
987
988
  t: FSharpList[Any] = FSharpList(x, None)
988
989
  lacc.tail_ = t
989
990
  return t
990
991
 
991
- return (_arrow46(), racc)
992
+ return (_arrow57(), racc)
992
993
 
993
994
  else:
994
995
 
995
- def _arrow47(x: Any = x) -> FSharpList[T]:
996
+ def _arrow58(x: Any = x) -> FSharpList[T]:
996
997
  t_2: FSharpList[Any] = FSharpList(x, None)
997
998
  racc.tail_ = t_2
998
999
  return t_2
999
1000
 
1000
- return (lacc, _arrow47())
1001
+ return (lacc, _arrow58())
1001
1002
 
1002
1003
  pattern_input_1: tuple[FSharpList[Any], FSharpList[Any]] = fold(folder, (root1, root2), xs)
1003
1004
  t_4: FSharpList[Any] = FSharpList_get_Empty()
@@ -1125,7 +1126,7 @@ def exists2[T1, T2](f_mut: Callable[[T1, T2], bool], xs_mut: FSharpList[T1], ys_
1125
1126
  continue
1126
1127
 
1127
1128
  else:
1128
- raise Exception((SR_differentLengths + "\\nParameter name: ") + "list2")
1129
+ raise Exception(SR_differentLengths + " (Parameter 'list2')")
1129
1130
 
1130
1131
  break
1131
1132
 
@@ -1311,7 +1312,7 @@ def skip[T](count_mut: int32, xs_mut: FSharpList[T]) -> FSharpList[T]:
1311
1312
  return xs
1312
1313
 
1313
1314
  elif FSharpList__get_IsEmpty(xs):
1314
- raise Exception((SR_notEnoughElements + "\\nParameter name: ") + "list")
1315
+ raise Exception(SR_notEnoughElements + " (Parameter 'list')")
1315
1316
 
1316
1317
  else:
1317
1318
  count_mut = count - int32.ONE
@@ -1340,7 +1341,7 @@ def skip_while[T](predicate_mut: Callable[[T], bool], xs_mut: FSharpList[T]) ->
1340
1341
 
1341
1342
  def take[T](count: int32, xs: FSharpList[T]) -> FSharpList[T]:
1342
1343
  if count < int32.ZERO:
1343
- raise Exception((SR_inputMustBeNonNegative + "\\nParameter name: ") + "count")
1344
+ raise Exception(SR_inputMustBeNonNegative + " (Parameter 'count')")
1344
1345
 
1345
1346
  def loop(i_mut: int32, acc_mut: FSharpList[T], xs_1_mut: FSharpList[T]) -> FSharpList[T]:
1346
1347
  while True:
@@ -1349,17 +1350,17 @@ def take[T](count: int32, xs: FSharpList[T]) -> FSharpList[T]:
1349
1350
  return acc
1350
1351
 
1351
1352
  elif FSharpList__get_IsEmpty(xs_1):
1352
- raise Exception((SR_notEnoughElements + "\\nParameter name: ") + "list")
1353
+ raise Exception(SR_notEnoughElements + " (Parameter 'list')")
1353
1354
 
1354
1355
  else:
1355
1356
  i_mut = i - int32.ONE
1356
1357
 
1357
- def _arrow82(acc: Any = acc, xs_1: Any = xs_1) -> FSharpList[T]:
1358
+ def _arrow88(acc: Any = acc, xs_1: Any = xs_1) -> FSharpList[T]:
1358
1359
  t: FSharpList[Any] = FSharpList(FSharpList__get_Head(xs_1), None)
1359
1360
  acc.tail_ = t
1360
1361
  return t
1361
1362
 
1362
- acc_mut = _arrow82()
1363
+ acc_mut = _arrow88()
1363
1364
  xs_1_mut = FSharpList__get_Tail(xs_1)
1364
1365
  continue
1365
1366
 
@@ -1384,12 +1385,12 @@ def take_while[T](predicate: Callable[[T], bool], xs: FSharpList[T]) -> FSharpLi
1384
1385
 
1385
1386
  else:
1386
1387
 
1387
- def _arrow83(acc: Any = acc, xs_1: Any = xs_1) -> FSharpList[T]:
1388
+ def _arrow89(acc: Any = acc, xs_1: Any = xs_1) -> FSharpList[T]:
1388
1389
  t: FSharpList[Any] = FSharpList(FSharpList__get_Head(xs_1), None)
1389
1390
  acc.tail_ = t
1390
1391
  return t
1391
1392
 
1392
- acc_mut = _arrow83()
1393
+ acc_mut = _arrow89()
1393
1394
  xs_1_mut = FSharpList__get_Tail(xs_1)
1394
1395
  continue
1395
1396
 
@@ -1415,12 +1416,12 @@ def truncate[T](count: int32, xs: FSharpList[T]) -> FSharpList[T]:
1415
1416
  else:
1416
1417
  i_mut = i - int32.ONE
1417
1418
 
1418
- def _arrow84(acc: Any = acc, xs_1: Any = xs_1) -> FSharpList[T]:
1419
+ def _arrow90(acc: Any = acc, xs_1: Any = xs_1) -> FSharpList[T]:
1419
1420
  t: FSharpList[Any] = FSharpList(FSharpList__get_Head(xs_1), None)
1420
1421
  acc.tail_ = t
1421
1422
  return t
1422
1423
 
1423
- acc_mut = _arrow84()
1424
+ acc_mut = _arrow90()
1424
1425
  xs_1_mut = FSharpList__get_Tail(xs_1)
1425
1426
  continue
1426
1427
 
@@ -1450,23 +1451,23 @@ def get_slice[T](start_index: int32 | None, end_index: int32 | None, xs: FSharpL
1450
1451
 
1451
1452
  def split_at[T](index: int32, xs: FSharpList[T]) -> tuple[FSharpList[T], FSharpList[T]]:
1452
1453
  if index < int32.ZERO:
1453
- raise Exception((SR_inputMustBeNonNegative + "\\nParameter name: ") + "index")
1454
+ raise Exception(SR_inputMustBeNonNegative + " (Parameter 'index')")
1454
1455
 
1455
1456
  if index > FSharpList__get_Length(xs):
1456
- raise Exception((SR_notEnoughElements + "\\nParameter name: ") + "index")
1457
+ raise Exception(SR_notEnoughElements + " (Parameter 'index')")
1457
1458
 
1458
1459
  return (take(index, xs), skip(index, xs))
1459
1460
 
1460
1461
 
1461
1462
  def exactly_one[T](xs: FSharpList[T]) -> T:
1462
1463
  if FSharpList__get_IsEmpty(xs):
1463
- raise Exception((SR_inputSequenceEmpty + "\\nParameter name: ") + "list")
1464
+ raise Exception(SR_inputSequenceEmpty + " (Parameter 'list')")
1464
1465
 
1465
1466
  elif FSharpList__get_IsEmpty(FSharpList__get_Tail(xs)):
1466
1467
  return FSharpList__get_Head(xs)
1467
1468
 
1468
1469
  else:
1469
- raise Exception((SR_inputSequenceTooLong + "\\nParameter name: ") + "list")
1470
+ raise Exception(SR_inputSequenceTooLong + " (Parameter 'list')")
1470
1471
 
1471
1472
 
1472
1473
  def try_exactly_one[T](xs: FSharpList[T]) -> Option[T]:
@@ -1513,11 +1514,11 @@ def insert_at[T](index: int32, y: T, xs: FSharpList[T]) -> FSharpList[T]:
1513
1514
 
1514
1515
  result: FSharpList[Any] = fold(folder, FSharpList_get_Empty(), xs)
1515
1516
 
1516
- def _arrow85(__unit: Unit = UNIT) -> FSharpList[T]:
1517
- raise Exception((SR_indexOutOfBounds + "\\nParameter name: ") + "index")
1517
+ def _arrow91(__unit: Unit = UNIT) -> FSharpList[T]:
1518
+ raise Exception(SR_indexOutOfBounds + " (Parameter 'index')")
1518
1519
 
1519
1520
  return reverse(
1520
- result if is_done else (FSharpList_Cons_305B8EAC(y, result) if ((i + int32.ONE) == index) else _arrow85())
1521
+ result if is_done else (FSharpList_Cons_305B8EAC(y, result) if ((i + int32.ONE) == index) else _arrow91())
1521
1522
  )
1522
1523
 
1523
1524
 
@@ -1538,10 +1539,10 @@ def insert_many_at[T](index: int32, ys: IEnumerable_1[T], xs: FSharpList[T]) ->
1538
1539
 
1539
1540
  result: FSharpList[Any] = fold(folder, FSharpList_get_Empty(), xs)
1540
1541
 
1541
- def _arrow91(__unit: Unit = UNIT) -> FSharpList[T]:
1542
- raise Exception((SR_indexOutOfBounds + "\\nParameter name: ") + "index")
1542
+ def _arrow92(__unit: Unit = UNIT) -> FSharpList[T]:
1543
+ raise Exception(SR_indexOutOfBounds + " (Parameter 'index')")
1543
1544
 
1544
- return reverse(result if is_done else (append(ys_1, result) if ((i + int32.ONE) == index) else _arrow91()))
1545
+ return reverse(result if is_done else (append(ys_1, result) if ((i + int32.ONE) == index) else _arrow92()))
1545
1546
 
1546
1547
 
1547
1548
  def remove_at[T](index: int32, xs: FSharpList[T]) -> FSharpList[T]:
@@ -1560,7 +1561,7 @@ def remove_at[T](index: int32, xs: FSharpList[T]) -> FSharpList[T]:
1560
1561
 
1561
1562
  ys: FSharpList[Any] = filter(f, xs)
1562
1563
  if not is_done:
1563
- raise Exception((SR_indexOutOfBounds + "\\nParameter name: ") + "index")
1564
+ raise Exception(SR_indexOutOfBounds + " (Parameter 'index')")
1564
1565
 
1565
1566
  return ys
1566
1567
 
@@ -1593,7 +1594,7 @@ def remove_many_at[T](index: int32, count: int32, xs: FSharpList[T]) -> FSharpLi
1593
1594
  )
1594
1595
  if status_1 < int32.ONE:
1595
1596
  raise Exception(
1596
- (SR_indexOutOfBounds + "\\nParameter name: ") + ("index" if (status_1 < int32.ZERO) else "count")
1597
+ SR_indexOutOfBounds + ((" (Parameter '" + ("index" if (status_1 < int32.ZERO) else "count")) + "')")
1597
1598
  )
1598
1599
 
1599
1600
  return ys
@@ -1613,7 +1614,7 @@ def update_at[T](index: int32, y: T, xs: FSharpList[T]) -> FSharpList[T]:
1613
1614
 
1614
1615
  ys: FSharpList[Any] = map_indexed(mapping, xs)
1615
1616
  if not is_done:
1616
- raise Exception((SR_indexOutOfBounds + "\\nParameter name: ") + "index")
1617
+ raise Exception(SR_indexOutOfBounds + " (Parameter 'index')")
1617
1618
 
1618
1619
  return ys
1619
1620
 
@@ -25,6 +25,7 @@ from .seq import pick as pick_1
25
25
  from .seq import try_pick as try_pick_1
26
26
  from .string_ import format, join
27
27
  from .system import NotSupportedException__ctor_Z721C83C5
28
+ from .types import ExceptionBase
28
29
  from .util import UNIT, Disposable, Unit, compare, equals, get_enumerator, ignore, nullable, range, structural_hash
29
30
 
30
31
 
@@ -349,7 +350,7 @@ def MapTreeModule_find[KEY, VALUE](
349
350
  ) -> VALUE:
350
351
  match_value: Option[Any] = MapTreeModule_tryFind(comparer, k, m)
351
352
  if match_value is None:
352
- raise Exception()
353
+ raise ExceptionBase()
353
354
 
354
355
  else:
355
356
  return value_1(match_value)
@@ -1243,7 +1244,7 @@ def MapTreeModule_leftmost[KEY, VALUE](m_mut: MapTreeLeaf_2[KEY, VALUE] | None)
1243
1244
  return (MapTreeLeaf_2__get_Key(m2), MapTreeLeaf_2__get_Value(m2))
1244
1245
 
1245
1246
  else:
1246
- raise Exception()
1247
+ raise ExceptionBase()
1247
1248
 
1248
1249
  break
1249
1250
 
@@ -1277,7 +1278,7 @@ def MapTreeModule_rightmost[KEY, VALUE](m_mut: MapTreeLeaf_2[KEY, VALUE] | None)
1277
1278
  return (MapTreeLeaf_2__get_Key(m2), MapTreeLeaf_2__get_Value(m2))
1278
1279
 
1279
1280
  else:
1280
- raise Exception()
1281
+ raise ExceptionBase()
1281
1282
 
1282
1283
  break
1283
1284
 
@@ -1608,7 +1609,7 @@ def pick[_A, _B, _C](chooser: Callable[[_A, _B], Option[_C]], table: FSharpMap[_
1608
1609
  return value_1(match_value)
1609
1610
 
1610
1611
  else:
1611
- raise Exception()
1612
+ raise ExceptionBase()
1612
1613
 
1613
1614
 
1614
1615
  def exists[_A, _B](predicate: Callable[[_A, _B], bool], table: FSharpMap[_A, _B]) -> bool:
@@ -16,11 +16,12 @@ from .resize_array import find_index
16
16
  from .seq import concat, delay, iterate_indexed, map
17
17
  from .string_ import format
18
18
  from .system import ArgumentException__ctor_Z721C83C5
19
+ from .types import ExceptionBase
19
20
  from .types import FSharpRef as FSharpRef_1
20
21
  from .util import UNIT, Disposable, Unit, dispose, equals, get_enumerator, ignore, nullable, to_enumerable
21
22
 
22
23
 
23
- def _expr13(gen0: TypeInfo, gen1: TypeInfo) -> TypeInfo:
24
+ def _expr17(gen0: TypeInfo, gen1: TypeInfo) -> TypeInfo:
24
25
  return class_type("Fable.Collections.Dictionary", Array([gen0, gen1]), Dictionary)
25
26
 
26
27
 
@@ -126,13 +127,13 @@ class Dictionary[KEY, VALUE](MutableMapping[Any, Any], Mapping[Any, Any], Enumer
126
127
  def System_Collections_Generic_IDictionary_2_get_Keys(self, __unit: Unit = UNIT) -> ICollection[KEY]:
127
128
  this: Dictionary[Any, Any] = self
128
129
 
129
- def _arrow9(__unit: Unit = UNIT) -> IEnumerable_1[KEY]:
130
- def _arrow8(pair: Any) -> KEY:
130
+ def _arrow14(__unit: Unit = UNIT) -> IEnumerable_1[KEY]:
131
+ def _arrow13(pair: Any) -> KEY:
131
132
  return pair[0]
132
133
 
133
- return map(_arrow8, this)
134
+ return map(_arrow13, this)
134
135
 
135
- return Array[Any](delay(_arrow9))
136
+ return Array[Any](delay(_arrow14))
136
137
 
137
138
  def System_Collections_Generic_IDictionary_2_Remove2B595(self, key: KEY = UNIT) -> bool:
138
139
  this: Dictionary[Any, Any] = self
@@ -152,13 +153,13 @@ class Dictionary[KEY, VALUE](MutableMapping[Any, Any], Mapping[Any, Any], Enumer
152
153
  def System_Collections_Generic_IDictionary_2_get_Values(self, __unit: Unit = UNIT) -> ICollection[VALUE]:
153
154
  this: Dictionary[Any, Any] = self
154
155
 
155
- def _arrow11(__unit: Unit = UNIT) -> IEnumerable_1[VALUE]:
156
- def _arrow10(pair: Any) -> VALUE:
156
+ def _arrow16(__unit: Unit = UNIT) -> IEnumerable_1[VALUE]:
157
+ def _arrow15(pair: Any) -> VALUE:
157
158
  return pair[1]
158
159
 
159
- return map(_arrow10, this)
160
+ return map(_arrow15, this)
160
161
 
161
- return Array[Any](delay(_arrow11))
162
+ return Array[Any](delay(_arrow16))
162
163
 
163
164
  def get_item(self, key: KEY = UNIT) -> VALUE:
164
165
  this: Dictionary[Any, Any] = self
@@ -205,7 +206,7 @@ class Dictionary[KEY, VALUE](MutableMapping[Any, Any], Mapping[Any, Any], Enumer
205
206
  self.Remove(key)
206
207
 
207
208
 
208
- Dictionary_reflection = _expr13
209
+ Dictionary_reflection = _expr17
209
210
 
210
211
 
211
212
  def Dictionary__ctor_6623D9B3[KEY, VALUE](
@@ -219,20 +220,20 @@ def Dictionary__TryFindIndex_2B595[KEY, VALUE](this: Dictionary[KEY, VALUE], k:
219
220
  match_value: tuple[bool, list[Any]]
220
221
  out_arg: list[Any] = cast(list[Any], None)
221
222
 
222
- def _arrow15(__unit: Unit = UNIT) -> list[Any]:
223
+ def _arrow18(__unit: Unit = UNIT) -> list[Any]:
223
224
  return out_arg
224
225
 
225
- def _arrow17(v: list[Any]) -> None:
226
+ def _arrow19(v: list[Any]) -> None:
226
227
  nonlocal out_arg
227
228
  out_arg = v
228
229
 
229
- match_value = (try_get_value(this.hash_map, h, FSharpRef(_arrow15, _arrow17)), out_arg)
230
+ match_value = (try_get_value(this.hash_map, h, FSharpRef(_arrow18, _arrow19)), out_arg)
230
231
  if match_value[0]:
231
232
 
232
- def _arrow19(pair: Any, this: Any = this, k: Any = k) -> bool:
233
+ def _arrow20(pair: Any, this: Any = this, k: Any = k) -> bool:
233
234
  return this.comparer.Equals(k, pair[0])
234
235
 
235
- return (True, h, find_index(_arrow19, match_value[1]))
236
+ return (True, h, find_index(_arrow20, match_value[1]))
236
237
 
237
238
  else:
238
239
  return (False, h, int32.NEG_ONE)
@@ -276,7 +277,7 @@ def Dictionary__get_Item_2B595[KEY, VALUE](this: Dictionary[KEY, VALUE], k: KEY)
276
277
  return match_value[1]
277
278
 
278
279
  else:
279
- raise Exception("The item was not found in collection")
280
+ raise ExceptionBase("The item was not found in collection")
280
281
 
281
282
 
282
283
  def Dictionary__set_Item_5BDDA1[KEY, VALUE](this: Dictionary[KEY, VALUE], k: KEY, v: VALUE) -> None:
@@ -19,7 +19,7 @@ from .types import FSharpRef
19
19
  from .util import UNIT, Disposable, Unit, dispose, get_enumerator, ignore, to_enumerable
20
20
 
21
21
 
22
- def _expr12(gen0: TypeInfo) -> TypeInfo:
22
+ def _expr9(gen0: TypeInfo) -> TypeInfo:
23
23
  return class_type("Fable.Collections.HashSet", Array([gen0]), HashSet)
24
24
 
25
25
 
@@ -111,7 +111,7 @@ class HashSet[T](MutableSet[Any], Set[Any], EnumerableBase[Any]):
111
111
  self.Remove(value)
112
112
 
113
113
 
114
- HashSet_reflection = _expr12
114
+ HashSet_reflection = _expr9
115
115
 
116
116
 
117
117
  def HashSet__ctor_Z6150332D[T](items: IEnumerable_1[T], comparer: IEqualityComparer_1[Any]) -> HashSet[T]:
@@ -123,20 +123,20 @@ def HashSet__TryFindIndex_2B595[T](this: HashSet[T], k: T) -> tuple[bool, int32,
123
123
  match_value: tuple[bool, list[Any]]
124
124
  out_arg: list[Any] = cast(list[Any], None)
125
125
 
126
- def _arrow14(__unit: Unit = UNIT) -> list[T]:
126
+ def _arrow10(__unit: Unit = UNIT) -> list[T]:
127
127
  return out_arg
128
128
 
129
- def _arrow16(v: list[T]) -> None:
129
+ def _arrow11(v: list[T]) -> None:
130
130
  nonlocal out_arg
131
131
  out_arg = v
132
132
 
133
- match_value = (try_get_value(this.hash_map, h, FSharpRef_1(_arrow14, _arrow16)), out_arg)
133
+ match_value = (try_get_value(this.hash_map, h, FSharpRef_1(_arrow10, _arrow11)), out_arg)
134
134
  if match_value[0]:
135
135
 
136
- def _arrow18(v_1: T = UNIT, this: Any = this, k: Any = k) -> bool:
136
+ def _arrow12(v_1: T = UNIT, this: Any = this, k: Any = k) -> bool:
137
137
  return this.comparer.Equals(k, v_1)
138
138
 
139
- return (True, h, find_index(_arrow18, match_value[1]))
139
+ return (True, h, find_index(_arrow12, match_value[1]))
140
140
 
141
141
  else:
142
142
  return (False, h, int32.NEG_ONE)
@@ -25,7 +25,7 @@ def make_range_step_function[T](
25
25
 
26
26
  step_greater_than_zero: bool = step_compared_with_zero > int32.ZERO
27
27
 
28
- def _arrow86(x: T = UNIT, step: Any = step, stop: Any = stop, add: Any = add) -> tuple[T, T] | None:
28
+ def _arrow82(x: T = UNIT, step: Any = step, stop: Any = stop, add: Any = add) -> tuple[T, T] | None:
29
29
  compared_with_last: int32 = compare(x, stop)
30
30
  return (
31
31
  ((x, add(x, step)))
@@ -37,16 +37,16 @@ def make_range_step_function[T](
37
37
  else None
38
38
  )
39
39
 
40
- return _arrow86
40
+ return _arrow82
41
41
 
42
42
 
43
43
  def integral_range_step[T](start: T, step: T, stop: T, zero: T, add: Callable[[T, T], T]) -> IEnumerable_1[T]:
44
44
  step_fn: Callable[[Any], tuple[Any, Any] | None] = erase(make_range_step_function(step, stop, zero, add))
45
45
 
46
- def _arrow87(start: Any = start) -> IEnumerable_1[T]:
46
+ def _arrow83(start: Any = start) -> IEnumerable_1[T]:
47
47
  return unfold(step_fn, start)
48
48
 
49
- return delay(_arrow87)
49
+ return delay(_arrow83)
50
50
 
51
51
 
52
52
  def range_big_int(start: int, step: int, stop: int) -> IEnumerable_1[int]:
@@ -60,24 +60,24 @@ def range_decimal(start: Decimal, step: Decimal, stop: Decimal) -> IEnumerable_1
60
60
 
61
61
 
62
62
  def range_double(start: float64, step: float64, stop: float64) -> IEnumerable_1[float64]:
63
- def _arrow88(x: float64, y: float64) -> float64:
63
+ def _arrow84(x: float64, y: float64) -> float64:
64
64
  return x + y
65
65
 
66
- return integral_range_step(start, step, stop, float64(0.0), _arrow88)
66
+ return integral_range_step(start, step, stop, float64(0.0), _arrow84)
67
67
 
68
68
 
69
69
  def range_int32(start: int32, step: int32, stop: int32) -> IEnumerable_1[int32]:
70
- def _arrow89(x: int32, y: int32) -> int32:
70
+ def _arrow85(x: int32, y: int32) -> int32:
71
71
  return x + y
72
72
 
73
- return integral_range_step(start, step, stop, int32.ZERO, _arrow89)
73
+ return integral_range_step(start, step, stop, int32.ZERO, _arrow85)
74
74
 
75
75
 
76
76
  def range_uint32(start: uint32, step: uint32, stop: uint32) -> IEnumerable_1[uint32]:
77
- def _arrow90(x: uint32, y: uint32) -> uint32:
77
+ def _arrow86(x: uint32, y: uint32) -> uint32:
78
78
  return x + y
79
79
 
80
- return integral_range_step(start, step, stop, uint32.ZERO, _arrow90)
80
+ return integral_range_step(start, step, stop, uint32.ZERO, _arrow86)
81
81
 
82
82
 
83
83
  def range_int64(start: int64, step: int64, stop: int64) -> IEnumerable_1[int64]:
@@ -91,7 +91,7 @@ def range_uint64(start: uint64, step: uint64, stop: uint64) -> IEnumerable_1[uin
91
91
  def range_char(start: str, stop: str) -> IEnumerable_1[str]:
92
92
  int_stop: int32 = int32(char_code_at(stop, int32.ZERO))
93
93
 
94
- def _arrow92(start: Any = start) -> IEnumerable_1[str]:
94
+ def _arrow87(start: Any = start) -> IEnumerable_1[str]:
95
95
  def step_fn(i: int32) -> tuple[str, int32] | None:
96
96
  if i <= int_stop:
97
97
  return (chr(int(i)), i + int32.ONE)
@@ -101,7 +101,7 @@ def range_char(start: str, stop: str) -> IEnumerable_1[str]:
101
101
 
102
102
  return unfold(step_fn, int32(char_code_at(start, int32.ZERO)))
103
103
 
104
- return delay(_arrow92)
104
+ return delay(_arrow87)
105
105
 
106
106
 
107
107
  __all__ = [
@@ -12,7 +12,7 @@ from .union import Union, tagged_union
12
12
  from .util import equals
13
13
 
14
14
 
15
- def _expr20(gen0: TypeInfo, gen1: TypeInfo) -> TypeInfo:
15
+ def _expr8(gen0: TypeInfo, gen1: TypeInfo) -> TypeInfo:
16
16
  return union_type(
17
17
  "FSharp.Core.FSharpResult`2",
18
18
  Array([gen0, gen1]),
@@ -40,7 +40,7 @@ class Error[T, TERROR](_FSharpResult_2[T, TERROR]):
40
40
 
41
41
  type FSharpResult_2[T, TERROR] = Ok[T, TERROR] | Error[T, TERROR]
42
42
 
43
- FSharpResult_2_reflection = _expr20
43
+ FSharpResult_2_reflection = _expr8
44
44
 
45
45
 
46
46
  def Result_Map[A, B, C](mapping: Callable[[A], B], result: FSharpResult_2[A, C]) -> FSharpResult_2[B, C]: