cef98a8a18
Update some docs
2024-08-10 16:53:12 -04:00
586bf82848
Move docs to docs
2024-08-10 16:44:45 -04:00
926995f58d
Bugfix for Text:split()
2024-08-10 16:41:23 -04:00
948d6b4c22
Add array:counts()
2024-08-10 16:36:50 -04:00
4265728cbb
Add Array:unique() to get a set of unique items
2024-08-10 16:19:36 -04:00
b64ec73b03
Update learnxiny to use new table syntax
2024-08-10 16:13:29 -04:00
b37bd70b60
For tables, deprecate support for square bracket indexing and .default
...
values, replacing them with a `:bump()` function for tables with numeric
values. This means that counters can be implemented easily without the
need to mask complexity.
2024-08-10 16:03:41 -04:00
671f81137e
Make Num32/Num64 literals explicitly typed to aid in macros using
...
__typeof
2024-08-10 16:03:00 -04:00
8d3d591312
Add Sets to the language
2024-08-10 15:15:38 -04:00
cb6cebf12e
Add test for iterators
2024-08-10 14:52:53 -04:00
416300287f
Add test for ranges
2024-08-10 14:52:42 -04:00
df7a8508c8
Move docs
2024-08-10 14:26:41 -04:00
3b1d88ab93
Bugfix for table literals with duplicated keys
2024-08-10 14:20:54 -04:00
f78cd6357a
Change table removal function to use values instead of references
2024-08-08 13:20:38 -04:00
c045c54309
Add a Range datatype with creation methods like 5:to(10)
and
...
modification methods like `range:by(2)` or `range:reversed()`
2024-08-05 14:40:28 -04:00
8e2156ac48
Guard against tables exceeding maximum supported size
2024-08-04 18:28:18 -04:00
7300049867
Switch to TABLE_INCREF
2024-08-04 17:31:33 -04:00
7fd74553f8
More refcount fixes
2024-08-04 17:27:43 -04:00
d7e3d399d6
Fix up some edge cases with refcounting
2024-08-04 17:25:54 -04:00
43501f7bec
Minor fix for array refcounting
2024-08-04 17:23:42 -04:00
fa0dee19e2
Add comment
2024-08-04 17:02:29 -04:00
aa218fe872
Tweak bits
2024-08-04 15:01:27 -04:00
cb44b09715
Tweak reallocation heuristics for arrays
2024-08-04 14:58:09 -04:00
7a649b145e
Bugfix for tests
2024-08-04 14:57:22 -04:00
ff4ea60daf
Tweaks to array implementation, including changing how the bits are
...
allocated, making more explicit checks for refcounts and max values,
optimizations for certain methods, and adding compile-time errors for
arrays that hold items that are too large.
2024-08-04 14:22:58 -04:00
adccc56880
Switch around some of the logic for array:random() and array:shuffle()
...
to use Int$random() and return values
2024-08-04 13:03:55 -04:00
09204f4ce8
Revert "Fix array:random() to return a random item using correct RNG logic,"
...
This reverts commit 68b34cf00b
.
2024-08-03 17:44:22 -04:00
8357d02992
Make default table removal behavior deterministic, but have caches
...
explicitly use random eviction.
2024-08-03 17:42:45 -04:00
68b34cf00b
Fix array:random() to return a random item using correct RNG logic,
...
rather than a reference.
2024-08-03 17:33:18 -04:00
99b00530ce
Change structs/enums so they allow for field/tag names that are C
...
keywords
2024-08-03 16:39:04 -04:00
17be975d3a
Fix integer random functions so they correctly handle all representable
...
ranges
2024-08-03 16:23:28 -04:00
46396646bf
Add proper error check for heap popping
2024-08-03 15:36:40 -04:00
167634eaa4
Change array API to take a padded item size instead of a type info in
...
most cases
2024-08-03 15:33:50 -04:00
16c2e3f590
Incrementally moving towards passing array entry sizes explicitly
2024-08-03 15:06:59 -04:00
52544344f1
Fix bug caused by not handling item padding properly
2024-08-03 14:52:49 -04:00
2b9bec18a4
Fix for stride overflows in arrays
2024-08-03 14:40:56 -04:00
b2e752ee32
Replace heap_str with GC_strdup
2024-07-26 13:30:24 -04:00
cfe46ee393
Replace heap_strn() with GC_strndup()
2024-07-26 13:28:18 -04:00
87785555ec
Fix for order of operations issues with enum and function typedef code
2024-07-23 19:46:42 -04:00
09ea357f46
Update string docs
2024-07-23 14:29:23 -04:00
6467e6c9d0
Tweak Make deps
2024-07-23 12:27:14 -04:00
9ac51bf2f3
Add headers to make deps
2024-07-23 12:25:54 -04:00
7911df8294
Make sure array slicing doesn't require a pointer and disallow automatic
...
stackifying of values
2024-07-22 13:54:03 -04:00
5b0a841db6
Fix edge case with iterating over array:from(-999)
2024-07-20 17:20:50 -04:00
279cd23143
Micro optimization for iterating over array ranges
2024-07-20 17:13:15 -04:00
fb95bbb1d4
Deprecate array:pairs() and switch iterator functions to use enums
2024-07-20 16:45:13 -04:00
907122a049
Fix for unqualified enum names as return values
2024-07-19 14:16:51 -04:00
d3f14cf53c
Support nested lambda closures
2024-07-14 14:13:23 -04:00
4e6d8162bf
Fix issue with bindings inside closures
2024-07-14 13:22:42 -04:00
9fec3a6adb
Fix for reductions over iterators like (+) range(5, 10)
2024-07-13 19:58:21 -04:00