fable-library 5.2.0__tar.gz → 5.3.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.
- {fable_library-5.2.0 → fable_library-5.3.0}/Cargo.lock +10 -11
- {fable_library-5.2.0 → fable_library-5.3.0}/Cargo.toml +1 -1
- {fable_library-5.2.0 → fable_library-5.3.0}/PKG-INFO +1 -1
- fable_library-5.3.0/fable_library/_version.py +1 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/list.py +48 -48
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/mutable_map.py +15 -15
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/mutable_set.py +7 -7
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/range.py +12 -12
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/result.py +2 -2
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/seq.py +20 -20
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/seq2.py +20 -20
- {fable_library-5.2.0 → fable_library-5.3.0}/pyproject.toml +1 -1
- {fable_library-5.2.0 → fable_library-5.3.0}/uv.lock +1 -1
- fable_library-5.2.0/fable_library/_version.py +0 -1
- {fable_library-5.2.0 → fable_library-5.3.0}/README.md +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/__init__.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/array_.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/async_.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/async_builder.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/bases.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/big_int.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/bit_converter.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/boolean.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/char.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/choice.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/core/__init__.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/core/__init__.pyi +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/core/_core.pyi +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/core/array.pyi +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/core/floats.pyi +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/core/ints.pyi +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/core/option.pyi +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/core/strings.pyi +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/core/types.pyi +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/curry.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/date.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/date_offset.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/date_only.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/decimal_.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/diagnostics.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/double.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/encoding.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/event.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/exceptions.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/file.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/floats.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/fsharp_collections.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/fsharp_core.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/global_.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/guid.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/int32.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/long.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/mailbox_processor.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/map.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/map_util.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/native.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/numeric.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/observable.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/option.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/path.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/protocols.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/quotation.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/record.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/reflection.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/reg_exp.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/resize_array.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/set.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/singleton_local_time_zone.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/string_.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/system.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/system_collections_generic.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/system_text.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/task.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/task_builder.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/thread.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/time_only.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/time_span.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/timer.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/types.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/union.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/uri.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/fable_library/util.py +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/py.typed +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/src/array.rs +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/src/floats.rs +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/src/ints.rs +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/src/lib.rs +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/src/native_array.rs +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/src/options.rs +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/src/strings.rs +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/src/types.rs +0 -0
- {fable_library-5.2.0 → fable_library-5.3.0}/src/util.rs +0 -0
|
@@ -179,9 +179,9 @@ dependencies = [
|
|
|
179
179
|
|
|
180
180
|
[[package]]
|
|
181
181
|
name = "pyo3"
|
|
182
|
-
version = "0.
|
|
182
|
+
version = "0.29.0"
|
|
183
183
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
184
|
-
checksum = "
|
|
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.
|
|
197
|
+
version = "0.29.0"
|
|
198
198
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
199
|
-
checksum = "
|
|
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.
|
|
206
|
+
version = "0.29.0"
|
|
207
207
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
208
|
-
checksum = "
|
|
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.
|
|
216
|
+
version = "0.29.0"
|
|
217
217
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
218
|
-
checksum = "
|
|
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.
|
|
228
|
+
version = "0.29.0"
|
|
229
229
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
230
|
-
checksum = "
|
|
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.
|
|
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"
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "5.3.0"
|
|
@@ -269,7 +269,7 @@ def FSharpList__get_Head[T](xs: FSharpList[T]) -> T:
|
|
|
269
269
|
return xs.head_
|
|
270
270
|
|
|
271
271
|
else:
|
|
272
|
-
raise Exception(
|
|
272
|
+
raise Exception(SR_inputWasEmpty + " (Parameter 'list')")
|
|
273
273
|
|
|
274
274
|
|
|
275
275
|
def FSharpList__get_Tail[T](xs: FSharpList[T]) -> FSharpList[T]:
|
|
@@ -278,7 +278,7 @@ def FSharpList__get_Tail[T](xs: FSharpList[T]) -> FSharpList[T]:
|
|
|
278
278
|
return match_value
|
|
279
279
|
|
|
280
280
|
else:
|
|
281
|
-
raise Exception(
|
|
281
|
+
raise Exception(SR_inputWasEmpty + " (Parameter 'list')")
|
|
282
282
|
|
|
283
283
|
|
|
284
284
|
def FSharpList__get_Item_Z524259A4[T](xs: FSharpList[T], index: int32) -> T:
|
|
@@ -296,7 +296,7 @@ def FSharpList__get_Item_Z524259A4[T](xs: FSharpList[T], index: int32) -> T:
|
|
|
296
296
|
continue
|
|
297
297
|
|
|
298
298
|
else:
|
|
299
|
-
raise Exception(
|
|
299
|
+
raise Exception(SR_indexOutOfBounds + " (Parameter 'index')")
|
|
300
300
|
|
|
301
301
|
break
|
|
302
302
|
|
|
@@ -695,10 +695,10 @@ def map[T, U](mapping: Callable[[T], U], xs: FSharpList[T]) -> FSharpList[U]:
|
|
|
695
695
|
|
|
696
696
|
|
|
697
697
|
def indexed[_A](xs: FSharpList[_A]) -> FSharpList[tuple[int32, _A]]:
|
|
698
|
-
def
|
|
698
|
+
def _arrow51(i: int32, x: _A) -> tuple[int32, _A]:
|
|
699
699
|
return (i, x)
|
|
700
700
|
|
|
701
|
-
return map_indexed(
|
|
701
|
+
return map_indexed(_arrow51, xs)
|
|
702
702
|
|
|
703
703
|
|
|
704
704
|
def map2[T1, T2, U](mapping: Callable[[T1, T2], U], xs: FSharpList[T1], ys: FSharpList[T2]) -> FSharpList[U]:
|
|
@@ -729,14 +729,14 @@ def map_indexed2[T1, T2, U](
|
|
|
729
729
|
else:
|
|
730
730
|
i_mut = i + int32.ONE
|
|
731
731
|
|
|
732
|
-
def
|
|
732
|
+
def _arrow52(i: Any = i, acc: Any = acc, xs_1: Any = xs_1, ys_1: Any = ys_1) -> FSharpList[U]:
|
|
733
733
|
t: FSharpList[Any] = FSharpList(
|
|
734
734
|
mapping(i, FSharpList__get_Head(xs_1), FSharpList__get_Head(ys_1)), None
|
|
735
735
|
)
|
|
736
736
|
acc.tail_ = t
|
|
737
737
|
return t
|
|
738
738
|
|
|
739
|
-
acc_mut =
|
|
739
|
+
acc_mut = _arrow52()
|
|
740
740
|
xs_1_mut = FSharpList__get_Tail(xs_1)
|
|
741
741
|
ys_1_mut = FSharpList__get_Tail(ys_1)
|
|
742
742
|
continue
|
|
@@ -771,7 +771,7 @@ def map3[T1, T2, T3, U](
|
|
|
771
771
|
|
|
772
772
|
else:
|
|
773
773
|
|
|
774
|
-
def
|
|
774
|
+
def _arrow53(acc: Any = acc, xs_1: Any = xs_1, ys_1: Any = ys_1, zs_1: Any = zs_1) -> FSharpList[U]:
|
|
775
775
|
t: FSharpList[Any] = FSharpList(
|
|
776
776
|
mapping(FSharpList__get_Head(xs_1), FSharpList__get_Head(ys_1), FSharpList__get_Head(zs_1)),
|
|
777
777
|
None,
|
|
@@ -779,7 +779,7 @@ def map3[T1, T2, T3, U](
|
|
|
779
779
|
acc.tail_ = t
|
|
780
780
|
return t
|
|
781
781
|
|
|
782
|
-
acc_mut =
|
|
782
|
+
acc_mut = _arrow53()
|
|
783
783
|
xs_1_mut = FSharpList__get_Tail(xs_1)
|
|
784
784
|
ys_1_mut = FSharpList__get_Tail(ys_1)
|
|
785
785
|
zs_1_mut = FSharpList__get_Tail(zs_1)
|
|
@@ -804,12 +804,12 @@ def map_fold[STATE, T, RESULT](
|
|
|
804
804
|
) -> tuple[FSharpList[RESULT], STATE]:
|
|
805
805
|
pattern_input: tuple[Any, Any] = mapping(tupled_arg[1], x)
|
|
806
806
|
|
|
807
|
-
def
|
|
807
|
+
def _arrow54(tupled_arg: Any = tupled_arg) -> FSharpList[RESULT]:
|
|
808
808
|
t: FSharpList[Any] = FSharpList(pattern_input[0], None)
|
|
809
809
|
tupled_arg[0].tail_ = t
|
|
810
810
|
return t
|
|
811
811
|
|
|
812
|
-
return (
|
|
812
|
+
return (_arrow54(), pattern_input[1])
|
|
813
813
|
|
|
814
814
|
pattern_input_1: tuple[FSharpList[Any], Any] = fold(folder, (root, state), xs)
|
|
815
815
|
t_2: FSharpList[Any] = FSharpList_get_Empty()
|
|
@@ -820,10 +820,10 @@ def map_fold[STATE, T, RESULT](
|
|
|
820
820
|
def map_fold_back[T, STATE, RESULT](
|
|
821
821
|
mapping: Callable[[T, STATE], tuple[RESULT, STATE]], xs: FSharpList[T], state: STATE
|
|
822
822
|
) -> tuple[FSharpList[RESULT], STATE]:
|
|
823
|
-
def
|
|
823
|
+
def _arrow55(acc: STATE, x: T, mapping: Any = mapping) -> tuple[RESULT, STATE]:
|
|
824
824
|
return mapping(x, acc)
|
|
825
825
|
|
|
826
|
-
return map_fold(
|
|
826
|
+
return map_fold(_arrow55, state, reverse(xs))
|
|
827
827
|
|
|
828
828
|
|
|
829
829
|
def try_pick[T, _A](f: Callable[[T], Option[_A]], xs: FSharpList[T]) -> Option[_A]:
|
|
@@ -857,10 +857,10 @@ def pick[_A, _B](f: Callable[[_A], Option[_B]], xs: FSharpList[_A]) -> _B:
|
|
|
857
857
|
|
|
858
858
|
|
|
859
859
|
def try_find[_A](f: Callable[[_A], bool], xs: FSharpList[_A]) -> Option[_A]:
|
|
860
|
-
def
|
|
860
|
+
def _arrow56(x: _A = UNIT, f: Any = f) -> Option[_A]:
|
|
861
861
|
return some(x) if f(x) else None
|
|
862
862
|
|
|
863
|
-
return try_pick(
|
|
863
|
+
return try_pick(_arrow56, xs)
|
|
864
864
|
|
|
865
865
|
|
|
866
866
|
def find[_A](f: Callable[[_A], bool], xs: FSharpList[_A]) -> _A:
|
|
@@ -983,21 +983,21 @@ def partition[T](f: Callable[[T], bool], xs: FSharpList[T]) -> tuple[FSharpList[
|
|
|
983
983
|
racc: FSharpList[Any] = tupled_arg[1]
|
|
984
984
|
if f(x):
|
|
985
985
|
|
|
986
|
-
def
|
|
986
|
+
def _arrow57(x: Any = x) -> FSharpList[T]:
|
|
987
987
|
t: FSharpList[Any] = FSharpList(x, None)
|
|
988
988
|
lacc.tail_ = t
|
|
989
989
|
return t
|
|
990
990
|
|
|
991
|
-
return (
|
|
991
|
+
return (_arrow57(), racc)
|
|
992
992
|
|
|
993
993
|
else:
|
|
994
994
|
|
|
995
|
-
def
|
|
995
|
+
def _arrow58(x: Any = x) -> FSharpList[T]:
|
|
996
996
|
t_2: FSharpList[Any] = FSharpList(x, None)
|
|
997
997
|
racc.tail_ = t_2
|
|
998
998
|
return t_2
|
|
999
999
|
|
|
1000
|
-
return (lacc,
|
|
1000
|
+
return (lacc, _arrow58())
|
|
1001
1001
|
|
|
1002
1002
|
pattern_input_1: tuple[FSharpList[Any], FSharpList[Any]] = fold(folder, (root1, root2), xs)
|
|
1003
1003
|
t_4: FSharpList[Any] = FSharpList_get_Empty()
|
|
@@ -1125,7 +1125,7 @@ def exists2[T1, T2](f_mut: Callable[[T1, T2], bool], xs_mut: FSharpList[T1], ys_
|
|
|
1125
1125
|
continue
|
|
1126
1126
|
|
|
1127
1127
|
else:
|
|
1128
|
-
raise Exception(
|
|
1128
|
+
raise Exception(SR_differentLengths + " (Parameter 'list2')")
|
|
1129
1129
|
|
|
1130
1130
|
break
|
|
1131
1131
|
|
|
@@ -1283,21 +1283,21 @@ def all_pairs[T1, T2](xs: FSharpList[T1], ys: FSharpList[T2]) -> FSharpList[tupl
|
|
|
1283
1283
|
root: FSharpList[tuple[Any, Any]] = FSharpList_get_Empty()
|
|
1284
1284
|
node: FSharpList[tuple[Any, Any]] = root
|
|
1285
1285
|
|
|
1286
|
-
def
|
|
1287
|
-
def
|
|
1286
|
+
def _arrow87(x: T1 = UNIT, ys: Any = ys) -> None:
|
|
1287
|
+
def _arrow86(y: T2 = UNIT) -> None:
|
|
1288
1288
|
nonlocal node
|
|
1289
1289
|
|
|
1290
|
-
def
|
|
1290
|
+
def _arrow85(__unit: Unit = UNIT) -> FSharpList[tuple[T1, T2]]:
|
|
1291
1291
|
xs_1: FSharpList[tuple[Any, Any]] = node
|
|
1292
1292
|
t: FSharpList[tuple[Any, Any]] = FSharpList((x, y), None)
|
|
1293
1293
|
xs_1.tail_ = t
|
|
1294
1294
|
return t
|
|
1295
1295
|
|
|
1296
|
-
node =
|
|
1296
|
+
node = _arrow85()
|
|
1297
1297
|
|
|
1298
|
-
iterate(
|
|
1298
|
+
iterate(_arrow86, ys)
|
|
1299
1299
|
|
|
1300
|
-
iterate(
|
|
1300
|
+
iterate(_arrow87, xs)
|
|
1301
1301
|
xs_3: FSharpList[tuple[Any, Any]] = node
|
|
1302
1302
|
t_2: FSharpList[tuple[Any, Any]] = FSharpList_get_Empty()
|
|
1303
1303
|
xs_3.tail_ = t_2
|
|
@@ -1311,7 +1311,7 @@ def skip[T](count_mut: int32, xs_mut: FSharpList[T]) -> FSharpList[T]:
|
|
|
1311
1311
|
return xs
|
|
1312
1312
|
|
|
1313
1313
|
elif FSharpList__get_IsEmpty(xs):
|
|
1314
|
-
raise Exception(
|
|
1314
|
+
raise Exception(SR_notEnoughElements + " (Parameter 'list')")
|
|
1315
1315
|
|
|
1316
1316
|
else:
|
|
1317
1317
|
count_mut = count - int32.ONE
|
|
@@ -1340,7 +1340,7 @@ def skip_while[T](predicate_mut: Callable[[T], bool], xs_mut: FSharpList[T]) ->
|
|
|
1340
1340
|
|
|
1341
1341
|
def take[T](count: int32, xs: FSharpList[T]) -> FSharpList[T]:
|
|
1342
1342
|
if count < int32.ZERO:
|
|
1343
|
-
raise Exception(
|
|
1343
|
+
raise Exception(SR_inputMustBeNonNegative + " (Parameter 'count')")
|
|
1344
1344
|
|
|
1345
1345
|
def loop(i_mut: int32, acc_mut: FSharpList[T], xs_1_mut: FSharpList[T]) -> FSharpList[T]:
|
|
1346
1346
|
while True:
|
|
@@ -1349,17 +1349,17 @@ def take[T](count: int32, xs: FSharpList[T]) -> FSharpList[T]:
|
|
|
1349
1349
|
return acc
|
|
1350
1350
|
|
|
1351
1351
|
elif FSharpList__get_IsEmpty(xs_1):
|
|
1352
|
-
raise Exception(
|
|
1352
|
+
raise Exception(SR_notEnoughElements + " (Parameter 'list')")
|
|
1353
1353
|
|
|
1354
1354
|
else:
|
|
1355
1355
|
i_mut = i - int32.ONE
|
|
1356
1356
|
|
|
1357
|
-
def
|
|
1357
|
+
def _arrow88(acc: Any = acc, xs_1: Any = xs_1) -> FSharpList[T]:
|
|
1358
1358
|
t: FSharpList[Any] = FSharpList(FSharpList__get_Head(xs_1), None)
|
|
1359
1359
|
acc.tail_ = t
|
|
1360
1360
|
return t
|
|
1361
1361
|
|
|
1362
|
-
acc_mut =
|
|
1362
|
+
acc_mut = _arrow88()
|
|
1363
1363
|
xs_1_mut = FSharpList__get_Tail(xs_1)
|
|
1364
1364
|
continue
|
|
1365
1365
|
|
|
@@ -1384,12 +1384,12 @@ def take_while[T](predicate: Callable[[T], bool], xs: FSharpList[T]) -> FSharpLi
|
|
|
1384
1384
|
|
|
1385
1385
|
else:
|
|
1386
1386
|
|
|
1387
|
-
def
|
|
1387
|
+
def _arrow89(acc: Any = acc, xs_1: Any = xs_1) -> FSharpList[T]:
|
|
1388
1388
|
t: FSharpList[Any] = FSharpList(FSharpList__get_Head(xs_1), None)
|
|
1389
1389
|
acc.tail_ = t
|
|
1390
1390
|
return t
|
|
1391
1391
|
|
|
1392
|
-
acc_mut =
|
|
1392
|
+
acc_mut = _arrow89()
|
|
1393
1393
|
xs_1_mut = FSharpList__get_Tail(xs_1)
|
|
1394
1394
|
continue
|
|
1395
1395
|
|
|
@@ -1415,12 +1415,12 @@ def truncate[T](count: int32, xs: FSharpList[T]) -> FSharpList[T]:
|
|
|
1415
1415
|
else:
|
|
1416
1416
|
i_mut = i - int32.ONE
|
|
1417
1417
|
|
|
1418
|
-
def
|
|
1418
|
+
def _arrow90(acc: Any = acc, xs_1: Any = xs_1) -> FSharpList[T]:
|
|
1419
1419
|
t: FSharpList[Any] = FSharpList(FSharpList__get_Head(xs_1), None)
|
|
1420
1420
|
acc.tail_ = t
|
|
1421
1421
|
return t
|
|
1422
1422
|
|
|
1423
|
-
acc_mut =
|
|
1423
|
+
acc_mut = _arrow90()
|
|
1424
1424
|
xs_1_mut = FSharpList__get_Tail(xs_1)
|
|
1425
1425
|
continue
|
|
1426
1426
|
|
|
@@ -1450,23 +1450,23 @@ def get_slice[T](start_index: int32 | None, end_index: int32 | None, xs: FSharpL
|
|
|
1450
1450
|
|
|
1451
1451
|
def split_at[T](index: int32, xs: FSharpList[T]) -> tuple[FSharpList[T], FSharpList[T]]:
|
|
1452
1452
|
if index < int32.ZERO:
|
|
1453
|
-
raise Exception(
|
|
1453
|
+
raise Exception(SR_inputMustBeNonNegative + " (Parameter 'index')")
|
|
1454
1454
|
|
|
1455
1455
|
if index > FSharpList__get_Length(xs):
|
|
1456
|
-
raise Exception(
|
|
1456
|
+
raise Exception(SR_notEnoughElements + " (Parameter 'index')")
|
|
1457
1457
|
|
|
1458
1458
|
return (take(index, xs), skip(index, xs))
|
|
1459
1459
|
|
|
1460
1460
|
|
|
1461
1461
|
def exactly_one[T](xs: FSharpList[T]) -> T:
|
|
1462
1462
|
if FSharpList__get_IsEmpty(xs):
|
|
1463
|
-
raise Exception(
|
|
1463
|
+
raise Exception(SR_inputSequenceEmpty + " (Parameter 'list')")
|
|
1464
1464
|
|
|
1465
1465
|
elif FSharpList__get_IsEmpty(FSharpList__get_Tail(xs)):
|
|
1466
1466
|
return FSharpList__get_Head(xs)
|
|
1467
1467
|
|
|
1468
1468
|
else:
|
|
1469
|
-
raise Exception(
|
|
1469
|
+
raise Exception(SR_inputSequenceTooLong + " (Parameter 'list')")
|
|
1470
1470
|
|
|
1471
1471
|
|
|
1472
1472
|
def try_exactly_one[T](xs: FSharpList[T]) -> Option[T]:
|
|
@@ -1513,11 +1513,11 @@ def insert_at[T](index: int32, y: T, xs: FSharpList[T]) -> FSharpList[T]:
|
|
|
1513
1513
|
|
|
1514
1514
|
result: FSharpList[Any] = fold(folder, FSharpList_get_Empty(), xs)
|
|
1515
1515
|
|
|
1516
|
-
def
|
|
1517
|
-
raise Exception(
|
|
1516
|
+
def _arrow91(__unit: Unit = UNIT) -> FSharpList[T]:
|
|
1517
|
+
raise Exception(SR_indexOutOfBounds + " (Parameter 'index')")
|
|
1518
1518
|
|
|
1519
1519
|
return reverse(
|
|
1520
|
-
result if is_done else (FSharpList_Cons_305B8EAC(y, result) if ((i + int32.ONE) == index) else
|
|
1520
|
+
result if is_done else (FSharpList_Cons_305B8EAC(y, result) if ((i + int32.ONE) == index) else _arrow91())
|
|
1521
1521
|
)
|
|
1522
1522
|
|
|
1523
1523
|
|
|
@@ -1538,10 +1538,10 @@ def insert_many_at[T](index: int32, ys: IEnumerable_1[T], xs: FSharpList[T]) ->
|
|
|
1538
1538
|
|
|
1539
1539
|
result: FSharpList[Any] = fold(folder, FSharpList_get_Empty(), xs)
|
|
1540
1540
|
|
|
1541
|
-
def
|
|
1542
|
-
raise Exception(
|
|
1541
|
+
def _arrow92(__unit: Unit = UNIT) -> FSharpList[T]:
|
|
1542
|
+
raise Exception(SR_indexOutOfBounds + " (Parameter 'index')")
|
|
1543
1543
|
|
|
1544
|
-
return reverse(result if is_done else (append(ys_1, result) if ((i + int32.ONE) == index) else
|
|
1544
|
+
return reverse(result if is_done else (append(ys_1, result) if ((i + int32.ONE) == index) else _arrow92()))
|
|
1545
1545
|
|
|
1546
1546
|
|
|
1547
1547
|
def remove_at[T](index: int32, xs: FSharpList[T]) -> FSharpList[T]:
|
|
@@ -1560,7 +1560,7 @@ def remove_at[T](index: int32, xs: FSharpList[T]) -> FSharpList[T]:
|
|
|
1560
1560
|
|
|
1561
1561
|
ys: FSharpList[Any] = filter(f, xs)
|
|
1562
1562
|
if not is_done:
|
|
1563
|
-
raise Exception(
|
|
1563
|
+
raise Exception(SR_indexOutOfBounds + " (Parameter 'index')")
|
|
1564
1564
|
|
|
1565
1565
|
return ys
|
|
1566
1566
|
|
|
@@ -1593,7 +1593,7 @@ def remove_many_at[T](index: int32, count: int32, xs: FSharpList[T]) -> FSharpLi
|
|
|
1593
1593
|
)
|
|
1594
1594
|
if status_1 < int32.ONE:
|
|
1595
1595
|
raise Exception(
|
|
1596
|
-
|
|
1596
|
+
SR_indexOutOfBounds + ((" (Parameter '" + ("index" if (status_1 < int32.ZERO) else "count")) + "')")
|
|
1597
1597
|
)
|
|
1598
1598
|
|
|
1599
1599
|
return ys
|
|
@@ -1613,7 +1613,7 @@ def update_at[T](index: int32, y: T, xs: FSharpList[T]) -> FSharpList[T]:
|
|
|
1613
1613
|
|
|
1614
1614
|
ys: FSharpList[Any] = map_indexed(mapping, xs)
|
|
1615
1615
|
if not is_done:
|
|
1616
|
-
raise Exception(
|
|
1616
|
+
raise Exception(SR_indexOutOfBounds + " (Parameter 'index')")
|
|
1617
1617
|
|
|
1618
1618
|
return ys
|
|
1619
1619
|
|
|
@@ -20,7 +20,7 @@ from .types import FSharpRef as FSharpRef_1
|
|
|
20
20
|
from .util import UNIT, Disposable, Unit, dispose, equals, get_enumerator, ignore, nullable, to_enumerable
|
|
21
21
|
|
|
22
22
|
|
|
23
|
-
def
|
|
23
|
+
def _expr17(gen0: TypeInfo, gen1: TypeInfo) -> TypeInfo:
|
|
24
24
|
return class_type("Fable.Collections.Dictionary", Array([gen0, gen1]), Dictionary)
|
|
25
25
|
|
|
26
26
|
|
|
@@ -126,13 +126,13 @@ class Dictionary[KEY, VALUE](MutableMapping[Any, Any], Mapping[Any, Any], Enumer
|
|
|
126
126
|
def System_Collections_Generic_IDictionary_2_get_Keys(self, __unit: Unit = UNIT) -> ICollection[KEY]:
|
|
127
127
|
this: Dictionary[Any, Any] = self
|
|
128
128
|
|
|
129
|
-
def
|
|
130
|
-
def
|
|
129
|
+
def _arrow14(__unit: Unit = UNIT) -> IEnumerable_1[KEY]:
|
|
130
|
+
def _arrow13(pair: Any) -> KEY:
|
|
131
131
|
return pair[0]
|
|
132
132
|
|
|
133
|
-
return map(
|
|
133
|
+
return map(_arrow13, this)
|
|
134
134
|
|
|
135
|
-
return Array[Any](delay(
|
|
135
|
+
return Array[Any](delay(_arrow14))
|
|
136
136
|
|
|
137
137
|
def System_Collections_Generic_IDictionary_2_Remove2B595(self, key: KEY = UNIT) -> bool:
|
|
138
138
|
this: Dictionary[Any, Any] = self
|
|
@@ -152,13 +152,13 @@ class Dictionary[KEY, VALUE](MutableMapping[Any, Any], Mapping[Any, Any], Enumer
|
|
|
152
152
|
def System_Collections_Generic_IDictionary_2_get_Values(self, __unit: Unit = UNIT) -> ICollection[VALUE]:
|
|
153
153
|
this: Dictionary[Any, Any] = self
|
|
154
154
|
|
|
155
|
-
def
|
|
156
|
-
def
|
|
155
|
+
def _arrow16(__unit: Unit = UNIT) -> IEnumerable_1[VALUE]:
|
|
156
|
+
def _arrow15(pair: Any) -> VALUE:
|
|
157
157
|
return pair[1]
|
|
158
158
|
|
|
159
|
-
return map(
|
|
159
|
+
return map(_arrow15, this)
|
|
160
160
|
|
|
161
|
-
return Array[Any](delay(
|
|
161
|
+
return Array[Any](delay(_arrow16))
|
|
162
162
|
|
|
163
163
|
def get_item(self, key: KEY = UNIT) -> VALUE:
|
|
164
164
|
this: Dictionary[Any, Any] = self
|
|
@@ -205,7 +205,7 @@ class Dictionary[KEY, VALUE](MutableMapping[Any, Any], Mapping[Any, Any], Enumer
|
|
|
205
205
|
self.Remove(key)
|
|
206
206
|
|
|
207
207
|
|
|
208
|
-
Dictionary_reflection =
|
|
208
|
+
Dictionary_reflection = _expr17
|
|
209
209
|
|
|
210
210
|
|
|
211
211
|
def Dictionary__ctor_6623D9B3[KEY, VALUE](
|
|
@@ -219,20 +219,20 @@ def Dictionary__TryFindIndex_2B595[KEY, VALUE](this: Dictionary[KEY, VALUE], k:
|
|
|
219
219
|
match_value: tuple[bool, list[Any]]
|
|
220
220
|
out_arg: list[Any] = cast(list[Any], None)
|
|
221
221
|
|
|
222
|
-
def
|
|
222
|
+
def _arrow18(__unit: Unit = UNIT) -> list[Any]:
|
|
223
223
|
return out_arg
|
|
224
224
|
|
|
225
|
-
def
|
|
225
|
+
def _arrow19(v: list[Any]) -> None:
|
|
226
226
|
nonlocal out_arg
|
|
227
227
|
out_arg = v
|
|
228
228
|
|
|
229
|
-
match_value = (try_get_value(this.hash_map, h, FSharpRef(
|
|
229
|
+
match_value = (try_get_value(this.hash_map, h, FSharpRef(_arrow18, _arrow19)), out_arg)
|
|
230
230
|
if match_value[0]:
|
|
231
231
|
|
|
232
|
-
def
|
|
232
|
+
def _arrow20(pair: Any, this: Any = this, k: Any = k) -> bool:
|
|
233
233
|
return this.comparer.Equals(k, pair[0])
|
|
234
234
|
|
|
235
|
-
return (True, h, find_index(
|
|
235
|
+
return (True, h, find_index(_arrow20, match_value[1]))
|
|
236
236
|
|
|
237
237
|
else:
|
|
238
238
|
return (False, h, int32.NEG_ONE)
|
|
@@ -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
|
|
22
|
+
def _expr8(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 =
|
|
114
|
+
HashSet_reflection = _expr8
|
|
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
|
|
126
|
+
def _arrow10(__unit: Unit = UNIT) -> list[T]:
|
|
127
127
|
return out_arg
|
|
128
128
|
|
|
129
|
-
def
|
|
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(
|
|
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
|
|
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(
|
|
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
|
|
28
|
+
def _arrow79(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
|
|
40
|
+
return _arrow79
|
|
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
|
|
46
|
+
def _arrow80(start: Any = start) -> IEnumerable_1[T]:
|
|
47
47
|
return unfold(step_fn, start)
|
|
48
48
|
|
|
49
|
-
return delay(
|
|
49
|
+
return delay(_arrow80)
|
|
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
|
|
63
|
+
def _arrow81(x: float64, y: float64) -> float64:
|
|
64
64
|
return x + y
|
|
65
65
|
|
|
66
|
-
return integral_range_step(start, step, stop, float64(0.0),
|
|
66
|
+
return integral_range_step(start, step, stop, float64(0.0), _arrow81)
|
|
67
67
|
|
|
68
68
|
|
|
69
69
|
def range_int32(start: int32, step: int32, stop: int32) -> IEnumerable_1[int32]:
|
|
70
|
-
def
|
|
70
|
+
def _arrow82(x: int32, y: int32) -> int32:
|
|
71
71
|
return x + y
|
|
72
72
|
|
|
73
|
-
return integral_range_step(start, step, stop, int32.ZERO,
|
|
73
|
+
return integral_range_step(start, step, stop, int32.ZERO, _arrow82)
|
|
74
74
|
|
|
75
75
|
|
|
76
76
|
def range_uint32(start: uint32, step: uint32, stop: uint32) -> IEnumerable_1[uint32]:
|
|
77
|
-
def
|
|
77
|
+
def _arrow83(x: uint32, y: uint32) -> uint32:
|
|
78
78
|
return x + y
|
|
79
79
|
|
|
80
|
-
return integral_range_step(start, step, stop, uint32.ZERO,
|
|
80
|
+
return integral_range_step(start, step, stop, uint32.ZERO, _arrow83)
|
|
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
|
|
94
|
+
def _arrow84(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(
|
|
104
|
+
return delay(_arrow84)
|
|
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
|
|
15
|
+
def _expr9(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 =
|
|
43
|
+
FSharpResult_2_reflection = _expr9
|
|
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]:
|