Commit Graph

6349 Commits

Author SHA1 Message Date
gingerBill
145dac5b75 Merge pull request #5016 from Barinzaya/fix-math-nextafter
Fix `math.nextafter` skipping from 0 to 1
2025-04-08 13:13:51 +01:00
Jeroen van Rijn
d77b8aeaa1 Merge pull request #5018 from Barinzaya/fix-fmt-bitset-nonzero-enum
Fix printing of `bit_set[Enum]` when `min(Enum) != 0`
2025-04-07 22:01:19 +02:00
Barinzaya
92ac86ae3c Fixed fmt handling of bit_set[Enum] when min(Enum) != 0.
The lower bound of the `bit_set` was only being applied *after*
searching for a matching enum value, so values wouldn't line up if the
minimum value of the enum wasn't 0.
2025-04-07 15:41:21 -04:00
Jeroen van Rijn
716bd479a9 Disallow .Multiline in iterator. 2025-04-07 21:33:57 +02:00
Barinzaya
bffa0eaa58 Fixed math.nextafter procs skipping from 0 to 1. 2025-04-07 13:38:10 -04:00
Jeroen van Rijn
2b26c0b39e Remove now unused field. 2025-04-07 15:02:36 +02:00
Jeroen van Rijn
a5e513567b Optimize regex match iterator.
Reuse virtual machine and capture groups between matches.
2025-04-07 14:58:41 +02:00
Jeroen van Rijn
c13b68f103 Fix os2/process defer error. 2025-04-07 13:33:21 +02:00
Jeroen van Rijn
3287e1b0f0 Fix HXA defer warning 2025-04-07 13:19:00 +02:00
Jeroen van Rijn
9a2b6c01aa Return loop index in regex iterator. 2025-04-06 21:45:37 +02:00
Jeroen van Rijn
66077add33 {.Glboal} implicit in regex allocator. 2025-04-06 21:13:02 +02:00
Jeroen van Rijn
cdc56dc691 Add iterator for core:text/regex.
Usage:
```odin
haystack := `xxfoobarxfoobarxx`
pattern  := `f(o)ob(ar)`

it := regex.create_iterator(haystack, pattern, {.Global}) or_return
defer regex.destroy(it)

for capture in regex.match(&it) {
	fmt.println(capture)
}
```
2025-04-06 14:19:14 +02:00
Jeroen van Rijn
a6977ac733 Remove stray import. 2025-04-05 19:25:39 +02:00
Jeroen van Rijn
4b203d0c78 Fix segfault in core:sys/info on WSL2 2025-04-05 19:23:58 +02:00
Jeroen van Rijn
8d283cefa0 Merge pull request #5007 from laytan/net-errors-overhaul
net: rework errors to be cross-platform
2025-04-05 17:53:10 +02:00
Laytan Laats
ff7d55a8e1 net: rework errors to be cross-platform 2025-04-05 17:35:19 +02:00
Jeroen van Rijn
f7c4c80ef3 Fix broken examples in documentation tester.
No more:
```
We could not find the procedure "pkg_foo_example :: proc()" needed to test the example created for "pkg.foo"
The following procedures were found:
   bar()
```
2025-04-05 16:36:26 +02:00
Jeroen van Rijn
8480295b60 Merge pull request #4993 from Sojamann/small-array-doc
[DOC] Add documentation for package core:container/small_array
2025-04-05 15:49:51 +02:00
Robin Bergewski
e963ba12fc core:container/small_array: add package documentation 2025-04-05 15:38:42 +02:00
Harold Brenes
c5980ba6c4 Add linux build tag to core/sys/linux/sys.odin 2025-04-02 16:39:25 -04:00
gingerBill
70ddb74e40 Add mem.make_over_aligned 2025-03-31 10:51:02 +01:00
gingerBill
dcb683927e Fix indentation 2025-03-31 10:40:03 +01:00
gingerBill
08ad2d20cd Merge pull request #4986 from hardliner66/bugfix/use_correct_size_when_resolving_symbols
Use the proper size for SizeOfStruct to make resolving of procedure names work
2025-03-30 22:28:19 +01:00
Steve Biedermann
61610fa033 Use the proper size for SizeOfStruct 2025-03-30 18:11:41 +02:00
Laytan Laats
327d9f134d net: drop core:os dependency for Darwin 2025-03-29 23:27:03 +01:00
Dave Voutila
18988b5f94 Fix use of errno on OpenBSD. 2025-03-27 10:36:40 -04:00
Jonathan Tron
1b5e83bfb6 Prevent odin.js from printing empty line in the console for the ending "\n" 2025-03-26 21:58:58 +01:00
Jeroen van Rijn
660598ca8a Fix #4968 2025-03-25 12:01:02 +01:00
gingerBill
2b8c76354d Use copy over intrinsics.mem_copy_non_overlapping 2025-03-24 11:31:05 +00:00
gingerBill
4a595f9dac Merge pull request #4954 from Feoramund/os2-path
Add new path API for `os2`
2025-03-24 11:19:21 +00:00
gingerBill
6fd752f647 Merge pull request #4959 from wisonye/master
Fixed: Freebsd syscall 'getpeername' is missing.
2025-03-24 10:10:15 +00:00
Yawning Angel
38665431dd core/crypto/_aes/ct64: Disable bounds checking 2025-03-23 19:17:18 +09:00
Yawning Angel
2f301e46dc core/crypto: Switch to using ensure 2025-03-23 19:14:33 +09:00
Yawning Angel
dc94452fb9 core/crypto/blake2: Add the ability to easily alter digest size 2025-03-23 19:14:33 +09:00
Yawning Angel
93951ac72a core/crypto/sha2: Clean up the portable code slightly 2025-03-23 19:14:33 +09:00
Yawning Angel
982ab11aa1 core/crypto/sha2: Use hardware SHA224/256 when available (AMD64) 2025-03-23 19:14:33 +09:00
Yawning Angel
b220df60b8 core:crypto/deoxysii: Initial import 2025-03-23 19:14:33 +09:00
Yawning Angel
c2786a6dd5 core/crypto/aegis: Initial import 2025-03-23 19:14:33 +09:00
Yawning Angel
9fdcc4e39a core/crypto/x448: Initial import 2025-03-23 19:14:33 +09:00
Yawning Angel
bb395aeb41 core/crypto: Add rodata annotations (NFC) 2025-03-23 19:14:33 +09:00
Yawning Angel
50d40c2a26 core/crypto/chacha20poly1305: Add missing assertions 2025-03-23 19:14:33 +09:00
Yawning Angel
6e8710fce4 core/crypto/chacha20: Misc Simd128 improvements
- Detect the RISC-V `v` profile
- Don't bother trying to process 4 blocks at a time if emulated
2025-03-23 19:14:33 +09:00
Yawning Angel
e4e76f27f6 core/crypto: Use panic_contextless instead of intrinsics.trap 2025-03-23 19:14:33 +09:00
Yawning Angel
4c28f6d170 core/crypto/_aes/hw_intel: Fix comment (NFC) 2025-03-23 19:14:33 +09:00
Wison Ye
61acb15529 #4959, fixed the broken CI build. 2025-03-23 13:32:11 +13:00
Wison Ye
2af691f587 Fixed: Freebsd syscall 'getpeername' is missing. 2025-03-23 13:22:19 +13:00
Barinzaya
7819797a03 Split mem.make_map to match the runtime procs.
The existing `mem.make_map` passes a capacity, but the builtin
`make_map` no longer takes a capacity--it was separated to
`make_map_cap` to allow for making a map without an allocation (#4340).

`core:mem` was not updated to reflect this, so any usage of `mem.make`
to make a map will currently result in a compile error.
2025-03-22 11:03:04 -04:00
Wison Ye
17a01dcebf Merge remote-tracking branch 'upstream/master' 2025-03-22 17:52:43 +13:00
Wison Ye
01e81fe597 Fixed #4892: 'EPoll_Event.events' should be bit set. 2025-03-22 17:51:08 +13:00
Laytan Laats
e4bc9677af fix unmarshalling bit sets in json
Fixes #4761
2025-03-22 00:20:00 +01:00