Book-reader
9bc5e259d2
fix types::may_load_atomic with enums
2025-06-07 13:54:27 +02:00
Christoffer Lerno
5e45c34f21
- Deprecate String.is_zstr and String.quick_zstr #2188 .
2025-06-06 15:30:46 +02:00
Christoffer Lerno
f2daf2e11e
@sprintf macro (based on the $$sprintf builtin) allows compile time format strings #1874 .
2025-06-06 03:18:28 +02:00
Christoffer Lerno
c9d9127da6
Deprecate foo.#bar.
2025-06-05 12:51:35 +02:00
Christoffer Lerno
7f85534414
- Implicitly convert from constant typeid to Type in $Type assignment, and $assignable.
...
- Make $Type parameters accept constant typeid values.
2025-06-05 00:37:16 +02:00
Christoffer Lerno
8fc01d4e1a
Simplify contract macros.
2025-06-02 22:53:06 +02:00
Christoffer Lerno
4d848f1707
Incorrect ensure on String.split.
2025-06-01 20:28:32 +02:00
Christoffer Lerno
b5ddc36d7f
Limit vector max size, default is 4096 bits, but may be increased using --max-vector-size.
2025-05-23 21:40:14 +02:00
Christoffer Lerno
b7ae5dce8b
Deprecate MyEnum.elements.
2025-05-16 16:12:37 +02:00
Christoffer Lerno
91db6ceeda
Defining an enum like ABC = { 1 2 } was accidentally allowed.
2025-05-16 09:56:08 +02:00
Christoffer Lerno
b83e57b952
Added @rnd() compile time random function (using the $$rnd() builtin). #2078
2025-05-15 00:51:33 +02:00
DragonFriend
50b4d7aa35
Add replace and treplace to String ( #2127 )
...
* Add replace and treplace functions to String
2025-05-14 11:00:20 +02:00
Christoffer Lerno
abe4727c3a
Deprecate uXX and iXX bit suffixes.
...
Add experimental LL / ULL suffixes for int128 and uint128 literals.
2025-05-13 23:48:59 +02:00
Christoffer Lerno
634438eb82
Cleanup.
2025-05-08 21:05:43 +02:00
Christoffer Lerno
164c901ae6
More comments on the allocators.
2025-05-07 12:52:19 +02:00
Christoffer Lerno
d313afa487
Add String.count to count the number of instances of a string.
2025-05-02 21:48:04 +02:00
Christoffer Lerno
8a0907cb70
Add String.tokenize_all to replace the now deprecated String.splitter
2025-05-02 20:51:15 +02:00
Christoffer Lerno
8a09b2e5f7
std::ascii moved into std::core::ascii. Old _m variants are deprecated, as is uint methods.
2025-05-02 18:06:28 +02:00
Christoffer Lerno
bfccc303d1
Added comments.
2025-05-02 13:36:46 +02:00
Christoffer Lerno
0d3299f267
Added String.quick_ztr and String.is_zstr
2025-05-02 13:22:13 +02:00
Christian Buttner
0595270d9a
Fix mem::copy_inline compile.
2025-04-25 16:04:41 +02:00
Christoffer Lerno
8b47673524
Added Enum.lookup and Enum.lookup_field.
2025-04-25 14:44:00 +02:00
Christoffer Lerno
8a2907806b
Fixes to tclone and other temp allocations with overaligned data.
2025-04-20 21:30:36 +02:00
Christoffer Lerno
f778e75757
Added missing @clone_aligned and add checks to @tclone
2025-04-20 18:31:52 +02:00
joshringuk@gmail.com
434a0e8e4b
array contains
2025-04-18 18:15:01 +02:00
Boris Barbulovski
b5d0739de0
Add env::ANDROID to std.*
2025-04-16 17:47:49 +02:00
Christoffer Lerno
e7c9ec0938
Added comments.
2025-04-16 01:32:01 +02:00
Christoffer Lerno
d6fa9cd50b
Added some comments about the tracking allocator.
2025-04-15 16:03:12 +02:00
Christoffer Lerno
41e173d255
Added some comment about the temp allocator.
2025-04-15 15:53:11 +02:00
Christoffer Lerno
0a9bb2e8e0
Fix to simple a += b overload fallback. Renaming and reordering in the stdlib.
2025-04-15 12:01:58 +02:00
Christoffer Lerno
f85198e3ee
Added += and related as overloads. Updated tests and docs. Slice2 extracted to its own file.
2025-04-14 00:55:46 +02:00
Christoffer Lerno
28fc03c376
Do not user finalizer with wasm
2025-04-08 00:03:35 +02:00
Christoffer Lerno
1290906d66
Setup temp allocator by default on Wasm
2025-04-07 23:35:38 +02:00
Christoffer Lerno
25d416aca1
Regression with invalid setup of the WASM temp allocator.
2025-04-07 21:58:21 +02:00
Christoffer Lerno
3cb5df5639
0.7 fixes. Improving the yacc grammar.
2025-04-04 18:14:16 +02:00
Sander van den Bosch
561a683230
Added .hash() functions for vectors ( #2043 )
...
* Added .hash() functions for vectors
* Update test to a non-zero sized vector
* Changed vector hash functions to hash the underlying bytes in a char slice, the same approch is used for arrays
* Added test for hashed
* Updated formatting to be consistant with C3 code style
* Formatting, use "self"
---------
Co-authored-by: Christoffer Lerno <christoffer@aegik.com >
2025-03-31 16:33:48 +02:00
Christoffer Lerno
ff2809a3ac
Fix of regression in @assert_leak.
2025-03-25 22:11:47 +01:00
Maxime Beaudoin
a8554b4233
String.c3 function parameters ambiguous ( #2061 )
...
* Some tweaks. Fixes regression in `format`
---------
Co-authored-by: Christoffer Lerno <christoffer@aegik.com >
2025-03-25 14:25:23 +01:00
Christoffer Lerno
fa707db078
Do not implicitly convert enums to ordinal in formatting functions.
2025-03-25 12:27:51 +01:00
Christoffer Lerno
439349ceb8
Move dynamic dispatch lowering.
2025-03-25 00:20:01 +01:00
Christoffer Lerno
82f1b543ed
&self not runtime null-checked in macro #1827 . Regression in temp allocators.
2025-03-23 22:50:09 +01:00
walther chen
b48588ca8f
improve error message for uninitialized temp allocator pool on new
...
threads
2025-03-23 22:15:42 +01:00
Christoffer Lerno
a03d821602
- Use @pool_init() to set up a temp pool on a thread. Only the main thread has implicit temp pool setup.
...
- `tmem` is now a variable.
2025-03-21 17:08:58 +01:00
Christoffer Lerno
de74e97ab1
Fixes to temp allocator.
2025-03-18 19:58:16 +01:00
Christoffer Lerno
7e100472e7
- AnyList now also defaults to the temp allocator.
...
- `os::getcwd` and `os::get_home_dir` requires an explicit allocator.
- `file::load_new` and `file::load_path_new` removed.
2025-03-18 18:34:52 +01:00
Christoffer Lerno
72608ce01d
- Temp allocator now supports more than 2 in-flight stacks.
...
- Printing stacktrace uses its own temp allocator.
- `@pool` no longer takes an argument.
- `Allocator` interface removes `mark` and `reset`.
- DynamicArenaAllocator has changed init function.
- Added `BackedArenaAllocator` which is allocated to a fixed size, then allocates on the backing allocator and supports mark/reset.
2025-03-18 15:16:22 +01:00
Christoffer Lerno
425676a98d
Bug due to missing cast when doing $i[$x] = $z.
...
Added `math::iota`.
2025-03-16 10:58:13 +01:00
Christoffer Lerno
5c77c9a754
- Change distinct -> typedef.
...
- Order of attribute declaration is changed for `alias`.
- Added `LANGUAGE_DEV_VERSION` env constant.
- Rename `anyfault` -> `fault`.
- Changed `fault` -> `faultdef`.
- Added `attrdef` instead of `alias` for attribute aliases.
2025-03-15 20:10:47 +01:00
Christoffer Lerno
8b49e6c14d
Rename def to alias.
2025-03-13 11:22:27 +01:00
Christoffer Lerno
b8ae2b06d6
Rename @return! to @return?
2025-03-12 21:40:30 +01:00