@grain/stdlib 0.4.6 → 0.5.2

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 (85) hide show
  1. package/CHANGELOG.md +93 -0
  2. package/array.gr +18 -18
  3. package/array.md +18 -18
  4. package/bigint.gr +497 -0
  5. package/bigint.md +811 -0
  6. package/buffer.gr +59 -223
  7. package/buffer.md +24 -17
  8. package/bytes.gr +100 -202
  9. package/bytes.md +19 -0
  10. package/char.gr +63 -133
  11. package/exception.gr +28 -2
  12. package/exception.md +43 -0
  13. package/float32.gr +76 -95
  14. package/float32.md +69 -30
  15. package/float64.gr +81 -95
  16. package/float64.md +69 -30
  17. package/hash.gr +37 -37
  18. package/int32.gr +152 -198
  19. package/int32.md +104 -0
  20. package/int64.gr +151 -197
  21. package/int64.md +104 -0
  22. package/list.gr +467 -70
  23. package/list.md +1141 -0
  24. package/map.gr +192 -7
  25. package/map.md +525 -0
  26. package/number.gr +111 -54
  27. package/number.md +100 -3
  28. package/option.md +1 -1
  29. package/package.json +3 -3
  30. package/pervasives.gr +499 -59
  31. package/pervasives.md +1116 -0
  32. package/queue.gr +4 -0
  33. package/queue.md +10 -0
  34. package/random.gr +196 -0
  35. package/random.md +179 -0
  36. package/regex.gr +1833 -842
  37. package/regex.md +11 -11
  38. package/result.md +1 -1
  39. package/runtime/bigint.gr +2045 -0
  40. package/runtime/bigint.md +326 -0
  41. package/runtime/dataStructures.gr +99 -278
  42. package/runtime/dataStructures.md +391 -0
  43. package/runtime/debug.md +6 -0
  44. package/runtime/equal.gr +5 -23
  45. package/runtime/equal.md +6 -0
  46. package/runtime/exception.md +30 -0
  47. package/runtime/gc.gr +20 -3
  48. package/runtime/gc.md +36 -0
  49. package/runtime/malloc.gr +13 -11
  50. package/runtime/malloc.md +55 -0
  51. package/runtime/numberUtils.gr +91 -41
  52. package/runtime/numberUtils.md +54 -0
  53. package/runtime/numbers.gr +1049 -391
  54. package/runtime/numbers.md +300 -0
  55. package/runtime/string.gr +136 -230
  56. package/runtime/string.md +24 -0
  57. package/runtime/stringUtils.gr +58 -38
  58. package/runtime/stringUtils.md +6 -0
  59. package/runtime/unsafe/constants.gr +17 -0
  60. package/runtime/unsafe/constants.md +72 -0
  61. package/runtime/unsafe/conv.md +71 -0
  62. package/runtime/unsafe/errors.md +204 -0
  63. package/runtime/unsafe/memory.md +54 -0
  64. package/runtime/unsafe/printWasm.md +24 -0
  65. package/runtime/unsafe/tags.gr +9 -8
  66. package/runtime/unsafe/tags.md +120 -0
  67. package/runtime/unsafe/wasmf32.md +168 -0
  68. package/runtime/unsafe/wasmf64.md +168 -0
  69. package/runtime/unsafe/wasmi32.md +282 -0
  70. package/runtime/unsafe/wasmi64.md +300 -0
  71. package/runtime/utils/printing.gr +62 -0
  72. package/runtime/utils/printing.md +18 -0
  73. package/runtime/wasi.gr +1 -1
  74. package/runtime/wasi.md +839 -0
  75. package/set.gr +17 -8
  76. package/set.md +24 -21
  77. package/stack.gr +3 -3
  78. package/stack.md +4 -6
  79. package/string.gr +194 -329
  80. package/string.md +3 -3
  81. package/sys/file.gr +245 -429
  82. package/sys/process.gr +27 -45
  83. package/sys/random.gr +47 -16
  84. package/sys/random.md +38 -0
  85. package/sys/time.gr +11 -27
package/int64.md CHANGED
@@ -571,6 +571,32 @@ Returns:
571
571
  |----|-----------|
572
572
  |`Bool`|`true` if the first value is less than the second value or `false` otherwise|
573
573
 
574
+ ### Int64.**ltU**
575
+
576
+ <details disabled>
577
+ <summary tabindex="-1">Added in <code>0.5.0</code></summary>
578
+ No other changes yet.
579
+ </details>
580
+
581
+ ```grain
582
+ ltU : (Int64, Int64) -> Bool
583
+ ```
584
+
585
+ Checks if the first unsigned value is less than the second unsigned value.
586
+
587
+ Parameters:
588
+
589
+ |param|type|description|
590
+ |-----|----|-----------|
591
+ |`x`|`Int64`|The first value|
592
+ |`y`|`Int64`|The second value|
593
+
594
+ Returns:
595
+
596
+ |type|description|
597
+ |----|-----------|
598
+ |`Bool`|`true` if the first value is less than the second value or `false` otherwise|
599
+
574
600
  ### Int64.**gt**
575
601
 
576
602
  <details disabled>
@@ -597,6 +623,32 @@ Returns:
597
623
  |----|-----------|
598
624
  |`Bool`|`true` if the first value is greater than the second value or `false` otherwise|
599
625
 
626
+ ### Int64.**gtU**
627
+
628
+ <details disabled>
629
+ <summary tabindex="-1">Added in <code>0.5.0</code></summary>
630
+ No other changes yet.
631
+ </details>
632
+
633
+ ```grain
634
+ gtU : (Int64, Int64) -> Bool
635
+ ```
636
+
637
+ Checks if the first unsigned value is greater than the second unsigned value.
638
+
639
+ Parameters:
640
+
641
+ |param|type|description|
642
+ |-----|----|-----------|
643
+ |`x`|`Int64`|The first value|
644
+ |`y`|`Int64`|The second value|
645
+
646
+ Returns:
647
+
648
+ |type|description|
649
+ |----|-----------|
650
+ |`Bool`|`true` if the first value is greater than the second value or `false` otherwise|
651
+
600
652
  ### Int64.**lte**
601
653
 
602
654
  <details disabled>
@@ -623,6 +675,32 @@ Returns:
623
675
  |----|-----------|
624
676
  |`Bool`|`true` if the first value is less than or equal to the second value or `false` otherwise|
625
677
 
678
+ ### Int64.**lteU**
679
+
680
+ <details disabled>
681
+ <summary tabindex="-1">Added in <code>0.5.0</code></summary>
682
+ No other changes yet.
683
+ </details>
684
+
685
+ ```grain
686
+ lteU : (Int64, Int64) -> Bool
687
+ ```
688
+
689
+ Checks if the first unsigned value is less than or equal to the second unsigned value.
690
+
691
+ Parameters:
692
+
693
+ |param|type|description|
694
+ |-----|----|-----------|
695
+ |`x`|`Int64`|The first value|
696
+ |`y`|`Int64`|The second value|
697
+
698
+ Returns:
699
+
700
+ |type|description|
701
+ |----|-----------|
702
+ |`Bool`|`true` if the first value is less than or equal to the second value or `false` otherwise|
703
+
626
704
  ### Int64.**gte**
627
705
 
628
706
  <details disabled>
@@ -649,6 +727,32 @@ Returns:
649
727
  |----|-----------|
650
728
  |`Bool`|`true` if the first value is greater than or equal to the second value or `false` otherwise|
651
729
 
730
+ ### Int64.**gteU**
731
+
732
+ <details disabled>
733
+ <summary tabindex="-1">Added in <code>0.5.0</code></summary>
734
+ No other changes yet.
735
+ </details>
736
+
737
+ ```grain
738
+ gteU : (Int64, Int64) -> Bool
739
+ ```
740
+
741
+ Checks if the first unsigned value is greater than or equal to the second unsigned value.
742
+
743
+ Parameters:
744
+
745
+ |param|type|description|
746
+ |-----|----|-----------|
747
+ |`x`|`Int64`|The first value|
748
+ |`y`|`Int64`|The second value|
749
+
750
+ Returns:
751
+
752
+ |type|description|
753
+ |----|-----------|
754
+ |`Bool`|`true` if the first value is greater than or equal to the second value or `false` otherwise|
755
+
652
756
  ## Bitwise logic
653
757
 
654
758
  Boolean operations on the bits of Int64 values.