gingerBill
16c5c69a40
Merge pull request #4175 from laytan/riscv-compiler
...
Support RISC-V for the compiler itself
2024-09-02 00:20:04 +01:00
gingerBill
39b49cb6fb
Merge pull request #4176 from Feoramund/fix-context-error-msg
...
Remove extra format item at end of `context` error message
2024-09-02 00:18:15 +01:00
Feoramund
9871ad5fc8
Remove extra format item at end of context error message
2024-09-01 17:50:50 -04:00
Laytan
28c643d23f
riscv compiler support
2024-09-01 21:42:47 +02:00
Jeroen van Rijn
dd1f151696
Add math.remap_clamped.
2024-09-01 17:22:58 +02:00
Jeroen van Rijn
c1605b5b4f
Merge pull request #4173 from karl-zylinski/clamp-remap
...
Make math.remap clamp the result in range [new_min, new_max]
2024-09-01 16:54:17 +02:00
Karl Zylinski
6e150d1d58
Make math.remap clamp the result in range [new_min, new_max].
2024-09-01 16:30:48 +02:00
Laytan
722b638e2c
"fix" #4169 , looks like llvm 14 bug
2024-08-31 19:40:05 +02:00
Jeroen van Rijn
c1cb1a3d7e
Simplified #assert check
2024-08-31 19:13:37 +02:00
Jeroen van Rijn
a4ac50a5b4
Check for #assert condition to be a constant bool
...
Fixes #4170
2024-08-31 19:06:17 +02:00
gingerBill
6ba1506aa9
Fix possible leaks in os2.user_* calls
2024-08-31 15:12:47 +01:00
gingerBill
b4bdb73158
Fix new(sync.Mutex)
2024-08-31 15:06:20 +01:00
gingerBill
476030dd28
Fix #4156
2024-08-31 13:51:35 +01:00
Laytan Laats
e0a2e52601
c/libc: fix time link name
2024-08-31 02:49:53 +02:00
Laytan Laats
7f3d8e115f
remove comma
2024-08-31 02:45:17 +02:00
Laytan
584e8859bf
Merge pull request #4168 from laytan/fix-bad-import-name-errors
...
fix some issues with the "bad import name" errors
2024-08-31 02:44:16 +02:00
Laytan Laats
8e855155fd
fix bad import
2024-08-31 02:38:07 +02:00
Laytan Laats
7624ecf4ba
fix some issues with the "bad import name" errors
...
There was so much wrong here:
- The `if` statement was never entered because even on invalid import
names `path_to_entity_name` returns "_"
- Two errors were shown where one doesn't make sense, need to choose one
based on context
- Structure of the messages were different from other error messages
- Suggestion was using the wrong import path
2024-08-31 02:30:32 +02:00
Laytan Laats
bfedcd7035
encoding/csv: fix examples
2024-08-30 23:31:31 +02:00
Laytan Laats
6ef49d4f24
core/odin: support #type_assert and #no_type_assert
2024-08-30 23:21:35 +02:00
Jeroen van Rijn
8ad4427a25
Add a few more reflect.bit_field_* helpers.
2024-08-30 22:40:14 +02:00
Jeroen van Rijn
db3bcd2cea
Add reflect.bit_fields_zipped
2024-08-30 22:04:10 +02:00
Jeroen van Rijn
3072a02d5d
Attempt to account for BuildTools installer's lack of \
2024-08-30 18:54:51 +02:00
gingerBill
773703bc83
Merge pull request #4009 from thetarnav/file-tag-parser
...
Add a file tag parser to core:odin/parser
2024-08-30 11:58:18 +01:00
gingerBill
a4e865f90b
Fix #4166
2024-08-30 11:01:06 +01:00
gingerBill
9197a126fc
Use XOR directly rather than (~x) & mask
2024-08-30 10:52:11 +01:00
gingerBill
38ea276231
Make ~some_bit_set work on only the possible bits by doing a mask with the full set
2024-08-30 10:48:21 +01:00
gingerBill
b020b91df2
Merge pull request #4112 from Feoramund/fix-test-io-issues
...
Add `core:io` test suite
2024-08-30 09:57:02 +01:00
gingerBill
291048cb3b
Merge pull request #4165 from avanspector/master
...
Add missing lexer checking delay for foreign blocks
2024-08-30 09:56:36 +01:00
avanspector
3135c89a0a
Merge branch 'master' of https://github.com/avanspector/Odin
2024-08-30 01:32:21 +02:00
avanspector
47f423c123
Set a flag for delayed checking
2024-08-30 01:32:06 +02:00
avanspector
a7a2611efc
Merge branch 'odin-lang:master' into master
2024-08-29 23:44:14 +02:00
avanspector
9866c83d61
Add missing checker delaying
2024-08-29 23:43:01 +02:00
Damian Tarnawski
655610ec87
Satisfy vet
2024-08-29 23:06:50 +02:00
Damian Tarnawski
a28d574272
Add and test match_build_tags
2024-08-29 23:02:49 +02:00
Damian Tarnawski
f93779d425
Parse build_project_name as [][]string
2024-08-29 22:08:01 +02:00
Damian Tarnawski
a10f988020
Move some types to runtime, use reflection instead of lut
2024-08-29 21:12:33 +02:00
Damian Tarnawski
39bdf4d710
Add missing require_results attr
2024-08-29 20:52:27 +02:00
Damian Tarnawski
7862460374
Remove useless code
2024-08-29 20:52:27 +02:00
Damian Tarnawski
92821300e4
Add a file tag parser to core:odin/parser
2024-08-29 20:52:27 +02:00
Laytan
94a1a7aed5
Merge pull request #4164 from laytan/virtual-growing-min-block-size-fix
...
mem/virtual: make sure the given size is used for subsequent blocks
2024-08-29 18:27:54 +02:00
Laytan Laats
5a22d49b72
mem/virtual: make sure the given size is used for subsequent blocks
2024-08-29 14:48:36 +02:00
Laytan
942017b958
Merge pull request #4163 from laytan/sysconf-pagesize
...
mem/virtual: use `sysconf` for retrieving page size and actually use these init procs
2024-08-29 14:44:54 +02:00
Laytan Laats
fd2ad20cd4
mem/virtual: use sysconf for retrieving page size and actually use these init procs
2024-08-29 14:36:32 +02:00
Laytan Laats
cca385209b
Remove double close
2024-08-28 19:53:20 +02:00
Laytan Laats
fe2d256468
Properly close the temporary files in io tests
2024-08-28 19:53:20 +02:00
Laytan Laats
0f2ad95014
Fix EOF detection is os2 window read
2024-08-28 19:53:20 +02:00
Feoramund
7fa2e56cd9
Add io tests for bufio streams
2024-08-28 19:53:20 +02:00
Feoramund
24a53c246f
Make sure seek succeeds in io.Limited_Reader test setup
2024-08-28 19:53:20 +02:00
Feoramund
b11fa90ed2
Test empty slice usage in io procs
2024-08-28 19:53:20 +02:00
Feoramund
f453054aff
Return 0, nil in all io cases where an empty slice is provided
2024-08-28 19:53:20 +02:00
Feoramund
ef99373c31
Fix pread and pwrite on os2 Windows
...
The previous code was jumping ahead by the specified offset, instead of
getting the current offset.
2024-08-28 19:53:20 +02:00
Feoramund
1cd5cbb0e4
Test io unexpected pointer movement
2024-08-28 19:53:20 +02:00
Feoramund
56f232e5fc
Report invalid whence & offset on os2 Windows
2024-08-28 19:53:20 +02:00
Feoramund
de1432b315
Fix Windows infinite recursion with os2._flush
2024-08-28 19:53:20 +02:00
Feoramund
e7d6e2d163
Add documentation to os2.close
...
Make it explicit that using a stream after closing is like a
use-after-free bug.
2024-08-28 19:53:20 +02:00
Feoramund
8b40be50b9
Update core:io tests
...
- Relax return value requirements on errors. Only the error is checked,
as there are multiple conflicting return styles throughout the `os`
API.
Some return the error along with `0`, `-1`, or another value. This can
be smoothed out later.
- Test `os2` files now.
- No longer test streams after closing; this is considered similar to a
use-after-free in `os2`.
2024-08-28 19:53:20 +02:00
Feoramund
6798d15ecb
Check int(abs) instead to avoid overflows
2024-08-28 19:53:20 +02:00
Feoramund
6aedb2695a
Report Invalid_Whence on some os platforms
...
- Move `Seek`-related checks into OS-specific files for granularity.
Platforms:
- Darwin
- FreeBSD
- Haiku
- Linux
- NetBSD
- OpenBSD
2024-08-28 19:53:20 +02:00
Feoramund
0243647e15
Add missing flush functionality to os platforms
...
Platforms:
- FreeBSD
- Haiku
- Linux
- NetBSD
- OpenBSD
2024-08-28 19:53:20 +02:00
Feoramund
3ec4db212b
Report Invalid_Whence in os2 Linux seek
2024-08-28 19:53:20 +02:00
Feoramund
7683c1f4bb
Report Invalid_Whence in os2 POSIX seek
2024-08-28 19:53:20 +02:00
Feoramund
ef2cd9d97f
Copy missing errors in os2._get_platform_error from posix to linux
2024-08-28 19:53:20 +02:00
Feoramund
5b9e9fb822
Add test suite for core:io
2024-08-28 19:53:20 +02:00
Feoramund
741ccd7ff5
Zero n on error in _file_stream_proc
2024-08-28 19:53:20 +02:00
Feoramund
eb92a2df71
Fix indentation
2024-08-28 19:53:20 +02:00
Feoramund
d60f404bb4
Fix OpenBSD implementations of read_at and write_at
2024-08-28 19:53:20 +02:00
Feoramund
6c4806835c
Fix indentation
2024-08-28 19:53:20 +02:00
Feoramund
e1555e04ad
Fix Haiku implementations of read_at and write_at
2024-08-28 19:53:20 +02:00
Feoramund
7061032db6
Fix NetBSD implementations of read_at and write_at
...
These procedures must not modify the underlying file pointer.
2024-08-28 19:53:20 +02:00
Feoramund
861d892ffe
Make Windows pread and pwrite conform to POSIX
2024-08-28 19:53:20 +02:00
Feoramund
5c8c63ae04
Fix FreeBSD implementations of read_at and write_at
...
These procedures must not modify the underlying file pointer.
2024-08-28 19:53:20 +02:00
Feoramund
1ced76cdd1
Fix broken cases of Seek usage in _file_stream_proc
...
Handles `EINVAL`, among other fixes.
2024-08-28 19:53:20 +02:00
Feoramund
e83b982afe
Measure bytes.Buffer size by length instead of capacity
2024-08-28 19:53:20 +02:00
Feoramund
7c6cc81041
Add Seek behavior to bytes.Buffer
2024-08-28 19:53:20 +02:00
Feoramund
521e47ffee
Don't invalidate prev_rune if Reader seek failed
2024-08-28 19:53:20 +02:00
Feoramund
8251f4d7d0
Return .EOF in bytes.buffer_read_at instead
...
This is consistent with the other stream `read` procs
2024-08-28 19:53:20 +02:00
Feoramund
da49f7eb4e
Make bytes.reader_init return an io.Stream
...
Makes the API like the other stream `init` procs.
2024-08-28 19:53:20 +02:00
Feoramund
d66486c17e
Make io.Section_Reader set base too
...
This should fix seeking from `.Start`, getting the `size`, and
`read_at`.
Also make the API consistent with the other `*_init` procs in
`util.odin` by returning the `io.Reader`.
2024-08-28 19:53:20 +02:00
Feoramund
981a2e1a00
Add missing io.Stream_Mode responses
2024-08-28 19:53:19 +02:00
Laytan
eb6e5ee3a1
Merge pull request #4162 from laytan/os2-disable-custom-heap-allocator
...
os2: disable custom heap allocator
2024-08-28 19:51:22 +02:00
Laytan
5e850e24d6
os2: disable custom heap allocator
...
See #4161
2024-08-28 19:45:34 +02:00
Jeroen van Rijn
17d10b72d5
Merge pull request #4158 from sqrt-negativeone/master
...
Win32 clipboard procedures
2024-08-28 19:02:18 +02:00
Fakhri Mouad
b08c14b710
fix style, ensure we compile with flags -vet -strict-style -disallow-do
2024-08-28 17:52:58 +01:00
Jeroen van Rijn
d3fca60e4d
Merge pull request #4160 from Kelimion/vsdd
...
-vet -strict-style -disallow-do
2024-08-28 18:49:44 +02:00
Jeroen van Rijn
d602e2cc74
Remove duplicate vet flag.
2024-08-28 18:43:54 +02:00
Jeroen van Rijn
831e26cb6f
Remove unused import.
2024-08-28 18:42:54 +02:00
Jeroen van Rijn
7b276cbc7e
-vet -strict-style -disallow-do
2024-08-28 18:36:49 +02:00
Fakhri Mouad
7e4750c303
fix indentation in test file
2024-08-28 17:30:30 +01:00
Fakhri Mouad
967b6d46b2
avoid using do statement in odin codebase
2024-08-28 17:27:27 +01:00
Jeroen van Rijn
fcafd83506
Merge pull request #4159 from Kelimion/disallow-do
...
More -disallow-do in CI.
2024-08-28 18:20:39 +02:00
Jeroen van Rijn
21dab9673d
More -disallow-do in CI.
2024-08-28 18:13:53 +02:00
Fakhri Mouad
16503c3b91
Add Win32 procs needed to handle clipboard
2024-08-28 16:36:06 +01:00
Laytan Laats
1e6419b5b7
fix zombie thread leak in thread self cleanup
2024-08-28 16:22:38 +02:00
Laytan Laats
ef66f96cf2
fix windows bindings where BOOL is not actually a boolean
...
Fixes #4157
2024-08-28 15:45:41 +02:00
Laytan Laats
9684ade23e
fix -vet-tabs
2024-08-27 19:13:46 +02:00
gingerBill
8694fa5f78
Minor cleanup of CFString.odin
2024-08-27 11:22:28 +01:00
gingerBill
fb248056c9
Merge pull request #4146 from Feoramund/fix-i128-transmute-align
...
Fix inline transmutation of `[16]i8` to `i128`
2024-08-26 22:38:24 +01:00
gingerBill
ade4e312fe
Merge pull request #4154 from avanspector/master
...
Delay lexical checking for foreign blocks that are in file scope
2024-08-26 22:38:13 +01:00
gingerBill
12bd07d2df
Merge pull request #4150 from laytan/update-wgpu-to-22-1-0
...
wgpu: update to v22.1.0.1
2024-08-26 22:37:31 +01:00
gingerBill
91f8c626bb
Merge pull request #4148 from Feoramund/tls-cleaner
...
Add API for freeing `thread_local` state
2024-08-26 22:37:08 +01:00
Laytan
c1684d6335
Merge pull request #4136 from flysand7/process-info-fix
...
[os2/process]: Don't free process info fields in partial success scenarios
2024-08-26 23:25:21 +02:00
flysand7
1a4faff9c9
[os2/process]: Fix typo on doc comments
2024-08-27 08:06:11 +11:00
Laytan
6c17642b91
Merge pull request #4155 from Feoramund/fix-test-vet-style
...
Fix `-vet` and `-strict-style` failures in tests
2024-08-26 23:01:21 +02:00
Laytan
ef254ec055
Merge pull request #4153 from Feoramund/fix-4151
...
Fix #4151
2024-08-26 22:59:48 +02:00
Feoramund
1f04f541cf
Fix -vet and -strict-style failures in tests
2024-08-26 16:20:08 -04:00
avanspector
dd86a8f013
Merge branch 'odin-lang:master' into master
2024-08-26 21:00:25 +02:00
avanspector
43ec2b9253
checker: delay foreign block checking
...
if file scope, otherwise as before
2024-08-26 20:59:16 +02:00
Laytan Laats
60cd0da2ed
wgpu: cont. fix sdl2glue on Linux
2024-08-26 20:24:26 +02:00
avanspector
c21bbae427
Merge branch 'master' of https://github.com/avanspector/Odin
2024-08-26 19:59:20 +02:00
avanspector
d7e977069a
Update checker.cpp
2024-08-26 19:59:15 +02:00
Jeroen van Rijn
ef98aa1fe1
Merge pull request #4152 from edyu/master
...
Fix error for uuid to require 36 bytes instead 32 (4 bytes for dashes)
2024-08-26 19:35:04 +02:00
Ed Yu
4e2bce0c83
Fix error for uuid to require 36 bytes instead 32 (4 bytes for dashes)
2024-08-26 10:25:10 -07:00
Feoramund
d43c6e39f6
Fix #4151
...
The `core:mem` procs were calling the wrong `runtime` procs for their
number of arguments.
2024-08-26 13:23:04 -04:00
Laytan
f56b895c05
wgpu: fix sdl2glue not using GetWindowWMInfo properly
...
Fixes #4127
2024-08-26 16:08:14 +02:00
Laytan Laats
54a420f3eb
wgpu: update to v22.1.0.1
2024-08-26 15:49:12 +02:00
Jeroen van Rijn
3e0f6bda91
Merge pull request #4149 from Feoramund/fix-thread-pool-use-after-free
...
Fix use-after-free in `thread.Pool`
2024-08-26 13:05:23 +02:00
Feoramund
9fac03b84c
Fix use-after-free in thread.Pool
2024-08-26 06:39:05 -04:00
Laytan
0a8f85e879
Merge pull request #4147 from Feoramund/cleanup-test-runtime-arenas
...
Free the arenas allocated in `test_core_runtime`
2024-08-26 12:09:34 +02:00
Feoramund
49606ec3ea
Use thread_local_cleaner API in os2
2024-08-26 06:01:59 -04:00
Feoramund
d338642dc4
Add API for freeing thread_local state
2024-08-26 06:01:59 -04:00
Feoramund
95d1c29c2a
Free the arenas allocated in test_core_runtime
...
Found by using `-sanitize:address`.
2024-08-26 05:45:24 -04:00
Feoramund
c424c94030
Fix inline transmutation of [16]i8 to i128
...
Forbids LLVM from generating SSE aligned loads on unaligned data.
2024-08-26 04:48:31 -04:00
gingerBill
8de1e88c4f
Merge pull request #4144 from laytan/riscv-error-on-atomics-without-extension
...
riscv: add an error when atomics are used without the atomics extension
2024-08-25 22:49:42 +01:00
flysand7
3119e0489f
[os2/process]: Fix vet errors
2024-08-26 07:23:59 +11:00
flysand7
db94e646e0
[os2/process]: Adjust documentation for process info
2024-08-26 07:21:54 +11:00
flysand7
4737485f09
[os2/process]: Force return on allocation errors and process not existing
2024-08-26 07:19:39 +11:00
Laytan
d299d4e1cd
riscv: add an error when atomics are used without the atomics extension
2024-08-25 21:17:00 +02:00
Laytan
9aeb0d0fb6
Merge pull request #4142 from laytan/os2-propogate-errors-from-execv
...
os2: propagate errors from execv
2024-08-25 21:09:54 +02:00
Laytan
0ea6809b49
os2: remove return on file_size error from read_entire_file
...
file_size can't return .No_Size because it uses io.size and only returns
an io.Error, removing this so it works when file_size fails (linux pipes
for instance)
2024-08-25 18:43:23 +02:00
Laytan Laats
a0fe6da10b
os2: propogate errors from execv functions to parent
2024-08-25 18:01:33 +02:00
gingerBill
8c952878fb
Allow empty strings in link_prefix and link_suffix
2024-08-25 14:03:14 +01:00
gingerBill
eda58357b6
Merge pull request #4141 from VladPavliuk/fix-dwmapi-enum
...
Fix win32 dwmapi DWMWINDOWATTRIBUTE enum.
2024-08-25 12:46:51 +01:00
gingerBill
7b14c267fb
Merge pull request #4138 from z64/z64/fix-cmark
...
Fix binding to cmark_node_get_fence_info
2024-08-25 12:43:07 +01:00
VladPavliuk
cc2ed2b302
Fix win32 dwmapi enum.
2024-08-25 14:34:24 +03:00
Zac Nowicki
17cc423a17
Fix binding to cmark_node_get_fence_info
...
https://github.com/commonmark/cmark/blob/master/src/cmark.h#L334
2024-08-25 01:42:12 -04:00
flysand7
fa84e86766
[os2/process]: Allow for partial success scenarios
2024-08-25 14:22:27 +11:00
flysand7
0d7e6430eb
[os2/process]: Don't free process info fields in partial success scenarios
2024-08-25 13:08:24 +11:00
Jeroen van Rijn
4cf1af3f7d
Merge pull request #4135 from gelatinstudios/master
...
fix core:reflect/iterator.odin
2024-08-24 23:23:33 +02:00
Laytan
eef4dffa12
Merge pull request #4134 from karl-zylinski/fix-raylib-LoadImageAnim-binding
...
Fix binding: Make rl.LoadImageAnim take a pointer instead of a multi-pointer.
2024-08-24 22:56:49 +02:00
Karl Zylinski
25e8a6353d
Fix comment indentation.
2024-08-24 22:02:17 +02:00
unknown
ae5ef0ce9c
fix core:reflect/iterator.odin
2024-08-24 16:01:49 -04:00
Karl Zylinski
574a5015d6
Make rl.LoadImageAnim take a pointer instead of a multipointer. The param frames is just for returning an int, it's not for passing a multipointer into the proc.
2024-08-24 22:00:29 +02:00
Jeroen van Rijn
0a825fc44d
Improve SRV handling in dns_windows.odin
2024-08-24 18:43:25 +02:00
gingerBill
aa659a637a
Fix #4132
2024-08-24 15:46:54 +01:00
gingerBill
0e71e93b22
Remove unused import
2024-08-24 14:51:28 +01:00
gingerBill
61b3af5b08
MemFree as a procedure group for both rawptr and cstring
2024-08-24 14:51:05 +01:00
gingerBill
19b95349a6
Use fmt.caprintf directly
2024-08-24 14:47:33 +01:00
gingerBill
d0eaf7642d
Add intrinsics.type_has_shared_fields
2024-08-24 14:36:18 +01:00
gingerBill
eb799393d5
Fix -vet-tabs issues
2024-08-24 13:56:41 +01:00
gingerBill
8ba87e01bd
Improve parse_enforce_tabs usage
2024-08-24 13:56:30 +01:00
gingerBill
daccd72162
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-08-24 13:36:51 +01:00
gingerBill
8b248673c1
Fix #4105
2024-08-24 13:36:43 +01:00
Jeroen van Rijn
faec52623d
Merge pull request #4128 from gordonshamway23/mini_fix_in_image
...
Added missing slice advancing.
2024-08-24 14:23:42 +02:00
gingerBill
b6d9a0c32e
Manually implement tail-recursion for parse_if_stmt
2024-08-24 13:16:55 +01:00
gingerBill
a4cc207022
Add a recursion depth limit for #3987 with a consideration to use a switch statement or refactor the code to not use a large if-else chain
2024-08-24 12:59:17 +01:00
gingerBill
683dde1fa0
Disallow labelled branches in defer - fix #3960
2024-08-24 12:47:29 +01:00
gingerBill
ca4d91a8a3
Fix #4079
2024-08-24 12:26:41 +01:00
gingerBill
65543b993f
Merge pull request #4130 from fusion32/fix-ambiguous-generic-type-names
...
fix ambiguous generic type names
2024-08-24 11:50:02 +01:00
gingerBill
00fb60d3d9
#4115 Add Suggestion: 'typeid_of(T)'
2024-08-24 11:48:32 +01:00
gingerBill
68a83abcd6
#4119 Add error when doing {.A | .B} instead of {.A, .B} with a suggestion to do surround it in parentheses to make it clear it is intended
2024-08-24 11:44:59 +01:00
gingerBill
4458ca4585
Fix #4126
2024-08-24 11:40:02 +01:00
fusion32
5ef8a092f6
fix wrong exact value kind comparison
2024-08-23 17:50:27 -03:00
fusion32
c969bee86d
fix ambiguous generic type names
2024-08-23 17:18:10 -03:00
gordonshamway23
426367c522
Added missing slice advancing.
2024-08-23 21:28:59 +02:00
Laytan Laats
d410281766
os2: do read_entire_file in parts if the file size is 0
2024-08-23 20:25:47 +02:00
Laytan Laats
ce53805d94
os2: fix read_entire_file wrong slice end variable
2024-08-23 20:25:19 +02:00
Laytan Laats
963e8544f4
os2: CLOEXEC the fds from pipe for posix implementation
2024-08-23 20:25:05 +02:00
Laytan Laats
c2a7c29ce8
os2: fix using uuid as process handle for darwin, once it goes zombie it changes
2024-08-23 20:24:06 +02:00
Laytan
b3f22133f3
Merge pull request #4123 from laytan/more-core-orca-support
...
orca: implement core:time and core:log
2024-08-23 18:47:00 +02:00
Laytan Laats
caef37bc18
orca: implement core:time and core:log
2024-08-23 18:25:10 +02:00
gingerBill
574dc5efe6
Merge pull request #4120 from laytan/posix-process
...
os2: process API for Darwin and most of it for BSDs
2024-08-22 22:51:48 +01:00
Laytan Laats
a66520ba57
os2: process API for Darwin and most of it for BSDs
2024-08-22 23:07:24 +02:00
Laytan Laats
b9043db434
os2: make platform error more ergonomic by making it an alias
2024-08-22 22:59:13 +02:00
Laytan Laats
58e5078b66
add riscv to simd.IS_EMULATED
2024-08-22 14:17:45 +02:00
gingerBill
70932dc478
Merge pull request #4089 from laytan/riscv64
...
add support for linux_riscv64 and freestanding_riscv64
2024-08-22 11:20:03 +01:00
Jeroen van Rijn
a8bc6f08a9
Merge pull request #4116 from Kelimion/article
...
Add table-driven (in)definite article to some errors.
2024-08-21 18:51:43 +02:00
Jeroen van Rijn
07aedb0b89
,
2024-08-21 18:42:11 +02:00
Laytan
63cd9a031a
fix variadic parameter with default value error check
2024-08-21 15:11:16 +02:00
gingerBill
c77e8ca401
Fix tests
2024-08-21 14:06:04 +01:00
gingerBill
58e811eea5
Merge pull request #3962 from Feoramund/regex
...
Add `core:text/regex`
2024-08-21 13:55:11 +01:00
Laytan
c0125f3192
correct the riscv64 stat structs
2024-08-21 14:41:23 +02:00
Jeroen van Rijn
1bcc074223
dash
2024-08-21 14:18:12 +02:00
gingerBill
e7b8e61c68
Merge pull request #4106 from yeongjukang/master
...
core:sys/linux - implement clock_settime, clock_getres and clock_nanosleep
2024-08-21 09:41:14 +01:00
Yeongju Kang
bbe4c32e32
changed signature of clock_getres
2024-08-21 08:25:14 +09:00
Laytan
0d39f52b4d
Merge pull request #4117 from yay/vet-tabs
...
A couple of foundation binding. Vet tabs.
2024-08-21 01:16:30 +02:00
Vitalii Kravchenko
14169ae5b4
A couple of foundation binding. Vet tabs.
2024-08-21 00:09:09 +01:00
Jeroen van Rijn
6b4b0cea5d
Add table-driven (in)definite article to some errors.
2024-08-20 22:13:31 +02:00
Laytan
85a33a1c9b
add constant_log2 to intrinsics file
2024-08-20 19:14:50 +02:00
Laytan
8f2d3dc955
fix i128 division?
2024-08-20 19:01:09 +02:00
Jeroen van Rijn
daa0779c01
Rewrite compound_to_time without using i128.
2024-08-20 18:50:05 +02:00
Laytan
d7e81e86f5
Merge pull request #4110 from andradei/termios-linux
...
Add support for Linux on os/sys/posix termios.
2024-08-20 17:23:53 +02:00
Laytan
06fb500dfe
make sure net.Network_Error is of size 8
2024-08-20 15:52:07 +02:00
Jeroen van Rijn
5ef58049dc
Merge pull request #4114 from it-a-me/master
...
fix wiki link in the README.md
2024-08-20 14:27:47 +02:00
Laytan Laats
5b22bfa2b7
unify LB_ABI_INFO and LB_ABI_INFO_CTX
2024-08-20 14:07:47 +02:00
Laytan
ca6ef95b03
add support for linux_riscv64 and freestanding_riscv64
2024-08-20 14:06:40 +02:00
it-a-me
53500699a9
README.md: Fix wiki link
2024-08-19 23:00:26 -07:00
Jeroen van Rijn
29838da782
Merge pull request #4111 from RoryO/simd-typo
...
fix simd var typo
2024-08-20 00:52:37 +02:00
Rory OConnell
97795ff3a2
fix simd var typo
2024-08-19 15:50:42 -07:00
Isaac Andrade
6df51b42a8
Fix termios NCCS size on linux.
2024-08-19 15:32:55 -06:00
Isaac Andrade
3228178d87
Add support for Linux on os/sys/posix termios.
2024-08-19 14:56:37 -06:00
Jeroen van Rijn
3fc1f6f1cd
Merge pull request #4101 from Yawning/feature/index-byte-tweaks
...
core/bytes: Tweak `index_byte`/`last_index_byte`
2024-08-19 20:43:37 +02:00
gingerBill
2999c02f65
Fix random typo
2024-08-19 16:33:17 +01:00
gingerBill
9d7ab8d5ca
Add strings.contains_space
2024-08-19 16:31:03 +01:00
gingerBill
2a0785037b
Fix switch val in ptr
2024-08-19 12:19:45 +01:00
Yawning Angel
9e65e229d0
core/bytes: Tweak index_byte and last_index_byte
...
- Assume unaligned loads are cheap
- Explicilty use 256-bit or 128-bit SIMD to avoid AVX512
- Limit "vectorized" scanning to 128-bits if SIMD is emulated via SWAR
- Add a few more benchmark cases
2024-08-19 11:40:36 +09:00
Jeroen van Rijn
34a9e20531
Merge pull request #4108 from Feoramund/remove-deprecated-testing-log
...
Remove deprecated `log` procs from `core:testing`
2024-08-19 04:19:22 +02:00
Feoramund
0fa24ac3c4
Remove deprecated log procs from core:testing
2024-08-18 21:30:32 -04:00
Jeroen van Rijn
17eb0b5ee0
Merge pull request #4107 from Feoramund/add-digit-count
...
Add `core:math.count_digits_of_base`
2024-08-19 02:36:05 +02:00
Feoramund
b49b80bdf9
Add test for count_digits_of_base
2024-08-18 20:14:14 -04:00
Feoramund
2906f2aa7e
Add core:math.count_digits_of_base
2024-08-18 20:14:14 -04:00
Yeongju Kang
f96991364a
implement clock_settime, clock_getres and clock_nanosleep
2024-08-19 08:53:07 +09:00
Laytan
359a212a78
Merge pull request #4104 from laytan/find-llvm-config-through-brew
...
query brew for llvm-config location if possible
2024-08-19 00:41:06 +02:00
Laytan Laats
ea7e8f075d
query brew for llvm-config location if possible
2024-08-19 00:02:14 +02:00
gingerBill
d99a6ad003
Add suggestion for ~uint(0) if cast(uint)-1 is done
2024-08-18 22:52:57 +01:00
gingerBill
95c3b8a8de
Move assert to else branch
2024-08-18 22:45:26 +01:00
Laytan Laats
ae41779366
remove redundant &
2024-08-18 21:10:21 +02:00
Laytan
bb3f848b4a
Merge pull request #4103 from laytan/wait-shared-on-macos-10-15
...
UL_COMPARE_AND_WAIT_SHARED is macOS 10.15+
2024-08-18 19:38:52 +02:00
gingerBill
a51b9c6fb0
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-08-18 18:37:45 +01:00
gingerBill
8e52a52580
Cache the paddding filler type
2024-08-18 18:37:40 +01:00
Laytan Laats
b7b3ada3b1
UL_COMPARE_AND_WAIT_SHARED is macOS 10.15+
2024-08-18 19:31:52 +02:00
Laytan
9a895a318c
Merge pull request #4102 from laytan/wasm-lshrti3
...
Implement lshrti3 on wasm
2024-08-18 17:18:05 +02:00
Laytan Laats
b2e64b7ce0
implement lshrti3 on wasm
2024-08-18 17:09:57 +02:00
Yawning Angel
7020e9b66a
core/simd: Add IS_EMULTATED so there is one place to look for potatos
2024-08-18 22:52:39 +09:00
gingerBill
f49ebae956
Correct lbAddr_SoaVariable logic
2024-08-18 12:37:15 +01:00
gingerBill
0e82a46047
Fix #3999
2024-08-18 12:35:25 +01:00
gingerBill
c4e0cbcd87
Fix #4005
2024-08-18 12:21:35 +01:00
gingerBill
f82bf6cd42
Fix #4022
2024-08-18 12:13:52 +01:00
gingerBill
60b2979cfd
Fix #4024
2024-08-18 12:10:46 +01:00
gingerBill
17740966e5
Fix #4040
2024-08-18 12:06:58 +01:00
gingerBill
5c06fcd346
Fix #4064
2024-08-18 12:00:27 +01:00
gingerBill
22a82e73d6
Fix #3976
2024-08-18 11:45:27 +01:00
Jeroen van Rijn
bbb5593f87
Merge pull request #4098 from jolson88/raygui/vertical-text-alignment
...
(raygui) Restores vertical text alignment broken after 4.0 migration
2024-08-17 22:29:38 +02:00
Jason Olson
d00057c803
Add missing trailing comma
2024-08-17 13:23:42 -07:00
Jason Olson
acfd9dcd1b
Restores vertical text alignment broken after 4.0 migration
...
A series of changes between raygui 3.6 and 4.0 were that various text box
properties were moved from the text box specific properties up into the
extended default control properties. This change corrects the various
property enums to match the raygui 4.0 API.
One additional aspect of this change was rolling back a previous commit
made to this vendor file that changed the signature of GuiSetStyle and
GuiGetStyle from using a c.int as property value to a more strongly-defined
GuiControlProperty enum. Unfortunately, this breaks the raygui API by
disallowing the use of various control-specific extended properties due to
how the enums are built.
2024-08-17 12:35:50 -07:00
Jeroen van Rijn
9553bc3689
If missing type is newline, print "newline", not \n
...
Turns:
W:/Odin/bug/bug.odin(3:27) Syntax Error: Expected a type, got '
'
Storage :: distinct map[]
Into:
W:/Odin/bug/bug.odin(3:27) Syntax Error: Expected a type, got newline
Storage :: distinct map[]
2024-08-17 17:25:52 +02:00
Jeroen van Rijn
ebbb70f11d
Error if missing map key type
...
Fixes #4096
2024-08-17 17:12:27 +02:00
Laytan Laats
142bda2804
posix: start on process API
2024-08-17 15:48:01 +02:00
Jeroen van Rijn
478f529744
Merge pull request #4094 from amad00r/fix-nil-logger
...
Fix log unnecessary allocations
2024-08-17 01:50:13 +02:00
gingerBill
536a342873
Merge pull request #4092 from laytan/fix-open-bindings
...
fix `open` bindings
2024-08-17 00:22:46 +01:00
Amadeu Moya
43dc7704a5
Fix log unnecessary allocations
2024-08-17 00:37:01 +02:00
Laytan Laats
e8933e43ec
add haiku to unsupported time file
2024-08-16 23:18:59 +02:00
Laytan Laats
f7d7d65bc0
fix open bindings
...
`open` specifies the `mode` argument as vararg (presumably to make it
optional). varargs actually have rules about casting, in this case the
rule that any integer arg of size <= 4 has to be casted to `i32` before
passing it.
Not doing that implicit cast makes the permissions wrong or not apply at
all.
2024-08-16 22:54:53 +02:00
Jeroen van Rijn
970dc7a1f2
Merge pull request #4091 from Feoramund/fix-darwin-os-open
...
Check if file open-mode is `O_CREATE` on Darwin before forcing chmod
2024-08-16 20:31:22 +02:00
Feoramund
a07878be71
Check if file open-mode is O_CREATE on Darwin before forcing chmod
...
Fixes #4087
2024-08-16 14:08:55 -04:00
Jeroen van Rijn
14e207088a
Merge pull request #4088 from Kelimion/benchmark
...
Improve benchmarks.
2024-08-16 17:16:59 +02:00
Jeroen van Rijn
6c46c9e04b
Improve benchmarks.
2024-08-16 17:00:16 +02:00
gingerBill
40b8150a23
Minor clean ups
2024-08-16 12:47:23 +01:00
gingerBill
31bb3dc4f0
Merge pull request #3971 from jasonKercher/os2-process-linux
...
os2 process linux implementation
2024-08-16 12:38:27 +01:00
gingerBill
65ce7687d7
Merge pull request #4004 from Skytrias/orca-odin-bindings
...
Add autogenerated orca bindings and macros from laytan
2024-08-16 12:37:36 +01:00
Laytan
6fc39c1b5d
Merge pull request #4075 from yay/more-foundation-bindings
...
More Foundation bindings.
2024-08-16 13:08:15 +02:00
jason
07a9c69714
update core:filepath's clean, join and split_list to return optional Allocator_Errors
2024-08-16 01:48:27 -04:00
Vitalii Kravchenko
004036dc59
More Foundation bindings.
2024-08-16 00:00:29 +01:00
Laytan
d91fa162d8
Merge pull request #3280 from beaumccartney/shm_syscalls
...
add shm_open and shm_unlink syscalls for darwin
2024-08-15 17:08:41 +02:00
gingerBill
6e91f6ab31
Merge pull request #4081 from DerTee/master
...
fix error handling in os2.read_entire_file_from_file()
2024-08-14 22:12:06 +01:00
gingerBill
b16d5198a3
Merge pull request #4082 from FourteenBrush/master
...
Fix 'odin [run|test] --' giving a compiler out of bounds
2024-08-14 22:11:55 +01:00
FourteenBrush
12813e5d48
Fix 'odin [run|test] --' giving a compiler out of bounds
2024-08-14 21:37:40 +02:00
DerTee
6422e49255
fix error handling in os2.read_entire_file_from_file()
...
even when an error in file_size() happened, os2.ERROR_NONE was returned
2024-08-14 17:30:02 +02:00
Jeroen van Rijn
f7234e2ed3
Allow ODIN_TEST_LOG_LEVEL override when -debug.
2024-08-14 16:29:51 +02:00
gingerBill
e810c3eace
Merge pull request #4012 from laytan/posix
...
core:sys/posix and core:os/os2 based on it (for darwin, netbsd, freebsd and openbsd)
2024-08-14 15:10:31 +01:00
gingerBill
18b6af1858
Minor clean up of comments
2024-08-14 14:15:20 +01:00
gingerBill
03dd38f203
Minor changes to vendor:ENet
2024-08-14 14:09:36 +01:00
gingerBill
eb6f2078cf
Add fmt:"v,extensions_count" tags to many struct fields
2024-08-14 14:03:41 +01:00
gingerBill
df61096317
Improve doc comments for vendor:ggpo
2024-08-14 13:55:25 +01:00
gingerBill
8abe054665
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-08-14 13:02:28 +01:00
gingerBill
324d9c2284
Fix doc writer bug caused by using an iterator rather than a for loop
2024-08-14 13:02:23 +01:00
Laytan Laats
f657b4cc0c
time: use assert_contextless in wasi implementation
2024-08-14 13:27:58 +02:00
gingerBill
c98c95fcf0
Add require_results and change some of the wrapper to return a slice
2024-08-14 11:29:23 +01:00
gingerBill
fd5376ba88
Allow @(require_results) on foreign blocks
2024-08-14 11:28:49 +01:00
gingerBill
78fa675c1a
Add assert_contextless, panic_contextless, unimplemented_contextless
2024-08-14 11:18:24 +01:00
gingerBill
4c19f507ff
Merge pull request #4074 from odin-lang/vendor/box2d
...
`vendor:box2d`
2024-08-14 11:15:34 +01:00
gingerBill
651122e9db
Fix foreign import paths
2024-08-14 11:01:54 +01:00
gingerBill
d1e114742e
Add deprecated and require_results attributes to math_functions.odin
2024-08-14 10:55:40 +01:00
Laytan
29a6959a56
Merge pull request #2977 from jakubtomsu/disallow-variadic-param-default
...
Report error when a variadic procedure parameter has a default value
2024-08-14 11:55:09 +02:00
gingerBill
491def9d5b
Fix paths for amd64 targets
2024-08-14 10:50:53 +01:00
gingerBill
427c48221d
Clean up foreign import code for library path determination
2024-08-14 10:28:07 +01:00
gingerBill
1c97739ca3
Merge branch 'vendor/box2d' of https://github.com/odin-lang/Odin into vendor/box2d
2024-08-14 10:18:41 +01:00
gingerBill
0b26115805
Improve presentation
2024-08-14 10:18:36 +01:00
gingerBill
1c8672ac6c
Merge pull request #4078 from funkkiy/fix-rodata-index
...
Error if assigning to `rodata` variable with index
2024-08-14 09:41:35 +01:00
jason
0f052dbde7
os2/process_linux: improve error handling, use pidfd where possible, remove usage of fmt
2024-08-14 00:45:25 -04:00
Davi
4bb51249d1
Error if assigning to rodata variable with index
2024-08-13 23:28:34 -03:00
Laytan Laats
e29f0a0f40
os2: dup the file descriptor before fdopendir
2024-08-14 01:45:24 +02:00
Laytan Laats
f837e35f4b
os2: fix bad free for posix file closure
2024-08-14 01:45:24 +02:00
Laytan Laats
61ee2efa35
os2: just use runtime._heap_allocator_proc instead of a copy for posix
2024-08-14 01:45:24 +02:00
Laytan Laats
e94c4e1e18
posix: remove the is_temp things that prevented use-after-frees
...
https://github.com/odin-lang/Odin/commit/d0709a7de21efded4625167dbff4a7dd13d561b4
fixes those another way.
2024-08-14 01:45:24 +02:00
Laytan Laats
b07d0b38b1
os2: improve absolute/full path handling for posix
2024-08-14 01:45:23 +02:00
Laytan Laats
a73677d21a
os2: nice != priority
2024-08-14 01:44:37 +02:00
Laytan Laats
67ea7bb65a
posix: address some freebsd feedback
2024-08-14 01:44:37 +02:00
Laytan Laats
175f5b0bb1
os2: don't rely on PATH_MAX in posix read_directory implementation
2024-08-14 01:44:37 +02:00
Laytan Laats
939ba4cf08
os2: fix leak and always close directory
2024-08-14 01:44:37 +02:00
Laytan Laats
f00f68ef6f
posix/os2: fix test and add back in removed temp guard
2024-08-14 01:44:37 +02:00
Laytan Laats
de9abe1f7b
os2: skip . and .. in read dir
2024-08-14 01:44:37 +02:00
Laytan Laats
bd808f9ec6
os2: fix wiping results with temp allocator guard
2024-08-14 01:44:37 +02:00
Laytan Laats
7474db6a34
os2: fix lstat logic
2024-08-14 01:44:37 +02:00
Laytan Laats
00eb702c4a
os2: implement the iterator based read directory
2024-08-14 01:44:37 +02:00
Laytan Laats
ea5783c2ac
os2: fixes after rebasing
2024-08-14 01:44:37 +02:00
Laytan Laats
e05fddc001
posix: fix file type checks in stat
2024-08-14 01:44:37 +02:00
Laytan Laats
406e60f5dd
posix: revert change to os that was done for testing
2024-08-14 01:44:37 +02:00
Laytan Laats
5115aee23f
posix: actually fix netbsd test
2024-08-14 01:44:37 +02:00
Laytan Laats
72220a855f
posix: fix write error check
2024-08-14 01:44:37 +02:00
Laytan Laats
4a61bac100
posix: fix test on netbsd
2024-08-14 01:44:37 +02:00
Laytan Laats
726891588f
posix: more tests
2024-08-14 01:44:37 +02:00
Laytan Laats
2a5ceff667
posix: move doc
2024-08-14 01:44:37 +02:00
Laytan Laats
9e2c5acb9d
os2: fix bit checks
2024-08-14 01:44:37 +02:00
Laytan Laats
7c9ca60ff0
mem/virtual: support the BSDs
2024-08-14 01:44:37 +02:00
Laytan Laats
379cd6fe66
os2: cleanup
2024-08-14 01:44:37 +02:00
Laytan Laats
ffff3c3c88
posix: fix foreign import of dl for free/netbsd
2024-08-14 01:44:37 +02:00
Laytan Laats
a4d459f651
os2: initial implementation for Darwin&BSDs, process API is only thing incomplete
2024-08-14 01:44:37 +02:00
Laytan Laats
ff0ca0bd53
os2: make config directory on darwin also ~/.config, it is the proper place
2024-08-14 01:44:37 +02:00
Laytan Laats
07b9f7d280
os2: fix read_entire_file bad logic
2024-08-14 01:44:37 +02:00
Laytan Laats
9f80191f60
os2: add default make_directory permissions
2024-08-14 01:44:37 +02:00
Laytan Laats
efe68c2e24
posix: add package
2024-08-14 01:44:35 +02:00
Laytan
3847d03248
Merge pull request #3281 from erjohnson/patch-1
...
Update mem doc example formatting
2024-08-14 00:10:03 +02:00
Laytan Laats
bb54a0a972
fix whitespace
2024-08-14 00:08:46 +02:00
Laytan Laats
ac68a9d52c
update MacOS releases
2024-08-14 00:00:50 +02:00
Laytan Laats
d4d46df2fc
box2d: add build script and MacOS libraries
2024-08-13 22:15:31 +02:00
gingerBill
660b6ff0f1
Add vendor:box2d to examples/all
2024-08-13 17:08:31 +01:00
gingerBill
9ccaca7f1a
Minor style change
2024-08-13 17:01:55 +01:00
gingerBill
926c419ef8
Change .lib to be /MT compatible; Fix comments
2024-08-13 16:58:35 +01:00
gingerBill
22b32ab0fa
Use intrinsics.has_target_feature
2024-08-13 16:35:28 +01:00
gingerBill
40361f877e
Add libraries for windows
2024-08-13 16:34:31 +01:00
gingerBill
f2ba3da895
Create bindings for box2d
...
Currently missing lib binaries
2024-08-13 16:18:24 +01:00
Laytan
55be3e60a0
Merge pull request #3125 from marcs-feh/master
...
sys/linux: Add binding to ioctl syscall + standard fd constants.
2024-08-13 15:30:50 +02:00
gingerBill
62911539cd
Minor style change
2024-08-13 14:27:25 +01:00
Laytan
c7af8af76a
Update core/sys/linux/sys.odin
2024-08-13 15:22:35 +02:00
gingerBill
e3d5bbe62c
Merge pull request #4065 from laytan/fix-max-alignments
...
fix max alignments
2024-08-13 14:09:45 +01:00
gingerBill
2584c6bcd7
Merge pull request #4069 from zen3ger/1738-aliased-procedure-resolution
...
Fix alias handling of procedures
2024-08-13 14:07:51 +01:00
gingerBill
66d3082a9a
Merge pull request #4056 from laytan/re-enable-runtime-wasm-stuff
...
re-enable some wasm things in runtime
2024-08-13 14:04:19 +01:00
gingerBill
09a07bd7e0
Merge pull request #4055 from laytan/time-wasi
...
time: wasi implementation
2024-08-13 14:03:02 +01:00
gingerBill
848f7e117f
Merge pull request #4050 from IllusionMan1212/egl-procs
...
vendor/egl: added a few more egl procedures and constants
2024-08-13 14:01:20 +01:00
gingerBill
d93364ce52
Merge pull request #4049 from IllusionMan1212/xrandr-xinput-xfixes
...
vendor/x11: added a few procedures for xrandr, xinput, and xfixes
2024-08-13 14:00:08 +01:00
gingerBill
4c4f24b5f4
Merge pull request #4041 from zen3ger/1079-parametric-struct-from-other-package
...
Check if procedure parameter type declares polymorphic args
2024-08-13 13:59:06 +01:00
Jeroen van Rijn
069ad446cd
Merge pull request #4070 from Feoramund/test-runner-mem-fail-as-error
...
Let memory failures be errors in the test runner
2024-08-13 13:50:46 +02:00
Jeroen van Rijn
02b4bb8491
Merge pull request #4072 from laytan/fix-32-bit-math-round
...
fix type hint propagation for shift
2024-08-13 00:34:19 +02:00
Laytan Laats
2808ecc5b6
remove panic workaround
2024-08-12 23:48:36 +02:00
Laytan Laats
a1d518442a
fix type hint propogation for shift
...
Fixes #3856
2024-08-12 23:39:07 +02:00
Jeroen van Rijn
0d916a659e
Merge pull request #4053 from Feoramund/fix-gitignore
...
Fix `.gitignore`
2024-08-12 21:34:26 +02:00
Feoramund
3a32250b80
Add .gitignore for tests directory
2024-08-12 15:16:52 -04:00
Jeroen van Rijn
053e65a1c8
Merge pull request #4071 from andreas-jonsson/andreas-jonsson-patch-2
...
Use another URL for pkgsrc on CI
2024-08-12 20:58:41 +02:00
Andreas T Jonsson
7af0291c7d
Try use another arch URL for pkgsrc
2024-08-12 20:27:20 +02:00
Feoramund
0af025d056
Add explicit copyright info to core:testing
2024-08-12 14:16:22 -04:00
Roland Kovacs
9eb7186cda
Fix alias handling of procedures
...
An incorrect memmove when overriding entities caused multiple ones to point to
the same procedure with incomplete variant data, resulting in later hiting a
compiler assertion.
Introduced delayed type checking for procedure aliases, as it was masked by
the previous error in the override logic.
2024-08-12 19:52:42 +02:00
Laytan
d68cc41782
Merge pull request #4068 from laytan/fix-read-dir-closing-given-fd
...
fix `os.read_dir` closing the given file descriptor
2024-08-12 19:23:48 +02:00
Laytan
fb09ec06d3
Merge pull request #4066 from Tetralux/fmt-bitfields-pointers
...
[fmt] Add bit fields to the pointer printing logic
2024-08-12 19:14:15 +02:00
Laytan Laats
a4ac3cc6e8
fix os.read_dir closing the given file descriptor
2024-08-12 18:51:27 +02:00
Tetralux
4f56822204
[fmt] Add bit fields to the pointer printing logic
...
core:fmt prints pointers to structs as `&StructName{ ... }` but `bit_field`s are currently printed
the same as rawptrs (`0xAABBCCDDEEFF` only).
This commit changes that so they behave the same as structs and unions.
2024-08-12 16:25:22 +00:00
Laytan Laats
f22ff21039
fix max alignments
2024-08-12 17:05:51 +02:00
Laytan
b71e0c2e36
Merge pull request #4059 from laytan/loop-write-entire-file
...
loop write_entire_file to write more than MAX_RW
2024-08-12 13:54:46 +02:00
Laytan
fd9a008e1e
Merge pull request #4058 from laytan/fix-cvararg-bitset
...
fix c_vararg bit_set
2024-08-12 13:54:28 +02:00
Laytan
450fc3ec77
Merge pull request #4060 from laytan/support-field-tag-bitsets-in-core-odin
...
core/odin: support field tags on bit_field fields
2024-08-12 13:53:33 +02:00
Laytan
0a118a14ab
Merge pull request #4061 from laytan/fix-fmt-maybe-pointer-detection
...
fix `type_info_union_is_pure_maybe` only working with regular pointers
2024-08-12 13:53:17 +02:00
Feoramund
f42a22369e
Fix wrong define name in test runner log messages
2024-08-11 23:01:28 -04:00
Feoramund
675add4d90
Optionally treat memory failures as errors in the test runner
...
Enable with `-define:ODIN_TEST_FAIL_ON_BAD_MEMORY=true`.
2024-08-11 22:59:20 -04:00
Jeroen van Rijn
1761802330
Merge pull request #4062 from laytan/fix-switch-over-internal-pointer-union
...
fix type switching over internal pointer union
2024-08-12 00:25:47 +02:00
Laytan Laats
99aa0d3a35
fix type switching over internal pointer union
...
Fixes #3947
2024-08-12 00:02:05 +02:00
Laytan Laats
dec97cbddb
fix type_info_union_is_pure_maybe only working with regular pointers
...
Fixes #3996
2024-08-11 21:07:21 +02:00
Laytan Laats
f0840ed24e
core/odin: support field tags on bit_field fields
...
Fixes #4044
2024-08-11 20:59:54 +02:00
Laytan
b9e68ee3c1
Merge pull request #4054 from Feoramund/zlib-reverse-bits
...
Use `intrinsics.reverse_bits` in `core:compress/zlib`
2024-08-11 17:42:28 +02:00
Laytan Laats
d6336e7252
add orca to examples/all for docs
2024-08-11 17:35:19 +02:00
Laytan Laats
c6a0d302b3
loop write_entire_file to write more than MAX_RW
...
Fixes #4042
2024-08-11 17:27:54 +02:00
Laytan Laats
26fa3aca44
fix copy-paste error in make docs
2024-08-11 17:09:26 +02:00
Laytan Laats
e3f375afd8
fix c_vararg bit_set
...
Fixes #4051
2024-08-11 17:00:49 +02:00
Jeroen van Rijn
8a67221bd4
Merge pull request #4057 from asibahi/patch-1
...
typo fix
2024-08-11 13:35:10 +02:00
Abdul Rahman Sibahi
67251ad5b8
typo fix
2024-08-11 14:30:48 +03:00
Laytan
938e81e341
sys/orca: add missing using
2024-08-10 23:59:51 +02:00
Laytan Laats
f5fe0de0fd
add clarity for diverging mismatch error
2024-08-10 23:34:35 +02:00
Laytan Laats
7fd8b9c55b
re-enable some wasm things in runtime
...
No idea why the floattidf procs are bodged to return 0, does somebody
know? I have just enabled the original codepath, if nobody knows I
suggest just enabling it and see if we get complaints, it works on all
wasm stuff I tried.
The linkage being set to "internal" instead of "strong" is actually
causing problems in my projects which is what prompted looking at this
in the first place, some of these functions were actually needed but not
added/used because they had internal linkage. This only happens on
bigger projects (or just when using f16?).
Unfortunately `git blame` gave me this generic commit: https://github.com/odin-lang/Odin/commit/94bad4d7861c78b9e7191ec0c3114861a1536d5c#diff-fb9f42022cb95efa59d16813546b8cb310234428c85edfabf09b1425c9dc46af
2024-08-10 23:10:30 +02:00
Laytan Laats
a2cd763dbb
time: wasi implementation
2024-08-10 23:01:31 +02:00
Feoramund
cf8f6afeff
Use intrinsics.reverse_bits in core:compress/zlib
2024-08-10 15:29:44 -04:00
Feoramund
afbdc78f85
Fix .gitignore
...
- Remove all-encompassing `benchmark`
- Add exception for `core:simd/x86`
2024-08-10 15:16:12 -04:00
Laytan Laats
6918d8aaa6
possibly fix init_core_type_info race condition
2024-08-10 21:03:40 +02:00
Jeroen van Rijn
e226d37803
Merge pull request #4023 from Feoramund/simd-index
...
Vectorize `index_byte`
2024-08-10 21:01:41 +02:00
Feoramund
4f816aabb3
Use SIMD_SCAN_WIDTH constant in core:bytes test
2024-08-10 13:54:12 -04:00
Laytan Laats
d98f848247
fix debug compiler build message not ending output with a newline
2024-08-10 19:07:30 +02:00
Jeroen van Rijn
1242b6e82f
Improve slice.binary_search_by
2024-08-10 18:26:59 +02:00
Jeroen van Rijn
9759d56c81
Merge pull request #4003 from Yawning/feature/crypto-improvements
...
core:crypto: Various improvements
2024-08-10 17:17:00 +02:00
Laytan
d73ad8eb1e
Merge pull request #4046 from laytan/cbor-fixes
...
encoding/cbor: various fixes
2024-08-10 17:02:41 +02:00
jason
a52f7c129f
stop trying to handle child pipe read errors in process_start
2024-08-10 09:13:07 -04:00
jason
e54d6e5a11
Ignore process_open errors in process_start. This enforces a contract
...
with the user that any process returned without error must eventually be
waited on.
2024-08-10 09:03:34 -04:00
jason
f7a73b9555
fix error handling; close read end of the child pipe instead of the write end twice
2024-08-10 08:55:40 -04:00
Feoramund
9d2b4b2f03
Simplify core:bytes test
2024-08-10 08:13:22 -04:00
Feoramund
5d5addd48f
Set SIMD_SCAN_WIDTH based on size_of(uintptr)
2024-08-10 07:43:14 -04:00
Feoramund
c69fa87d53
Merge core:simd/util into core:bytes
2024-08-10 07:17:03 -04:00
Jeroen van Rijn
bf53d2f6db
Fix time.precise_clock on 32-bit platforms.
2024-08-10 12:44:40 +02:00
Jeroen van Rijn
d267735d99
Fixed time.precise_clock
2024-08-10 12:35:58 +02:00
IllusionMan1212
554b0e5bf7
vendor/x11: added a few procedures for xrandr, xinput, and xfixes
2024-08-10 12:06:52 +02:00
Yawning Angel
ba1ad82c2b
core/crypto/aead: Initial import
2024-08-10 18:32:37 +09:00
Yawning Angel
38aea1f907
core/crypto/aes,chacha20poly1305: Add require_results to open
2024-08-10 18:32:37 +09:00
Yawning Angel
b381791f42
core/crypto/chacha20: Change API terminology to be consistent with AES
2024-08-10 18:32:37 +09:00
Yawning Angel
14ceb0b19d
core/crypto/chacha20poly1305: Support AEAD_XChaCha20_Poly1305
...
IETF-draft flavor (32-bit counter) though this makes no practical
difference.
2024-08-10 18:32:37 +09:00
Yawning Angel
8efc98ce90
core/crypto/chacha20poly1305: Change the interface to match GCM
2024-08-10 18:32:37 +09:00
Yawning Angel
1f3107e693
core/crypto/chacha20: Use 128-bit/256-bit SIMD
2024-08-10 18:32:37 +09:00
Yawning Angel
708f053fe6
core/crypto/aes: Use NIST terminology for the IV
2024-08-10 18:32:37 +09:00
Yawning Angel
ac7f44b1b8
core/crypto/aes: Slightly tweak GHASH to look less spooky
2024-08-10 18:32:37 +09:00
Yawning Angel
b1d6e4139e
core/crypto/aes: Disable bounds checking for the CTR loops
2024-08-10 18:32:37 +09:00
Yawning Angel
dfc4df9807
core/crypto/_aes/hw_intel: Use a constant for the PSHUFB indicies
2024-08-10 18:32:37 +09:00
Yawning Angel
b9293334ca
core/crypto/ed25519: Rename a member for clarity
...
This better matches the spec.
2024-08-10 18:32:37 +09:00
Yawning Angel
b68311d777
core/crypto/hash: Make the _to_buffer routines return the hash slice
...
Quality of life improvement.
2024-08-10 18:32:37 +09:00
Yawning Angel
c0f9655ec4
test/core/crypto: Minor changes to AES related tests
...
- Test against the non-standard GCM nonce length vectors
- Fix the CTR mode test to match the comment
Correctness was fine without this change.
2024-08-10 18:32:37 +09:00
IllusionMan1212
7875e4a1ab
vendor/egl: added a few more egl procedures and constants
2024-08-10 10:21:03 +02:00
Jeroen van Rijn
be7a1f671c
Revert "Add time.precise_clock_from_time + time.precise_clock_from_duration"
...
This reverts commit c9ca192f33 .
2024-08-10 03:26:09 +02:00
Jeroen van Rijn
c9ca192f33
Add time.precise_clock_from_time + time.precise_clock_from_duration
2024-08-10 03:23:08 +02:00
Feoramund
e7e7fe766a
Add test for misaligned data to core:simd/util suite
2024-08-09 18:54:04 -04:00
Feoramund
0d29cc3375
Use for x in y construct for bytes iteration
...
This cannot be applied to the `strings` version, as that would cause a
rune-by-rune iteration, not a byte-by-byte one.
2024-08-09 18:54:04 -04:00
Feoramund
c8a62ee4ec
Make simd_util index procs contextless where applicable
2024-08-09 18:54:04 -04:00
Feoramund
12dd0cb72a
Simplify and make simd_util cross-platform
...
This new algorithm uses a Scalar->Vector->Scalar iteration loop which
requires no masking off of any incomplete data chunks.
Also, the width was reduced to 32 bytes instead of 64, as I found this
to be about as fast as the previous 64-byte x86 version.
2024-08-09 18:54:04 -04:00
Laytan Laats
912f99abc8
encoding/cbor: various fixes
...
- "null" is the proper way to represent the nil value in the diagnostic
format
- hex encoding in diagnostic format was wrong
- struct keys weren't sorted the right deterministic way
2024-08-09 21:56:54 +02:00
jason
baacc512e3
fix child pipe in process_start
2024-08-09 15:21:11 -04:00
Jeroen van Rijn
c5ed7083d2
Disable NetBSD CI
2024-08-09 19:44:51 +02:00
Jeroen van Rijn
d69e0bfa00
NetBSD vm fix.
2024-08-09 19:37:26 +02:00
Jeroen van Rijn
fa6f343261
Remove unused import.
2024-08-09 19:06:50 +02:00
jason
c4d43bbab0
os2 linux process_wait rework; add Sig_Child_Code to sys/linux bits
2024-08-09 09:16:44 -04:00
Jeroen van Rijn
cc24d2de3e
Merge pull request #3810 from Feoramund/freebsd-core-net
...
Port `core:net` to FreeBSD
2024-08-09 09:50:05 +02:00
Jeroen van Rijn
bc6deab175
echo -> printf for build_odin.sh message
2024-08-09 09:46:45 +02:00
Laytan
b5a612202f
Merge pull request #4036 from laytan/master
...
add debug build message and align more with build.bat
2024-08-08 22:21:17 +02:00
Jeroen van Rijn
1e09ff3b2e
Merge pull request #4043 from Kelimion/expect_leak_or_bad_free
...
Allow testing for intentional leaks in test runner
2024-08-08 21:40:17 +02:00
Jeroen van Rijn
933f9f9bd1
Enable test leak = fatal on CI.
2024-08-08 21:31:30 +02:00
Jeroen van Rijn
b82cfc5f15
Fix shoco heisenleak
2024-08-08 21:15:59 +02:00
Jeroen van Rijn
a05b73c632
Keep -vet happy when mem tracking is disabled.
2024-08-08 21:02:35 +02:00
Jeroen van Rijn
4d27898418
Use test runner's own tracking allocator.
2024-08-08 20:58:25 +02:00
Jeroen van Rijn
80d1e1ba82
Allow testing for intentional leaks in test runner
...
Adds `expect_leak_or_bad_free :: proc(t: ^T, client_test: proc(t: ^T), verifier: Memory_Verifier_Proc)`.
It sets up its own `Tracking_Allocator`, runs the `client_test`, and then calls the `verifier` procedure.
The verifier can then inspect the contents of the tracking allocator and call `testing.expect*` as sensible for the test in question.
Any allocations are then cleared so that the test runner doesn't itself complain about leaks.
Additionally, `ODIN_TEST_LOG_LEVEL_MEMORY` has been added as a define to set the severity of the test runner's memory tracker. You can use `-define:ODIN_TEST_LOG_LEVEL_MEMORY=error` to make tests fail rather than warn if leaks or bad frees have been found.
2024-08-08 20:41:32 +02:00
Roland Kovacs
dda89a69bf
Check if procedure parameter type declares polymorphic args
...
When a procedure parameter's type was declared in an imported package the type
checker correctly resolved to the parametric type, but it did not check if the
expression that refers to that type conforms to a polymorphic type declaration.
This error was not detected if the procedure was unused, since it was marked as
polymorphic, where further type check is done on instantiation.
2024-08-08 19:50:05 +02:00
Jeroen van Rijn
f328929939
Merge pull request #4038 from Hyrtwol/core-sys-windows-rawinput-code
...
Core sys windows rawinput code
2024-08-08 18:23:02 +02:00
Thomas la Cour
3d0519fe6c
trim whitespace
2024-08-08 18:05:41 +02:00
Thomas la Cour
a4eeb6ed02
rawinput code
2024-08-08 18:03:59 +02:00
Jeroen van Rijn
94c62fb630
Fix typo.
2024-08-08 18:01:09 +02:00
Jeroen van Rijn
a7fe9eec73
Merge pull request #4037 from Kelimion/symlink_test
...
Allow symlink test to work irrespective of git settings.
2024-08-08 17:56:05 +02:00
Jeroen van Rijn
d93f3c63d8
Rename package to test_core_os to fit with the rest of test_*
2024-08-08 17:49:08 +02:00
Jeroen van Rijn
ada3df303e
Allow symlink test to work irrespective of git settings.
2024-08-08 17:46:00 +02:00
Laytan Laats
8b98fff98e
add debug build message and align more with build.bat
...
1. if ran without choosing a build type (just `make` or
`build_odin.sh`), print out a message about it being a debug build
2. Add `make release-native` alongside `make release_native` to align
with `build_odin.sh release-native`
3. Only run the demo if it is a debug build (just like `build.bat`)
2024-08-08 15:33:40 +02:00
jason
c3ba8fbd09
add child pipe for reporting post-fork errors
2024-08-08 08:56:29 -04:00
Jeroen van Rijn
4b9ca39522
Merge pull request #4035 from karl-zylinski/build-release-hint
...
Added a hint at end of build.bat about release mode when building in debug mode
2024-08-08 14:48:48 +02:00
Karl Zylinski
26633bbce6
Added a hint at end of build.bat about release mode when building in debug mode.
2024-08-08 14:15:32 +02:00
jason
9625798513
merge commit
2024-08-07 23:27:45 -04:00
Jeroen van Rijn
796feeead9
Remove LLVM copy from nightly.
2024-08-07 22:12:23 +02:00
Jeroen van Rijn
2bf055ec6e
Delete empty file after access check.
2024-08-07 19:38:36 +02:00
Laytan Laats
c9b69d76b0
text/edit: fix undo_state_push wrong builder check
2024-08-07 17:21:56 +02:00
Jeroen van Rijn
69a15ca5b6
Don't copy LLVM shared object on Linux
...
We copy the LLVM shared object when building Odin on Linux. Contrary the comment in `build_odin.sh`,
this is unnecessary, and Odin can be compiled and itself compile things just fine without this step.
This is then packaged up at release and leads to #4019 and #4033 . The Linux release builds are built
on Ubuntu and not strictly supported on other Linux distributions. Building from source is preferred.
2024-08-07 14:50:45 +02:00
Laytan Laats
6fe938b946
darwin: add setAllowedFileTypes binding for open panels
2024-08-06 21:42:33 +02:00
Laytan Laats
e5a478d393
wgpu: fix examples after changing color to an array
2024-08-06 21:42:33 +02:00
Feoramund
793811b219
Add simd_util to examples/all
2024-08-06 15:19:05 -04:00
Feoramund
0418d27bdf
Add benchmarks for vectorized index_* procs
2024-08-06 15:19:05 -04:00
Feoramund
28c98c2e7a
Add tests for vectorized index_* procs
2024-08-06 15:19:05 -04:00
Feoramund
f66fcd9acb
Use vectorized index_* procs in core
2024-08-06 15:19:05 -04:00
Feoramund
8deeb40e5d
Add vectorized index_byte and last_index_byte
2024-08-06 15:19:01 -04:00
gingerBill
39d557bcb4
Merge pull request #4032 from Feoramund/fix-intrinsic-wording
...
Fix SIMD intrinsics wording
2024-08-06 20:13:10 +01:00
Feoramund
e27a424f4d
Swap reduce_any and reduce_all
...
`llvm.vector.reduce.or` will return true if any lane is true.
`llvm.vector.reduce.and` will return true if all lanes are true.
2024-08-06 14:50:34 -04:00
Feoramund
7a367c9c08
Fix documented names of a few SIMD procedures
2024-08-06 14:49:56 -04:00
Laytan
4423aac3de
Merge pull request #4031 from RilleP/bit-field-closing-brace-fix
...
Fix missing closing brace for Bit_Field in core:odin/parser
2024-08-06 20:49:49 +02:00
gingerBill
94ded29b5f
Merge pull request #4030 from Kelimion/struct_field_count
...
Add `reflect.struct_field_count` that returns the number of fields in a struct type
2024-08-06 18:56:24 +01:00
Rikard Petré
6a6f078186
Fix missing closing brace for Bit_Field in core:odin/parser
2024-08-06 19:48:38 +02:00
gingerBill
bed18a17e6
Bodge: Improve aligned_resize logic
2024-08-06 11:22:34 +01:00
Jeroen van Rijn
17ebaffce8
Update comment.
2024-08-05 22:12:22 +02:00
Jeroen van Rijn
4902288a5a
Add reflect.struct_field_count that returns the number of fields in a struct type
...
Example:
```odin
package struct_count_example
import "core:fmt"
import "core:reflect"
import "core:dynlib"
Foo :: struct{
one: int,
two: f32,
}
Bar :: struct {
three: int,
four: bool,
five: f64,
}
Game_Api :: struct {
init: proc(api: ^Game_Api),
update: proc(api: ^Game_Api),
using foo: Foo,
bar: Bar,
// Private stuff
reload_count: int,
__handle: rawptr,
}
API_PRIVATE_COUNT :: 2
game_api: Game_Api
main :: proc() {
fmt.printfln("Game_Api, .Top: %v", reflect.struct_field_count(Game_Api)) // 6
fmt.printfln("Game_Api, .Using: %v", reflect.struct_field_count(Game_Api, .Using)) // 8
fmt.printfln("Game_Api, .Recursive: %v", reflect.struct_field_count(Game_Api, .Recursive)) // 11
symbols_loaded, _ := dynlib.initialize_symbols(&game_api, "game.dll")
symbols_expected := reflect.struct_field_count(Game_Api) - API_PRIVATE_COUNT
if symbols_loaded == -1 {
fmt.eprintln("Couldn't load game.dll")
return
} else if symbols_loaded != symbols_expected {
fmt.eprintfln("Expected %v symbols, got %v", symbols_expected, symbols_loaded)
return
}
}
```
2024-08-05 22:04:16 +02:00
Laytan
a1c3c38f04
Merge pull request #4029 from Feoramund/fix-darwin-sigpipe-send
...
Prevent `SIGPIPE` on Darwin when writing to a closed `core:net` socket
2024-08-05 19:26:16 +02:00
Feoramund
4c0ab09c9a
Handle EPIPE in Darwin core:net
2024-08-05 13:15:08 -04:00
Feoramund
6cc7f3b451
Add FreeBSD Accept_Error.Would_Block alias
2024-08-05 13:00:44 -04:00
Feoramund
3512d7c672
Move Darwin MSG_NOSIGNAL to core:os
2024-08-05 12:49:12 -04:00
Feoramund
eba0774bf3
Prevent SIGPIPE on Darwin when writing to a closed core:net socket
...
Mimics behavior found on Linux implementation.
2024-08-05 12:23:09 -04:00
gingerBill
7c3461b0df
Merge pull request #4028 from Kelimion/fix-4026
...
Fix crash if referencing import "aliased" in other file.
2024-08-05 16:57:58 +01:00
Jeroen van Rijn
2cc3795686
Merge pull request #4027 from karl-zylinski/blend-pixel-compile-fix
...
Fix for blend_pixel.odin in core/image/common.odin not compiling
2024-08-05 17:38:30 +02:00
Karl Zylinski
b63657d293
Fix for blend_pixel.odin in core/image/common.odin not compiling
2024-08-05 17:23:58 +02:00
Jeroen van Rijn
6175efde3d
Fix crash if referencing import "aliased" in other file.
...
Fixes #4026
2024-08-05 17:23:50 +02:00
Jeroen van Rijn
030220eb22
Merge pull request #4025 from karl-zylinski/patch-2
...
core/image/common.odin compile fix
2024-08-05 16:42:09 +02:00
Karl Zylinski
2d32b819dc
common.odin compile fix
...
Fix for "Error: Prefer to separate 'where' clauses with a comma rather than '&&'"
2024-08-05 16:32:34 +02:00
gingerBill
f56abf3780
Add intrinsics.masked_expand_load and intrinsics.masked_compress_store
2024-08-05 14:54:09 +01:00
gingerBill
78919f8524
Fix typos
2024-08-05 14:48:55 +01:00
gingerBill
80ea4e0aeb
Remove dead code
2024-08-05 14:25:33 +01:00
gingerBill
84ac56f778
Add intrinsics.simd_masked_load and intrinsics.simd_masked_store
2024-08-05 14:08:41 +01:00
gingerBill
7e701d1677
Add intrinsics.simd_gather and `intrinsics.simd_scatter
2024-08-05 13:46:24 +01:00
gingerBill
b67ed78afd
add_sat -> saturating_add
2024-08-05 13:21:27 +01:00
gingerBill
90fc52c2ee
Rename add_sat -> saturating_add
2024-08-05 13:19:01 +01:00
gingerBill
9a01a13914
Add simd_reduce_any and simd_reduce_all
2024-08-05 13:13:19 +01:00
gingerBill
eeb92e2644
Allow cast between #simd[N]rawptr <-> #simd[N]uintptr
2024-08-05 13:06:55 +01:00
gingerBill
fd06be2243
Allow swizzle to take more arguments than the original array length
2024-08-05 12:33:02 +01:00
gingerBill
a06cb8ba46
Add #simd[N]rawptr support
2024-08-05 12:04:36 +01:00
Feoramund
d0d4f19097
Remove debug line from test
2024-08-05 03:50:41 -04:00
Feoramund
8f5b838a07
Review manual for loops in core:text/regex
2024-08-05 03:49:29 -04:00
Feoramund
ba0581ae79
Give FreeBSD access to core:net in core:flags
2024-08-05 03:05:50 -04:00
Feoramund
d9404d928c
Add copyright info to core:sys/freebsd
2024-08-05 03:05:50 -04:00
Feoramund
fe754af13d
Add new contribution notes to core:net
2024-08-05 03:05:49 -04:00
Feoramund
61e770d943
Clean up some FreeBSD core:net code
2024-08-05 03:05:43 -04:00
Feoramund
2b63684ccf
Fix integer socket option values for FreeBSD
2024-08-05 02:14:41 -04:00
Feoramund
5ece6980eb
Make EINVAL generic in FreeBSD Socket_Option_Error
...
The documentation for `setsockopt(2)` mentioned accept filters for
`EINVAL`, but I've found that it can arise for any manner of invalid
values for setting socket options.
We'll just have to leave this as a generic error.
2024-08-05 02:14:27 -04:00
Feoramund
42a2297d31
Add core:net tests specifically for FreeBSD
2024-08-05 02:08:48 -04:00
Feoramund
8de48d81ea
Use common name for ENOBUFS
2024-08-05 00:30:39 -04:00
Feoramund
32fb1fb61c
Add missing ECONNRESET TCP_Send_Error
...
This was not specifically documented in `send(2)`.
2024-08-05 00:30:39 -04:00
Feoramund
05c50561ae
Set NOSIGPIPE on all core:net FreeBSD sockets
2024-08-05 00:30:39 -04:00
Feoramund
46455dd0a6
Add more socket options for FreeBSD core:net
2024-08-05 00:30:24 -04:00
Feoramund
3f9ddfe029
Clarify what umtx is
2024-08-04 22:24:55 -04:00
Feoramund
14858309f0
Add explicit license info to core:text/regex
2024-08-04 19:18:16 -04:00
Feoramund
e17fc8272b
Document rationale behind RegEx shorthand classes
2024-08-04 19:12:46 -04:00
Feoramund
dde42f0ebc
Add more documentation for core:text/regex API
2024-08-04 18:56:29 -04:00
Feoramund
ca7e46d56f
Add explicit test case for Capture pos
2024-08-04 18:56:29 -04:00
Feoramund
743480b1a4
Use regex.destroy for test captures
2024-08-04 18:56:29 -04:00
Feoramund
1ccb0b2558
Remove unused code
2024-08-04 18:56:29 -04:00
Feoramund
babdc432e9
Move Flag_To_Letter to core:text/regex/common
2024-08-04 18:56:25 -04:00
Feoramund
d3a51e208d
Hide Regular_Expression values
...
We don't directly support printing these.
To prevent future issues being raised about the pattern being missing if
someone tries to print one, hide everything.
2024-08-04 18:40:27 -04:00
Feoramund
cd8272557f
Test that a RegEx Capture pos corresponds to its groups
2024-08-04 18:33:36 -04:00
gingerBill
7e0fa795e4
Just compare against nil directly if the comparator is known to be nil too
2024-08-04 21:17:58 +01:00
Feoramund
6252712363
Add missing features to regex package documentation
2024-08-04 13:21:13 -04:00
gingerBill
60bc7f53d2
Comment out open_buffered
2024-08-04 17:41:48 +01:00
gingerBill
cf3c1a85ec
Remove temp parameter
2024-08-04 17:36:28 +01:00
gingerBill
046f72befd
Mock out open_buffered
2024-08-04 17:31:39 +01:00
gingerBill
f19436fb4d
Only swap if there was an arena
2024-08-04 17:17:09 +01:00
gingerBill
d0709a7de2
Allow for nested temp_allocator() calls to flip between arenas on TEMP_ALLOCATOR_GUARDs
2024-08-04 17:14:24 +01:00
gingerBill
f427f040fd
Merge pull request #4020 from odin-lang/bill/os-errno
...
`os.Error` to replace `os.Errno`
2024-08-04 15:53:18 +01:00
gingerBill
c078b2dd1b
Add @(require_results)
2024-08-04 15:24:26 +01:00
gingerBill
bf948ab8ae
Add stubs for flush on platforms that didn't have it
2024-08-04 15:07:24 +01:00
gingerBill
acb1ebddf6
Fix err != 0 uses
2024-08-04 15:01:04 +01:00
gingerBill
0bedd3357a
Disallow err != 0 with os.Error when -strict-style is enabled
2024-08-04 14:58:12 +01:00
gingerBill
93fabf8628
Replace err != 0 with err != nil where possible
2024-08-04 14:57:25 +01:00
gingerBill
fc10b781af
Update core/os/os2/process.odin
...
Co-authored-by: Laytan <laytanlaats@hotmail.com >
2024-08-04 14:47:44 +01:00
gingerBill
6a6b5061db
Update core/os/os_darwin.odin
...
Co-authored-by: Laytan <laytanlaats@hotmail.com >
2024-08-04 14:47:35 +01:00
gingerBill
b67817517e
Fix replace typo
2024-08-04 14:46:32 +01:00
gingerBill
fff1d509d5
Add read_entire_file_or_err and write_entire_file_or_err
2024-08-04 14:41:55 +01:00
gingerBill
e8d26c5797
Move errors to where appropriate
2024-08-04 13:41:34 +01:00
gingerBill
3d992e2704
Improve _error_string for Linux
2024-08-04 13:25:35 +01:00
gingerBill
0c5b645dde
Correct EOF value
2024-08-04 13:20:33 +01:00
gingerBill
cf5ec25873
Add extra cases for flush
2024-08-04 13:18:51 +01:00
gingerBill
7663a2036a
Add read_at/write_at to missing platforms
2024-08-04 13:16:37 +01:00
gingerBill
c32f345c68
Move error stuff to errors.odin
2024-08-04 12:55:08 +01:00
gingerBill
649b25fba6
Update the demo.odin to use nil instead of os.ERROR_NONE
2024-08-04 12:47:49 +01:00
gingerBill
bdbbbf5c95
Fix typo; remove unneeded casts
2024-08-04 12:39:21 +01:00
gingerBill
e8b6d15db9
Fix replace typo
2024-08-04 12:31:22 +01:00
gingerBill
5f7fef92fa
Update example to use err != nil instead
2024-08-04 12:25:50 +01:00
gingerBill
66b86bc7e0
Correct os errors for darwin
2024-08-04 12:23:18 +01:00
gingerBill
5187bb68bb
Hack: Convert 0 to nil
2024-08-04 12:08:52 +01:00
gingerBill
97c499dbb4
Begin mapping os.Error in the rest of the codebase
2024-08-04 11:58:04 +01:00
gingerBill
1d75a612d5
os.Errno -> os.Error
2024-08-04 11:47:23 +01:00
gingerBill
160048eaee
Errno -> Error
2024-08-04 11:46:42 +01:00
gingerBill
def2e2e271
Try to map to General_Error where possible
2024-08-04 11:44:45 +01:00
gingerBill
28666414bc
More clean ups of ERROR_NONE and != nil usage
2024-08-04 11:37:49 +01:00
gingerBill
a241168142
Clean up err != nil usage
2024-08-04 11:26:35 +01:00
gingerBill
29b6eebcd5
Clean up error handling
2024-08-04 11:21:09 +01:00
gingerBill
7dae38ce89
Begin mocking out for other errors
2024-08-04 11:12:45 +01:00
gingerBill
1826b0c700
Fix copy-replace errors
2024-08-04 11:10:17 +01:00
gingerBill
9f9abb8fb3
Use union #shared_nil for os.Error
2024-08-04 11:05:30 +01:00
gingerBill
e60951a902
Begin converting os.Errno to be a nil-able type as a transition period
2024-08-04 10:51:08 +01:00
gingerBill
71932628cc
Add alias
2024-08-04 10:08:48 +01:00
jason
c691c7dc68
point stdin, stdout, stderr to /dev/null if unused in os2.process_start
2024-08-04 01:47:10 -04:00
jason
2a7db08c20
Remove returned bool from access and faccessat in sys/linux.
...
Switch to using AT_EMPTY_PATH to execve with file descriptors.
2024-08-04 00:59:40 -04:00
jason
2b89829b52
minor edits in process_linux.odin
2024-08-03 18:08:00 -04:00
Laytan Laats
e77977c8ef
fix vet errors in stb truetype
2024-08-03 23:56:19 +02:00
jason
38b96a7981
change child error behavior to trap instead of exit
2024-08-03 17:50:47 -04:00
Laytan Laats
4dd846fa29
fix readir_r link name for netbsd
2024-08-03 15:54:29 +02:00
Laytan Laats
61008232e4
actually fail CI when NetBSD tests fail
2024-08-03 15:43:35 +02:00
Jeroen van Rijn
90e573c54a
Add image.premultiply_alpha helper.
2024-08-03 12:58:43 +02:00
Laytan
ac483f72eb
Merge pull request #4013 from laytan/fix-os-read-dir-with-symlinks
...
fix os.read_dir with symlinks
2024-08-03 01:08:23 +02:00
Laytan Laats
99d9e8f8b1
fix os.read_dir with symlinks
2024-08-03 00:26:46 +02:00
skytrias
9f5854e24e
Update orca bindings and macros to requested changes
2024-08-02 23:46:02 +02:00
Laytan
772dce7e42
Merge pull request #3969 from elvodqa/master
...
Add `sdl2glue` to `vendor:wgpu` package
2024-08-02 17:18:34 +02:00
Emir
e55d09bdfa
Update vendor/wgpu/examples/sdl2/main.odin
...
Co-authored-by: Laytan <laytanlaats@hotmail.com >
2024-08-02 18:04:36 +03:00
Jeroen van Rijn
1a16585b10
Add image.pixels_to_image helper.
2024-08-02 14:54:52 +02:00
Laytan
500c117312
Merge pull request #4008 from Daxode/wasm-quality-of-life
...
Quality of Life changes to wgpu/js
2024-08-02 13:51:47 +02:00
daniel-andersen
723e6d19be
right number whoops!
2024-08-02 13:38:36 +02:00
Jeroen van Rijn
8e8660fdfc
Merge pull request #4007 from marcosantos98/fix-wasm
...
Fix: compilation error when using BufferSubDataSlice in webgl package
2024-08-02 12:31:23 +02:00
marcosantos98
3bfccde6f9
Fix: remove extra usage in webgl.odin:250
...
Compilation error when using webgl.BufferSubDataSlice.
The `usage` parameter is nowhere to be found.
This is probably a copy-pasta leftover.
2024-08-02 10:50:16 +01:00
daniel-andersen
e7041f785a
Quality of life changes to wgpu/wasm stuff
2024-08-02 11:04:10 +02:00
gingerBill
83599957b1
Merge pull request #3998 from zen3ger/os2-temp_file_linux
...
[os2] Add missing temp_file implementation for Linux
2024-08-01 20:07:21 +01:00
skytrias
f8e0cda113
Add autogenerated orca bindings and macros from laytan
2024-08-01 19:19:24 +02:00
Jeroen van Rijn
0fa62937d5
Fix NetBSD CI
2024-07-31 20:19:13 +02:00
Jeroen van Rijn
f627a38b4f
Update rand.reset() example.
2024-07-31 20:00:55 +02:00
Jeroen van Rijn
cc8c2f236b
Merge pull request #4002 from thetarnav/update-builtin-constants
...
Update comments for builtin constants
2024-07-31 19:47:01 +02:00
Damian Tarnawski
953ae32607
Update builtin constants
2024-07-31 18:55:04 +02:00
Jeroen van Rijn
fdfe6b00e0
Improve output path checking
...
Fixes #4001
2024-07-31 15:16:09 +02:00
Laytan
8a9901aeab
Merge pull request #4000 from lxmcf/master
...
[vendor:raylib] Remove GuiStyleProp
2024-07-31 12:34:00 +02:00
Alex Macafee
1f2ab84e82
Use GuiControlProperty instead of c.int
2024-07-31 19:08:08 +10:00
Alex Macafee
92831d7ca3
Remove GuiStyleProp
2024-07-31 18:58:43 +10:00
Alex Macafee
f33b4ecd3e
Update Raygui Style set/get functions
2024-07-31 18:48:16 +10:00
gingerBill
62191f54a0
Merge pull request #3997 from Hyrtwol/reource-fix-windows
...
fix for using .rc files
2024-07-30 21:26:07 +01:00
gingerBill
04c3723985
Merge pull request #3992 from thetarnav/parser-patch
...
Correct the Array_Type.len comment and assign tok when making Ellipsis node
2024-07-30 21:25:21 +01:00
gingerBill
ac19bb3a8c
Merge pull request #3985 from flysand7/docs-sync
...
[sync]: Document all procedures
2024-07-30 21:24:59 +01:00
Roland Kovacs
1913c08b7b
[os2] Add missing temp_file implementation for Linux
2024-07-30 18:11:44 +02:00
Thomas la Cour
744d7f7ef4
fix for using .rc files
2024-07-30 16:53:14 +02:00
jason
c7eb2ae6bb
use sys/linux dirent instead of manual iteration
2024-07-30 10:19:09 -04:00
jason
792640df1f
remove File_Impl_Kind from file_linux
2024-07-30 09:41:49 -04:00
jason
278a63caaa
remove pidfd availability caching
2024-07-30 09:28:40 -04:00
jason
a03dffcd1a
improve error handling; do not report errors from failed execve
2024-07-30 08:45:53 -04:00
flysand7
3aac4b1a3e
[sync]: Document all procedures
2024-07-30 19:13:35 +11:00
Damian Tarnawski
478b2d7444
Correct the Array_Type.len comment and assign tok when making Ellipsis node
2024-07-29 22:14:42 +02:00
Laytan
7f17d4eb7f
Merge pull request #3991 from laytan/fix-in-map-with-union-variants
...
fix `specific_union_variant in map_keyed_by_union` not converting to union type
2024-07-29 02:39:47 +02:00
Laytan Laats
4d1d754cae
fix specific_union_variant in map_keyed_by_union not converting to union type
2024-07-29 02:32:13 +02:00
Jeroen van Rijn
24e6f16f4a
Clamp dot in angle_between to avoid precision errors.
...
Fixes #3978
2024-07-28 15:00:29 +02:00
Laytan
f852aac0e7
Merge pull request #3989 from colrdavidson/spall_doc
...
Improve Spall Docs slightly to reduce onboarding friction
2024-07-28 12:46:04 +02:00
Colin Davidson
27f75c40ab
make example compile
2024-07-28 01:29:33 -07:00
Colin Davidson
1d598f8287
tweak doc a little to reduce onboarding friction for thread-users
2024-07-28 01:23:47 -07:00
Jeroen van Rijn
cb31df34c1
Merge pull request #3362 from Hyrtwol/sys-windows-2
...
core/sys/windows part 2
2024-07-26 14:29:56 +02:00
Thomas la Cour
271ec643ed
removed some comments
2024-07-26 11:30:48 +02:00
Thomas la Cour
fe587ee79a
try to add sys/windows to the normal core tests
2024-07-26 11:04:13 +02:00
Thomas la Cour
b149b3d6c6
Merge remote-tracking branch 'upstream/master' into sys-windows-2
2024-07-26 10:45:09 +02:00
Thomas la Cour
03f3ea5a9e
removed old test stuff
2024-07-26 10:43:26 +02:00
Thomas la Cour
6e6f2a1f6b
removed obsolete fiels on WIN32_FIND_DATAW to match the size from the winsdk headers
2024-07-26 10:14:13 +02:00
Thomas la Cour
58ab6e5f94
missign cursorinfo
2024-07-26 10:07:20 +02:00
Jeroen van Rijn
4e194d5dbd
Merge pull request #3980 from Kelimion/format-time
...
Add `time.to_string*` formatters.
2024-07-25 21:09:51 +02:00
Jeroen van Rijn
00c6b83537
Use constants in example.
2024-07-25 21:02:38 +02:00
Jeroen van Rijn
ca7d86084e
Improve docs.
2024-07-25 20:58:47 +02:00
Jeroen van Rijn
9088a493d9
Add time.to_string* formatters.
2024-07-25 19:43:42 +02:00
Thomas la Cour
fe4754a77c
format
2024-07-25 10:27:49 +02:00
Thomas la Cour
9d67d12d22
Merge remote-tracking branch 'upstream/master' into sys-windows-2
...
# Conflicts:
# core/sys/windows/shell32.odin
2024-07-25 10:05:41 +02:00
gingerBill
9e82ae10ac
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-24 21:55:55 +01:00
gingerBill
85880f9def
Add more NtDll stuff
2024-07-24 21:55:51 +01:00
Jeroen van Rijn
4ff62994bf
Add CLSCTX_ALL
2024-07-24 22:54:17 +02:00
Feoramund
90f1f7fbdf
Use unaligned_store in regex too
2024-07-24 16:48:49 -04:00
gingerBill
9b624ef9e1
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-24 21:45:40 +01:00
gingerBill
f03c2b7783
General clean up of os2.read_directory for Windows
2024-07-24 21:45:35 +01:00
Feoramund
ff492e615c
Use unaligned_load for regex virtual machine
...
This should hopefully avoid any issues with loading operands greater
than 8 bits on alignment-sensitive platforms.
2024-07-24 16:27:20 -04:00
Feoramund
042f6de478
Remove printing facilities for Regular_Expression
...
The `original_pattern` introduced a tenuous dependency to the expression
value as a whole, and after some consideration, I decided that it would
be better for the developer to manage their own pattern strings.
In the event you need to print the text representation of a pattern,
it's usually better that you manage the memory of it as well.
2024-07-24 16:27:20 -04:00
Feoramund
c52a8a5f86
Allow configuring of MAX_CAPTURE_GROUPS for n > 10
2024-07-24 16:27:08 -04:00
Feoramund
16b644ad79
Use slice.zero instead
2024-07-24 15:23:20 -04:00
Feoramund
e8537a3134
Add test cases for unclosed classes and repetition
...
Simplified error checking while I was at it, too.
2024-07-24 15:21:41 -04:00
Feoramund
e642be8550
Fix handling of unclosed regex classes and repetitions
2024-07-24 15:17:37 -04:00
Jeroen van Rijn
33d6677514
Merge pull request #3951 from Kelimion/lua_test
...
Add Lua example to `vendor:lua` as well as basic tests.
2024-07-24 17:50:49 +02:00
Jeroen van Rijn
8d6ff51922
Copy lua54.dll during CI test
2024-07-24 17:43:51 +02:00
jason
a5fa93e06d
remove ctprintf; use fmt.caprintf; fix pipe_linux that I broke.
2024-07-24 10:23:23 -04:00
jasonKercher
215b21811e
Merge branch 'master' into os2-process-linux
2024-07-24 10:14:59 -04:00
jason
95a8a4e7f0
typo - inverted logic
2024-07-24 10:12:16 -04:00
jason
ecdd3887b2
fix process_info assumptions
2024-07-24 10:09:50 -04:00
gingerBill
2dbccbde54
Improve win32 types
2024-07-24 14:53:48 +01:00
gingerBill
07b1819dc8
Improve os2.read_directory
2024-07-24 14:53:33 +01:00
gingerBill
9d8953538b
Add missing attribute
2024-07-24 14:25:42 +01:00
gingerBill
d4af7b86a7
Begin cleaning up os2.read_directory
2024-07-24 14:19:30 +01:00
gingerBill
38e983cac6
Remove dead code
2024-07-24 13:47:57 +01:00
gingerBill
2ddaae45f3
Better handling of allocators
2024-07-24 13:47:22 +01:00
jason
16bdc6d240
use more iterators; global "has pidfd open" state is now thread-safe
2024-07-24 08:43:22 -04:00
gingerBill
6d2487a692
Add some more Ntdll calls
2024-07-24 13:38:14 +01:00
gingerBill
c407e423d9
Add inode to os2.Stat
2024-07-24 13:37:56 +01:00
gingerBill
0e91c8368c
Add allocator parameters to fmt.caprint*
2024-07-24 09:01:41 +01:00
gingerBill
f08a53015c
Merge pull request #3972 from laytan/testing-json-report
...
testing: add json reporting
2024-07-24 08:35:37 +01:00
Emir
c98bb7da39
Update README.md
2024-07-24 10:33:34 +03:00
Emir
ba81a81ca8
Update os_sdl2.odin
2024-07-24 10:29:34 +03:00
Emir
57dc6c2e94
Update os_sdl2.odin
2024-07-24 10:27:22 +03:00
Emir
95412df129
Add newline to glue_darwin.odin
2024-07-24 10:27:00 +03:00
Emir
2a2bedc85c
Fix indentation and add full example
2024-07-24 10:22:18 +03:00
Laytan Laats
f6488383d7
fix instrumentation features on LLVM versions with typed pointers
...
Fixes #3970
2024-07-24 02:43:53 +02:00
jason
0455e4b60f
remove unused constants; fix comment
2024-07-23 19:48:18 -04:00
Laytan Laats
545fbc54c7
testing: add json reporting
2024-07-24 01:33:22 +02:00
jason
82deaa59ad
os2 linux: fix order of operations bug in _open; fix process_info routine
2024-07-23 17:50:30 -04:00
jason
3c7d1f35db
os2 process implementation for linux
2024-07-23 16:50:00 -04:00
Emir
f9ef951b22
Add sdl2glue/glue_linux.odin
2024-07-23 22:39:50 +03:00
Laytan Laats
fc2e31fcd0
fix build comment in os_freestanding
2024-07-23 20:51:00 +02:00
Emir
e8e51db9ff
Update glue.odin
2024-07-23 20:42:26 +03:00
Emir
a429603195
Remove unused variable from example
2024-07-23 20:39:09 +03:00
Emir
42833d0471
Merge branch 'odin-lang:master' into master
2024-07-23 20:38:04 +03:00
Emir
f3f08a4b47
Add sdl2glue to vendor:wgpu package + triangle example
2024-07-23 20:37:26 +03:00
gingerBill
efa8c92bab
Implement init_long_path_support
2024-07-23 17:46:22 +01:00
gingerBill
65fec9134e
Use SHFileOperationW for remove_all on Windows
2024-07-23 17:30:42 +01:00
gingerBill
a28392852a
Mock out os2.remove_all for Windows
2024-07-23 17:05:41 +01:00
gingerBill
8037ace873
Begin work on os2/dir.odin
2024-07-23 16:47:49 +01:00
gingerBill
182454a1c0
Minor clean ups
2024-07-23 16:09:15 +01:00
gingerBill
24f9e2bbeb
Begin mocking out the linux stuff on os2
2024-07-23 16:06:14 +01:00
gingerBill
61b9a5dbb2
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-23 15:57:23 +01:00
gingerBill
0403626acf
Add utility calls to os2
2024-07-23 15:57:17 +01:00
Laytan
6fc3d32d4b
Merge pull request #3967 from thetarnav/remove-space
...
Remove space in indentation
2024-07-23 13:58:50 +02:00
Damian Tarnawski
eb4f850b7f
Remove space in indentation
2024-07-23 13:48:03 +02:00
Jeroen van Rijn
da80c51195
Merge pull request #3966 from KyleNBurke/sys-windows-add-type
...
Add `NCCALCSIZE_PARAMS` to `sys/windows`
2024-07-23 07:45:44 +02:00
Kyle Burke
9d99f98194
Remove semicolon
2024-07-23 00:22:19 -05:00
Kyle Burke
c32e12c3f5
Add NCCALCSIZE_PARAMS to sys/windows
2024-07-23 00:09:50 -05:00
Laytan
c5fb72340a
Merge pull request #3963 from andreas-jonsson/andreas-jonsson-patch-1
...
Use pkgsrc llvm for NetBSD CI
2024-07-23 04:20:54 +02:00
gingerBill
b0fe777ede
Propagate rodata a bit more in lb_const_value
2024-07-23 03:01:09 +01:00
gingerBill
bc5b41938e
Fix #3964
2024-07-23 02:40:51 +01:00
gingerBill
527c0b3202
Change lib for lz4
2024-07-23 00:19:42 +01:00
gingerBill
6eb28aeafc
Check to see if people are return a slice of a local fixed array from a procedure
2024-07-22 22:52:10 +01:00
gingerBill
12b971746c
vendor:compress/lz4
...
Bindings to lz4 library
2024-07-22 22:42:29 +01:00
gingerBill
ef84382f23
Add suggestion for #3961
2024-07-22 20:11:23 +01:00
Feoramund
b8f3d0fb53
Add core:text/regex to examples/all
2024-07-22 15:07:13 -04:00
Feoramund
be38ba6c5e
Add benchmarks for core:text/regex
2024-07-22 15:07:13 -04:00
Feoramund
3e49ceb82a
Add tests for core:text/regex
2024-07-22 15:07:13 -04:00
Feoramund
730e10bd6f
Support printing Regular_Expression in fmt
2024-07-22 14:25:12 -04:00
Feoramund
cb0704d51c
Add core:text/regex
2024-07-22 14:25:12 -04:00
Jeroen van Rijn
9cad8179b7
Clarify core:time Unix timestamp
2024-07-22 20:00:25 +02:00
Jeroen van Rijn
ccf8b2764d
Create README.md
2024-07-22 18:00:57 +02:00
gingerBill
915c5c3a87
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-22 16:29:35 +01:00
gingerBill
fcaa47986a
Improve error handling for invalid syntax doing [*]T
2024-07-22 16:29:29 +01:00
Jeroen van Rijn
07d2aba310
Simplify exe path check.
2024-07-22 16:36:21 +02:00
Jeroen van Rijn
4889641af4
Merge pull request #3959 from Kelimion/fix-output-is-directory-check
...
Fix .exe path is directory check.
2024-07-22 16:22:17 +02:00
Jeroen van Rijn
90a4d12b30
Fix .exe path is directory check.
2024-07-22 16:11:33 +02:00
Jeroen van Rijn
a39b6de18c
Merge pull request #3958 from Kelimion/fix-3473
...
Fix #3473
2024-07-22 15:41:39 +02:00
Jeroen van Rijn
39657e4d96
Fix #3473
...
Fix the problem where the initial package's directory name ended in .odin.
2024-07-22 15:15:51 +02:00
Laytan
73a9a97413
Merge pull request #3476 from PucklaJ/syscall-fix
...
[sys/linux] Fix fork and execve syscalls on arm64
2024-07-22 13:58:17 +02:00
PucklaJ
1873f7215d
[sys/linux]: Change execveat flags type to Execveat_Flags
2024-07-22 11:03:25 +02:00
Laytan Laats
4d86012d96
install lua for new lua vendor tests
2024-07-22 01:13:50 +02:00
Laytan Laats
a055c03de9
use #directory in lua test
2024-07-22 01:11:01 +02:00
Laytan
68550cf915
Merge pull request #3957 from laytan/fix-any_base-and-any_core
...
fix `reflect.any_base` and `reflect.any_core` with any's containing nil
2024-07-22 01:09:38 +02:00
Laytan Laats
3e618bed40
fix reflect.any_base and reflect.any_core with any's containing nil
2024-07-22 00:51:38 +02:00
Jeroen van Rijn
51733fce68
Merge pull request #3952 from Ronaldr1985/master
...
Ensure that values in ini map are unquoted
2024-07-21 14:58:15 +02:00
Jeroen van Rijn
a056e9da81
Merge pull request #3954 from flysand7/docs-thread
...
[thread]: Document all functions in core:thread
2024-07-21 14:10:49 +02:00
flysand7
b84b4c47d7
[thread]: Document all functions in core:thread
2024-07-21 14:34:36 +11:00
Jeroen van Rijn
431227d4c5
Add NULL check in check_range_stmt
...
Fixes #3953
2024-07-21 02:52:53 +02:00
Ronald
1a6885c2a3
Tidy up code
2024-07-21 00:08:20 +01:00
Ronald
c3a57853e2
Ensure that values in ini map are unquoted
2024-07-21 00:00:47 +01:00
Jeroen van Rijn
fc5ce30f34
Allow json to unmarshal empty struct.
2024-07-21 00:37:11 +02:00
Jeroen van Rijn
572b400d8e
Merge pull request #3950 from Ronaldr1985/master
...
Add tests for encoding/ini
2024-07-20 18:47:08 +02:00
Jeroen van Rijn
f78a792d48
Add Lua example to vendor\lua as well as basic tests.
2024-07-20 18:30:41 +02:00
Ronald
e0a8bd04d5
Ensure deletion of maybe is delayed until we're finished with it.
2024-07-20 17:10:34 +01:00
Ronald
f560b14d10
Fix typo in name of test
2024-07-20 17:10:19 +01:00
Ronald
b584eeaade
Add encoding/ini tests
2024-07-20 16:53:54 +01:00
Jeroen van Rijn
cdd2c98b8d
Merge pull request #3948 from flysand7/docs-time
...
[time]: Document all functions
2024-07-20 16:06:07 +02:00
Jeroen van Rijn
9d6ed991cb
Remove LUA panic for non-big-3 OS
2024-07-20 14:33:34 +02:00
Jeroen van Rijn
2385e1ddd9
Update LUA imports for Darwin.
2024-07-20 14:24:01 +02:00
flysand7
b3ca2d5e0a
[time]: Document all functions
2024-07-20 18:48:50 +11:00
Jeroen van Rijn
64614889de
Merge pull request #3946 from flysand7/x11-fixes
...
[vendor/x11]: Fix missing argument in XDefaultDepth, wrong types in CreateSimpleWindow
2024-07-20 04:00:00 +02:00
Jeroen van Rijn
d9d044970e
Merge pull request #3945 from flysand7/docs-datetime
...
[time/datetime]: Document package datetime
2024-07-20 03:56:21 +02:00
flysand7
0c78cab336
[time/datetime]: Document package datetime
2024-07-20 12:49:40 +11:00
flysand7
15997d2a90
[vendor/x11]: Fix missing argument in XDefaultDepth, wrong types in CreateSimpleWindow
2024-07-20 12:47:00 +11:00
Jeroen van Rijn
7237f9c9f8
Help text default -o:none -> -o:minimal.
2024-07-19 20:47:26 +02:00
gingerBill
ba3d7ba5d3
Add core:encoding/ini to examples/all
2024-07-19 12:03:34 +01:00
gingerBill
f226eba342
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-19 12:00:54 +01:00
gingerBill
393ca40c23
Minor clean ups
2024-07-19 12:00:49 +01:00
gingerBill
62f455f47b
Merge branch 'master' into syscall-fix
2024-07-19 11:43:56 +01:00
gingerBill
163287d9ce
Merge pull request #3938 from Ronaldr1985/master
...
Fix memory leak in encoding/ini
2024-07-19 11:42:35 +01:00
gingerBill
2f8399fe20
Merge pull request #3940 from flysand7/os2-handle-inheritance
...
[os2] Make all handles non-inheritable by default
2024-07-19 11:38:03 +01:00
gingerBill
685dbddcb5
Merge pull request #3939 from flysand7/os2-file-type
...
[os2]: Split file type from mode bits et other small fixes
2024-07-19 11:37:54 +01:00
Laytan Laats
27f9f0ba17
fix OLS #431 , #393
2024-07-18 21:06:37 +02:00
Laytan Laats
2b6a926bb6
fix OLS #52
2024-07-18 21:06:37 +02:00
Laytan
b3d798cb76
Merge pull request #3941 from laytan/wgpu-wayland-improvements
...
improve WGPU / GLFW / Wayland story by weak linking and adjusting docs
2024-07-18 20:20:01 +02:00
Laytan
7134015f56
improve WGPU / GLFW / Wayland story by weak linking and adjusting docs
2024-07-18 19:28:15 +02:00
flysand7
7b501b22bb
[os2]: Split file type from mode bits
2024-07-18 23:09:27 +11:00
flysand7
75605a47e7
[os2]: Make anonymous pipes always inheritable
2024-07-18 22:57:30 +11:00
flysand7
4dcb75af6d
Make all handles non-inheritable by default
...
The sockets are left as non-inheritable because they
never should be inherited.
2024-07-18 22:50:47 +11:00
Ronald
c768d0719a
Remove unnecessary change
...
This was accidentally added, it was a change I made whilst testing.
2024-07-17 21:57:35 +01:00
Ronald
f04db7145c
Fix memory leak in encoding/ini
...
A simple change that fixes a memory leak caused by not deleting all the
values in the map
2024-07-17 21:19:14 +01:00
gingerBill
0bb4cc6ce5
Merge pull request #3935 from IllusionMan1212/win32-drag-n-drop
...
core/sys/windows: added drag and drop procedures
2024-07-16 23:41:52 +01:00
IllusionMan1212
07121f81ff
core/sys/windows: added drag and drop procedures
2024-07-17 00:32:25 +02:00
Jeroen van Rijn
5520b45457
Add glfw LICENSE file
2024-07-16 22:59:32 +02:00
Laytan
cb16d2ddaf
Merge pull request #3934 from laytan/fix-saturating-intrinsics
...
fix `add_sat` and `sub_sat` intrinsics
2024-07-16 22:30:06 +02:00
Laytan Laats
a6d1a2e46c
add #optional_ok to docs file for intrinsics
2024-07-16 22:22:06 +02:00
Laytan Laats
47f14dd9ea
type is never a tuple here
2024-07-16 22:11:54 +02:00
Laytan Laats
853487e86c
fix add_sat and sub_sat intrinsics
2024-07-16 22:07:49 +02:00
gingerBill
0d881e1561
Improve rand.shuffle further by splitting into 64-bit and 32-bit parts
2024-07-16 18:36:31 +01:00
gingerBill
ba49950454
Improve rand.shuffle
2024-07-16 18:33:01 +01:00
gingerBill
f66133959f
Merge pull request #3933 from laytan/fix-some-bugs-with-disable-assert
...
fix some bugs with -disable-assert
2024-07-16 17:54:21 +01:00
Laytan Laats
28fac62a02
fix some bugs with -disable-assert
2024-07-16 18:44:18 +02:00
gingerBill
a3fe5754d9
Make complex32 use higher precision where possible for calculations
2024-07-16 15:31:00 +01:00
gingerBill
df56655ab1
Fix formatting inconsistencies
2024-07-16 14:03:02 +01:00
gingerBill
6702f07762
rawptr -> cstring
2024-07-16 14:02:07 +01:00
gingerBill
03e90bf924
Use RTTI to get the error_string for Windows
2024-07-16 12:26:24 +01:00
gingerBill
8d70a264ab
Check for specific error directly
2024-07-16 12:21:55 +01:00
gingerBill
fe718460c6
Clean up bit_set usage
2024-07-16 12:17:48 +01:00
gingerBill
1afb10109e
Remove the need for temporary variables where possible
2024-07-16 12:13:39 +01:00
gingerBill
3a162de18f
More clean up for process_windows.odin
2024-07-16 12:08:59 +01:00
gingerBill
321ef82d76
Add @(require_results) where needed
2024-07-16 11:57:22 +01:00
gingerBill
169fc4d3be
General clean up of the os2/process_windows.odin code
2024-07-16 11:56:31 +01:00
gingerBill
affe8f7144
Merge pull request #3310 from flysand7/core-process
...
Addition of `core:os2/process` api.
2024-07-16 11:24:24 +01:00
gingerBill
23ca27f40b
Add intrinsics add_sat and sub_sat
2024-07-16 00:48:17 +01:00
Laytan Laats
03426175ae
add workaround for kernel panics on MacOS
2024-07-15 22:45:16 +02:00
Jeroen van Rijn
0a9c150748
Merge pull request #3929 from laytan/fix-fmt-len-transfer-to-children
...
fmt: fix optional_len or use_nul_termination being used by both array and elems
2024-07-15 19:36:20 +02:00
Laytan Laats
f362e0fa20
add test for leaking struct tag into elems
2024-07-15 19:27:48 +02:00
Laytan Laats
d4d910bcfc
fmt: fix optional_len or use_nul_termination being used by both array and elems
...
```odin
My_Struct :: struct {
names: [^]string `fmt:"v,name_count"`,
name_count: int,
}
main :: proc() {
name := "hello?"
foo := My_Struct {
names = &name,
name_count = 1,
}
fmt.println(foo)
}
```
Before: `My_Struct{names = ["h"], name_count = 1}`
After: `My_Struct{names = ["hello?"], name_count = 1}`
2024-07-15 18:51:18 +02:00
Jeroen van Rijn
3a75a8dd1b
Merge pull request #3928 from Yawning/feature/aes-ni
...
core/crypto: Support AES-NI + PCLMUL
2024-07-15 18:41:21 +02:00
Yawning Angel
33dae2e26c
core/crypto/aes: Support the full range of GCM nonce sizes
2024-07-16 01:29:43 +09:00
Yawning Angel
69026852ce
core/crypto/aes: Add Intel AES-NI support
...
This supports AES-NI + PCLMUL, and provides optimized key schedule, ECB,
CTR, and GCM. Other modes are trivial to add later if required.
2024-07-16 01:29:43 +09:00
Yawning Angel
f578994fa6
core/simd/x86: Make the AES-NI intrinsics consistent with Intel
2024-07-16 01:29:43 +09:00
Yawning Angel
1bc21c3481
core/crypto/_aes: Remove redundant sanity checks
2024-07-16 01:29:43 +09:00
Yawning Angel
c9c0b9ea7b
core/crypto: Fix/add some documentation (NFC)
2024-07-16 01:29:43 +09:00
Yawning Angel
390cd3c30d
core/simd/x86: Fix some intrinsics
...
- _mm_slli_si128 produced totally incorrect output
- _mm_storeu_si128 refered to a LLVM intrinsic that is missing
2024-07-16 01:29:43 +09:00
Yawning Angel
401877184f
tests/benchmark/crypto: Benchmark AES256-CTR
2024-07-16 01:29:43 +09:00
Yawning Angel
4815154c31
test/core/crypto: Fix a copy-paste issue in failure spew
2024-07-16 01:29:43 +09:00
Yawning Angel
0d8dadec8a
tests/core/crypto: Fix new -vet issues
2024-07-16 01:29:43 +09:00
Yawning Angel
ff13ee3281
core/crypto: Enforce aliasing restrictions
2024-07-16 01:29:43 +09:00
Yawning Angel
dcaf085bfa
core/bytes: Add alias and alias_inexactly
2024-07-16 01:29:43 +09:00
Laytan Laats
55e0f97cc4
help fmt with Type_Info_Struct and Type_Info_Bit_Field changes
2024-07-15 18:29:06 +02:00
gingerBill
65c91b7dde
Fix code gen issue with bit_set
2024-07-15 15:16:23 +01:00
gingerBill
bd562116b8
Minor change to an internal flag
2024-07-15 15:08:26 +01:00
gingerBill
1e37eaf54d
Begin work for bit_set[...; [N]T] (not working)
2024-07-15 14:49:20 +01:00
flysand7
8df61b7209
[os2/process]: Make get_args() private and use heap_allocator
2024-07-15 23:28:03 +11:00
Yawning Angel
1a30d47ee8
repo: Cleanup the .gitignore to match the new test runner
2024-07-15 21:25:07 +09:00
gingerBill
5cefab8229
Fix case: in type switch issue
2024-07-15 13:22:50 +01:00
gingerBill
7d643bcae3
Make linkage weak in certain places
2024-07-15 12:30:32 +01:00
gingerBill
549311fac9
Fix global variables being "missing" with -use-separate-modules
2024-07-15 12:21:42 +01:00
gingerBill
c5decd3eae
Fix possible race and correct linkage _after_ generation
2024-07-15 11:49:07 +01:00
flysand7
255f00d971
[os2/process]: Implement missing functionality, update docs
2024-07-15 20:24:05 +11:00
gingerBill
664a71454b
-use-separate-modules default on Windows only
2024-07-15 02:53:01 +01:00
gingerBill
432388ac7f
Generate backing array in the case where there is no DeclInfo for the procedure body
2024-07-15 02:42:28 +01:00
gingerBill
cc3cf12ae2
Disable -use-separate-modules by default on darwin until problem is determined
2024-07-15 02:28:27 +01:00
gingerBill
d87583bead
Minimize mutex lock for #load_directory
2024-07-15 02:22:23 +01:00
gingerBill
1b0e98116d
Revert changes to in_single_threaded_checker_stage
2024-07-15 01:47:52 +01:00
gingerBill
eb6805ef40
Disable the need for mutexes in single threaded checker stage
2024-07-15 01:44:23 +01:00
gingerBill
a45e05bb18
Remove need for BlockingMutex in Arena
2024-07-15 01:36:54 +01:00
gingerBill
e4ba786948
Remove use of mutex in single threaded code
2024-07-15 01:29:57 +01:00
gingerBill
cae8c1e94f
Minimize use of mutex in Arena
2024-07-15 01:15:00 +01:00
gingerBill
a8f84c87ae
Add the permanent and temporary arenas directly on the Thread
2024-07-15 01:05:29 +01:00
gingerBill
c64702ae5a
Make -use-separate-modules the default behaviour for -o:none and -o:minimal
2024-07-15 00:43:46 +01:00
gingerBill
3311ea1c76
Keep MSVC happy with secure versions of C calls
2024-07-15 00:38:10 +01:00
gingerBill
018026d844
Use gb_zero_* calls
2024-07-15 00:36:00 +01:00
gingerBill
139c1bcdda
Comment out debug code
2024-07-15 00:25:41 +01:00
gingerBill
46817e8f68
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-15 00:01:31 +01:00
gingerBill
196ac7e6d6
Type erase _make_dynamic_array_len_cap
2024-07-15 00:01:26 +01:00
Jeroen van Rijn
e3e31b42d0
#force_no_inline build_huffman to avoid bloat
2024-07-15 00:54:08 +02:00
gingerBill
f7cb711874
Add #force_no_inline
2024-07-14 23:48:33 +01:00
gingerBill
f657055f12
Add slice variable if not exists
2024-07-14 23:36:54 +01:00
gingerBill
26a9416a41
Minor clean ups
2024-07-14 23:33:35 +01:00
gingerBill
e768bddaeb
Inline _append_elem_string further
2024-07-14 23:22:22 +01:00
gingerBill
83b7dd122a
Type erase for append_elems
2024-07-14 23:20:50 +01:00
gingerBill
b0fbaf24a0
Type erase append_elem
2024-07-14 23:16:11 +01:00
gingerBill
1c3240b6b5
Add #force_no_inline
2024-07-14 23:09:58 +01:00
gingerBill
7673d478b6
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-14 23:09:17 +01:00
gingerBill
15fb4ded2a
type erase resize and reserve internals
2024-07-14 23:09:10 +01:00
Jeroen van Rijn
03cb585845
Merge pull request #3908 from NicknEma/Intrusive-list-docs
...
Write docs for `core:container/intrusive/list` package
2024-07-14 23:28:53 +02:00
gingerBill
9d84e00502
Clean up unquote code
2024-07-14 22:25:26 +01:00
gingerBill
7703b37a1b
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-14 22:23:52 +01:00
gingerBill
95a695e4cd
Fix #3926
2024-07-14 22:23:46 +01:00
gingerBill
02408b713a
Merge pull request #3910 from VladPavliuk/json-add-int-key-map-support
...
Allow to `marshal` and `unmarshal` maps with int keys
2024-07-14 22:00:01 +01:00
gingerBill
251fa477af
Fix type
2024-07-14 21:39:33 +01:00
gingerBill
15a0655988
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-14 21:37:41 +01:00
gingerBill
399c3ab067
Reduce the size of runtime.Type_Info
2024-07-14 21:37:35 +01:00
flysand7
b7ccfed9af
[os2/process]: Implement process_kill
2024-07-15 07:27:44 +11:00
flysand7
4eca60946c
[os2/process]: Refactor process_info procs, add process_info_by_handle
2024-07-15 07:27:44 +11:00
flysand7
8f4755532e
[os2/process]: Adjust docs on process_close function
2024-07-15 07:27:44 +11:00
flysand7
63d94301fc
[os2/process]: Implement process creation procedures
2024-07-15 07:27:43 +11:00
flysand7
e1eed7610c
[os2/process]: Fix leaking memory on errors
2024-07-15 07:27:43 +11:00
flysand7
5d6e0bc793
[os2/process]: Implement retrieving command args in process info
2024-07-15 07:27:43 +11:00
flysand7
c1f5d8f006
[os2/process]: Improve documentation for *process_info() family of function
2024-07-15 07:27:43 +11:00
flysand7
f3d4a734d8
[os2/process]: Fix environment block null-terminator counting
2024-07-15 07:27:43 +11:00
flysand7
6387cd2c24
[os2/process] Added process_info() procedure
2024-07-15 07:27:43 +11:00
flysand7
56d55e4a86
Rebase master
2024-07-15 07:27:43 +11:00
flysand7
6fab055f43
[os2/process]: Add process list function
2024-07-15 07:27:43 +11:00
flysand7
2495f1c39a
[os2/process]: Fill in basic functions
2024-07-15 07:27:43 +11:00
Jeroen van Rijn
65dab3a3b1
Merge pull request #3925 from Feoramund/fix-no-return-switch
...
Fix compiler crash when switching on no value
2024-07-14 21:26:46 +02:00
Feoramund
b38237e8f0
Fix compiler crash when switching on no value
2024-07-14 14:59:00 -04:00
NicknEma
63276a85ba
Fixed grammar and expanded info
...
Fixed points made by Jeroen.
2024-07-14 18:18:12 +02:00
VladPavliuk
3f8712edb0
Merge branch 'master' into json-add-int-key-map-support
2024-07-14 18:22:20 +03:00
gingerBill
e7d37607ef
Fix parameter to none
2024-07-14 16:05:47 +01:00
gingerBill
6feace2351
Add pseudo flag -fast-build
2024-07-14 16:05:07 +01:00
gingerBill
a867378418
Default to -o:minimal again
2024-07-14 15:55:26 +01:00
gingerBill
11e2aa2d51
Improve error message
2024-07-14 15:31:40 +01:00
gingerBill
556355ef05
Disallow global use of target specific procedure calls
2024-07-14 15:30:40 +01:00
gingerBill
5de6016e7f
Clean up os2.File.impl usage
2024-07-14 15:26:59 +01:00
gingerBill
2d56e3805b
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-14 15:09:38 +01:00
gingerBill
4f73b35da5
Make os2.File a more generic interface
2024-07-14 15:09:33 +01:00
Jeroen van Rijn
76b0562acd
Merge pull request #3923 from laytan/fix-off-by-one-in-queue-back
...
Fix off-by-one in queue `back` and `back_ptr` procs
2024-07-14 16:09:16 +02:00
Laytan Laats
d90d7ed002
Fix off-by-one in queue back and back_ptr procs
2024-07-14 16:00:55 +02:00
gingerBill
3d38f14202
Use fstat on os2.File directly
2024-07-14 14:51:22 +01:00
gingerBill
d1450e3d88
Fix styling issues
2024-07-14 14:44:22 +01:00
gingerBill
eff46c2e5f
Merge pull request #3919 from colrdavidson/growing_workpool
...
move to a growing workstealing queue
2024-07-14 14:39:49 +01:00
gingerBill
8319917898
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-14 14:07:42 +01:00
gingerBill
2e0c5fefde
Reuse the slice value too for variadic parameters (LLVM >= 13)
2024-07-14 14:07:36 +01:00
Jeroen van Rijn
88823c4024
Merge pull request #3921 from Ronaldr1985/master
...
Fix logic bug in core/encoding/ini/ini.odin
2024-07-14 14:48:47 +02:00
gingerBill
6959554040
Calculate size and alignment, and reuse memory for all variadic calls within a procedure body
2024-07-14 13:44:47 +01:00
gingerBill
0a530b5ce8
Add error for #no_capture being reserved for future use
2024-07-14 13:20:12 +01:00
gingerBill
8650180ccc
Change Odin calling convention to not do a copy on byval for SysV
2024-07-14 12:59:55 +01:00
gingerBill
5027c7081e
Reuse slice variable for variadic parameters
2024-07-14 12:50:33 +01:00
gingerBill
3533094cc2
Restrict #no_capture to pointer-like types only
2024-07-14 12:44:13 +01:00
gingerBill
5ce6676914
Make #no_capture map to nocapture
2024-07-14 12:41:16 +01:00
gingerBill
3dff83f3dc
Mock out #no_capture for future use
2024-07-14 12:39:30 +01:00
gingerBill
8642d719f0
Imply #no_capture to all variadic parameters
2024-07-14 12:19:47 +01:00
gingerBill
891cf54b5c
Add f16 to #c_vararg promotion rules
2024-07-14 12:03:34 +01:00
gingerBill
3ba19d94cf
Add #no_capture to core:odin/ast
2024-07-14 11:58:26 +01:00
gingerBill
c7bd954752
Add more uses of #no_capture
2024-07-14 11:56:04 +01:00
Ronald
7e4e3429d7
Fix logic bug in core/encoding/ini/ini.odin
...
The load_map_from_path had incorrect logic where it would return false
for ok when err was equal to nil and true when there was an error.
2024-07-14 11:48:34 +01:00
gingerBill
edc793d7c1
Add #no_capture args: ..T to reuse the backing array stack memory
2024-07-14 11:39:05 +01:00
gingerBill
f98a7b84df
Merge pull request #3914 from VladPavliuk/json-add-ignore-tag-support
...
Add support of `ignore` tag for `json.marshal`
2024-07-14 10:38:15 +01:00
gingerBill
0050cb9471
Merge pull request #3918 from flysand7/file-handle-inheritance2
...
[os2/file]: Fixes related to handle inheritance
2024-07-14 10:36:10 +01:00
Colin Davidson
64feb7599e
move to isize
2024-07-14 00:33:40 -07:00
Colin Davidson
4420128dc1
handle steal-fail vs steal-empty
2024-07-14 00:29:58 -07:00
Colin Davidson
cdede4928c
move to a growing queue
2024-07-13 23:16:22 -07:00
flysand7
b686b072d5
[os2/file]: Fixes related to handle inheritance
...
All file handles created on Windows used to be made
non-inheritable, by forcing the .Close_On_Exec flag
in _open() function. In addition, there was an
issue with security descriptor being freed before
use, which has been fixed.
2024-07-14 15:06:28 +11:00
VladPavliuk
76fe5d1346
Align ignore syntax of json tags with fmt, cbor
2024-07-14 00:21:05 +03:00
gingerBill
8cebc7cc0c
Merge pull request #3915 from tadeohepperle/vendor-wgpu-RenderPassEncoderSetPushConstants-signature
...
vendor/wgpu: RenderPassEncoderSetPushConstants should take a rawptr instead of cstring
2024-07-13 15:16:21 +01:00
Tadeo hepperle
75076e2d64
RenderPassEncoderSetPushConstants should take a rawptr instead of cstring for the data
2024-07-13 16:01:33 +02:00
VladPavliuk
64ae99f016
Add support of ignore tag for json.marshal
2024-07-13 14:13:59 +03:00
Jeroen van Rijn
d845a07519
Merge pull request #3912 from xzores/master
...
Update stb_truetype.odin
2024-07-13 00:16:34 +02:00
xzores
b4683f4399
Update stb_truetype.odin
2024-07-12 23:57:45 +02:00
VladPavliuk
79e2f63182
Small code refactoring in test_core_json
2024-07-13 00:38:58 +03:00
VladPavliuk
39983eaaa4
Remove unused imports in test_core_json
2024-07-13 00:26:54 +03:00
VladPavliuk
dbdad0476d
Allow to marshal and unmarshal maps with int keys
2024-07-13 00:07:48 +03:00
Thomas la Cour
3627a51daf
Merge remote-tracking branch 'upstream/master' into sys-windows-2
2024-07-12 16:06:48 +02:00
gingerBill
e715674512
Merge pull request #3907 from flysand7/console-read-fix
...
[core/os]: Fix read_console edge case bug
2024-07-12 14:58:40 +01:00
gingerBill
9e0c4098be
Merge pull request #3905 from flysand7/winapi-process-procs
...
[sys/windows]: Advapi bindings, process-related functions and thread context
2024-07-12 14:58:27 +01:00
NicknEma
d10694901f
Simplify and fix doc examples
...
Remove unnecessary examples;
fix compilation errors in the remaining ones
2024-07-12 15:48:47 +02:00
NicknEma
c75a872909
Write doc comments in intrusive_list.odin
...
Write description, inputs/returns and some examples for each procedure
2024-07-12 15:37:34 +02:00
NicknEma
a348a7e84e
Create doc.odin
...
Create a doc file with a brief of the package and an example program (copied from a discord message by laytan)
2024-07-12 15:18:58 +02:00
flysand7
a7d95ab3e1
[core/os]: Fix read_console not stopping the read when newline can't fit in output slice
2024-07-12 20:28:38 +11:00
flysand7
6ae47c6f43
[sys/windows] Add advapi bindings, process-related functions and context-related stuff
2024-07-12 19:21:44 +11:00
Thomas la Cour
3291c59728
post rebase
2024-07-11 21:37:37 +02:00
Thomas la Cour
dd75b7a4d9
Merge remote-tracking branch 'upstream/master' into sys-windows-2
...
# Conflicts:
# core/sys/windows/kernel32.odin
# core/sys/windows/types.odin
# core/sys/windows/user32.odin
# core/sys/windows/winerror.odin
2024-07-11 21:20:53 +02:00
gingerBill
1770e3a9a9
Fix typo
2024-07-11 17:19:12 +01:00
gingerBill
19753ed8a3
Add rand.Generator and other calls
2024-07-11 17:12:42 +01:00
gingerBill
59d87d1f05
Add gen := context.random_generator parameters to rand calls
2024-07-11 17:01:34 +01:00
gingerBill
6b3453cc64
Fix #3902
2024-07-11 13:08:38 +01:00
gingerBill
5e7634d90c
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-11 13:04:32 +01:00
gingerBill
fc7c7cd8ab
Merge pull request #3900 from Kelimion/winres
...
Allow precompiled resources with `-resource:foo.res`
2024-07-11 12:51:25 +01:00
gingerBill
e05e99253b
Merge pull request #3904 from laytan/make-instrumentation-work-on-wasm
...
make instrumentation "work" on wasm
2024-07-11 12:50:51 +01:00
Jeroen van Rijn
a8ce5bd005
Merge pull request #3903 from laytan/allow-mem-virtual-import-on-more-targets
...
allow `core:mem/virtual` import on more targets by expanding the `other` implementation
2024-07-11 02:12:53 +02:00
Laytan Laats
65ca03a930
make instrumentation "work" on wasm
...
Using instrumentation on WASM causes it to complain about the
llvm.returnaddress instrinsic. This PR could be considered a "hack" but
makes this work by just passing `nil` instead of the return address.
2024-07-11 01:57:00 +02:00
Laytan Laats
0dfc660c71
allow core:mem/virtual import on more targets by expanding the other implementation
2024-07-11 01:55:59 +02:00
Jeroen van Rijn
c49afb0039
Add hinstdll forward to runtime globals
2024-07-10 19:58:29 +02:00
Jeroen van Rijn
b02291b20a
Compile demo with -vet -strict-style.
2024-07-10 19:26:35 +02:00
gingerBill
f75a45c3fa
Add aliases starts_with and ends_with
2024-07-10 16:34:15 +01:00
gingerBill
7e41340510
Unify IUnknown COM interface
2024-07-10 15:20:07 +01:00
Jeroen van Rijn
4148c6d6c7
#if WINDOWS
2024-07-10 15:25:49 +02:00
Jeroen van Rijn
cc73e06a46
Allow precompiled resources with -resource:foo.res
...
And add them to the magic new feature.
2024-07-10 15:09:13 +02:00
gingerBill
733b7c704c
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-10 13:45:27 +01:00
gingerBill
c54e3d3c4f
Improve warning handling for possible default: typo
2024-07-10 13:45:21 +01:00
Jeroen van Rijn
8dc4eca4d2
Allow using precompiled .res file.
2024-07-10 14:25:18 +02:00
gingerBill
34c6868e78
Merge pull request #3895 from laytan/fix-optimization-mode-attribute
...
remove misleading @(optimization_mode) values and make "none" inhibit optimizations
2024-07-10 13:22:57 +01:00
gingerBill
38315f83da
Merge pull request #3898 from laytan/fix-enable-target-features-for-poly-procs
...
fix require/enable target feature attribute on poly procs
2024-07-10 13:22:06 +01:00
gingerBill
5aa1f3751b
Merge pull request #3899 from laytan/fix-more-attributes-not-applied-to-poly-procs
...
fix optimization mode, cold, and disabled not being applied to poly procs
2024-07-10 13:21:57 +01:00
gingerBill
36301d0359
Give better syntax error messages for things like #define Example 123
2024-07-10 13:03:38 +01:00
gingerBill
c83307f26f
Give error message suggestion when doing ^x instead of x^ if x is an r-value
2024-07-10 12:39:42 +01:00
gingerBill
30204837ce
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-10 12:28:23 +01:00
gingerBill
f85f6b338a
Change .. variadic logic; comment out unneeded error message
2024-07-10 12:28:15 +01:00
Laytan Laats
40625b24e2
fix optimization mode, cold, and disabled not being applied to poly procs
2024-07-09 19:49:12 +02:00
Laytan Laats
1fce5791a1
fix require/enable target feature attribute on poly procs
2024-07-09 19:33:25 +02:00
Jeroen van Rijn
d43a2daa17
Merge pull request #3897 from Kelimion/simd-vet
...
Let simd/x86 pass new transmute/cast vet.
2024-07-09 17:04:45 +02:00
Jeroen van Rijn
7b31acd2d7
Let simd/x86 pass new transmute/cast vet.
2024-07-09 16:50:55 +02:00
gingerBill
b83822fd35
#3892 - Use temporary directory for asm file generation
2024-07-09 15:41:05 +01:00
gingerBill
ae2f16edea
Fix #3894
2024-07-09 15:29:36 +01:00
gingerBill
9782d7b928
Merge pull request #3896 from odin-lang/cached-builds
...
Internal Cached Builds
2024-07-09 15:27:45 +01:00
gingerBill
5627af582a
Add RPROMPT to blacklist
2024-07-09 15:18:15 +01:00
gingerBill
d701642293
Check for PROMPT
2024-07-09 15:15:23 +01:00
gingerBill
4c1754b1dc
environ is only for Linux
2024-07-09 14:56:12 +01:00
gingerBill
666703f430
Mock out \*nix stuff for cached.cpp
2024-07-09 14:47:22 +01:00
gingerBill
14dc3598b4
Add gb_internal to procedures
2024-07-09 14:33:01 +01:00
gingerBill
330d0e7a2a
Add debugf calls
2024-07-09 14:30:38 +01:00
gingerBill
952fb998e6
Check for CURR_DATE_TIME
2024-07-09 14:20:55 +01:00
gingerBill
886ee66e7f
Cache files, env, and args
2024-07-09 14:16:56 +01:00
gingerBill
68b70a2183
Check for bounds check error
2024-07-09 13:35:52 +01:00
gingerBill
ccdad8b8dd
Add odin clear-cache
2024-07-09 13:31:54 +01:00
gingerBill
45bf180847
Add subtarget to cached executable
2024-07-08 23:55:01 +01:00
gingerBill
87ac68fcf2
Add -internal-cached
2024-07-08 23:39:14 +01:00
Jeroen van Rijn
9575d85f1a
Merge pull request #3511 from IllusionMan1212/x11-xkb
...
vendor/x11: some XKB extension procedures and constants
2024-07-08 21:14:26 +02:00
Laytan Laats
2d8d0dd851
fix @(optimization_mode) usage in builtin collections
2024-07-08 21:07:53 +02:00
Laytan Laats
1a20b78633
remove misleading @(optimization_mode) values and make "none" inhibit optimizations
2024-07-08 21:06:57 +02:00
IllusionMan1212
0c27d95679
vendor/x11: some XKB extension procedures and constants
2024-07-08 21:00:19 +02:00
gingerBill
a3af94eeae
Merge pull request #3893 from laytan/temporary-directory-non-windows
...
implement `temporary_directory` on non-windows
2024-07-08 18:25:34 +01:00
Laytan Laats
9ff77397c6
implement temporary_directory on non-windows
2024-07-08 18:58:17 +02:00
gingerBill
48aef50164
Add #load cache files to -export-dependencies:json
2024-07-08 17:46:10 +01:00
gingerBill
fc9c995dc4
Fix fmt for code compilation bug with any
2024-07-08 16:39:13 +01:00
gingerBill
564d5af8b2
Default to -o:none for all builds
2024-07-08 16:12:22 +01:00
gingerBill
2c9ef6907a
Clean up timings messages showing used module count
2024-07-08 15:30:33 +01:00
gingerBill
505dec7b14
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-07-08 15:13:45 +01:00
gingerBill
2a219fa830
Correct -use-separate-module behaviour
2024-07-08 15:13:40 +01:00
gingerBill
498fb00c25
Merge pull request #3890 from laytan/llvm-18-non-windows-releases
...
ci: make releases use LLVM 18
2024-07-08 14:57:21 +01:00
Jeroen van Rijn
ec2234560a
Merge pull request #3889 from laytan/darwin-remove-implicit-syscall-usage
...
darwin: remove syscall usage (without -no-crt) to comply to Apple guidelines
2024-07-08 15:54:24 +02:00
Laytan Laats
5dd89a29e6
ci: make releases use LLVM 18
...
Since we updated to LLVM 18 on Windows now, we should make the releases
for non-windows use LLVM 18 too, this way all releases use the same version.
2024-07-08 15:49:37 +02:00
gingerBill
8491e2491c
Experiment with different uses of -use-separate-modules
2024-07-08 14:48:59 +01:00
Laytan Laats
ddad2011e2
darwin: remove syscall usage (without -no-crt) to comply to Apple guidelines
2024-07-08 15:39:23 +02:00
gingerBill
7dd4cccce7
Use a temporary directory for -use-separate-modules
...
Windows only currently
2024-07-08 14:21:07 +01:00
gingerBill
0f664893dd
Add sort for global types and procedures
2024-07-08 13:59:25 +01:00
gingerBill
04e0b3e270
Merge pull request #3887 from odin-lang/windows-llvm-18
...
Update to LLVM 18.1.8 for Windows
2024-07-08 13:25:22 +01:00
gingerBill
930a147f24
Update to LLVM 18.1.8
2024-07-08 13:08:18 +01:00
gingerBill
86c58167ed
Add -print-linker-flags
2024-07-08 10:40:04 +01:00
Jeroen van Rijn
212906ecd2
Merge pull request #3886 from laytan/cbor-enhancements
...
CBOR enhancements
2024-07-08 02:01:39 +02:00
Laytan Laats
6ab559437a
encoding/cbor: add a custom tag to the example
2024-07-08 01:01:11 +02:00
Laytan Laats
db3b4ceb4a
encoding/cbor: improve perf of marshalling array-like types
2024-07-08 00:37:40 +02:00
Laytan Laats
39e9b65c59
encoding/cbor: fix umarshal of big fixed arrays
2024-07-08 00:35:19 +02:00
Laytan Laats
56856b6307
io: remove dead code in io.write_at_least
2024-07-08 00:33:50 +02:00
Jeroen van Rijn
861ad2037f
Merge pull request #3884 from Feoramund/fix-3883
...
Forbid `$T=` parameter from crashing compiler
2024-07-06 22:08:05 +02:00
Feoramund
77d64a5461
Forbid $T= parameter from crashing compiler
...
Fixes #3883
2024-07-06 15:32:17 -04:00
gingerBill
88c9512d5f
Merge pull request #3828 from laytan/re-raise-signals-from-odin-run
...
re-raise signals from the `odin run` binary
2024-07-06 18:55:37 +01:00
Jeroen van Rijn
b79a098c2e
Merge pull request #3882 from Kelimion/clean_up_iterator
...
Remove nil checks.
2024-07-06 18:45:45 +02:00
Jeroen van Rijn
258f120d52
Remove nil checks.
...
The caller should really not pass `foo: ^string = nil`. A `for ch, in foo` would also crash,
so let's not introduce new semantics for iteration.
A caller shouldn't pass garbage if they can help it, and a `nil` ^string is not a useful ZII usage here.
2024-07-06 18:34:52 +02:00
gingerBill
80d122f531
Merge pull request #3879 from caquillo07/hm/adding-missing-env-calls-to-core-os-darwin
...
Add Darwin setenv and unsetenv syscalls
2024-07-06 12:55:29 +01:00
gingerBill
efe5e9e349
Merge pull request #3858 from flysand7/wow64-apiset
...
Add bindings for WOW64 API set
2024-07-06 00:23:47 +01:00
Jeroen van Rijn
25904e8f89
Merge pull request #3878 from Poaetce/setsid-returns-pid
...
[sys/linux]: change setsid to return Pid
2024-07-06 01:21:22 +02:00
Hector Mejia
2b854c94da
added the setenv and unsetenv bindings for darwin, inspired but os_linux.odin
2024-07-05 16:26:03 -04:00
poa
8c98ca3a10
updated return value of setsid to return Pid
2024-07-05 22:53:45 +09:00
Jeroen van Rijn
ecffe5a082
Merge pull request #3877 from Kelimion/wstring_fix
...
Fix utf8_to_wstring given zero bytes.
2024-07-05 13:58:49 +02:00
Jeroen van Rijn
9ecc33570b
Improve fix.
2024-07-05 13:51:38 +02:00
Jeroen van Rijn
164a5e587e
Fix utf8_to_wstring given zero bytes.
2024-07-05 13:46:07 +02:00
Jeroen van Rijn
c8432df248
Merge pull request #3874 from laytan/fix-not-detecting-duplicate-proc-case
...
Fix not detecting duplicate proc cases
2024-07-05 01:00:14 +02:00
Laytan Laats
f66b7021a6
Fix not detecting duplicate proc cases
...
Fixes #3864
2024-07-05 00:50:52 +02:00
Jeroen van Rijn
22fabba2f6
Fix #3873
2024-07-05 00:48:08 +02:00
gingerBill
c77f5b00bc
Merge pull request #3872 from laytan/fix-assertion-failure-on-old-llvm
...
Fix assertion false negative
2024-07-04 23:27:11 +01:00
Laytan Laats
1bd9fe04c4
Fix assertion false positive
...
Assertion was added in #3855 - https://github.com/odin-lang/Odin/pull/3855/commits/723314909679b89e159cb4cb05d250d12ac64436
to mimic LLVM's own internal assertion for this, turns out their
assertion is more sophisticated than an `==` so lets just remove it.
To be clear their internal assertion is not hit while this one is, which
defeats the purpose of ours.
2024-07-04 23:55:21 +02:00
Jeroen van Rijn
3c2161b196
Merge pull request #3870 from laytan/fix-fontstash-proc-group
...
vendor/fontstash: fix 'AddFont' proc group for JS target
2024-07-04 17:05:49 +02:00
Jeroen van Rijn
5247d3749c
Merge pull request #3871 from Kelimion/dynlib_temp
...
Remove implicit allocator usage in `core:dynlib`
2024-07-04 17:05:21 +02:00
Jeroen van Rijn
8bee73b08e
Remove implicit allocator usage in core:dynlib
2024-07-04 16:53:00 +02:00
Laytan Laats
bcdb202639
vendor/fontstash: fix 'AddFont' proc group for JS target
2024-07-04 16:50:58 +02:00
gingerBill
1eb0bc1408
Remove *_test.odin; always compile it for all targets
2024-07-04 14:43:57 +01:00
gingerBill
e9a54666e2
Fix typo.
2024-07-04 14:41:10 +01:00
gingerBill
8b7c6a23ba
Restrict a bit more
2024-07-04 14:06:02 +01:00
gingerBill
bf711b282d
Remove when check in check_entity_from_ident_or_selector
2024-07-04 13:58:36 +01:00
gingerBill
87bccc8f3f
Remove import name cases
2024-07-04 13:53:52 +01:00
gingerBill
657bc88535
Allow x :: y when cond else proc(...){...}
2024-07-04 13:48:52 +01:00
gingerBill
45b2a6a19e
Fix reflect.as_pointer
2024-07-04 13:37:47 +01:00
gingerBill
d78ff0be52
Fix lb_store_type_case_implicit
2024-07-04 13:20:36 +01:00
gingerBill
52c219690a
Ff @(disabled=true), do not add that entity's dependencies to the set
2024-07-04 13:09:31 +01:00
gingerBill
053f1759d7
Merge pull request #3866 from DerTee/test_mem_dynamic_pool
...
add test for mem.dynamic_pool and fix alignment bug
2024-07-03 22:17:57 +01:00
gingerBill
b65aa9c439
Merge pull request #3867 from karl-zylinski/error-on-typeof-untyped-type
...
error on type_of(value of untyped type)
2024-07-03 22:09:59 +01:00
Karl Zylinski
782286357b
error on type_of(value of untyped type)
2024-07-03 22:21:32 +02:00
DerTee
6b373cf49e
fix #3692 memory alignment bug in core:mem.dynamic_pool_alloc_bytes
2024-07-03 22:14:28 +02:00
DerTee
a76f9a70d5
add test for allocator mem.Dynamic_Pool
...
this test currently fails because of bug #3692
2024-07-03 22:13:20 +02:00
Jeroen van Rijn
a276722da5
Merge pull request #3865 from Feoramund/fix-sdl-constants
...
Fix SDL constants
2024-07-03 21:31:53 +02:00
Feoramund
bb6cbf6559
Fix SDL constants
2024-07-03 15:22:39 -04:00
Jeroen van Rijn
f6892d2236
Fix help text.
2024-07-03 19:30:25 +02:00
gingerBill
075384b2bb
Fix #soa assignment bug
2024-07-03 00:33:13 +01:00
gingerBill
7e6acdf800
Merge pull request #3855 from laytan/master
...
Fix two LLVM assertion failures
2024-07-02 22:16:49 +01:00
gingerBill
8b49549fd3
Merge pull request #3859 from laytan/wasm-stbtt-object-linking-preopens
...
wasm: support `vendor:stb/truetype` and `vendor:fontstash`
2024-07-02 22:14:54 +01:00
Jeroen van Rijn
0ceae51223
Merge pull request #3862 from laytan/fix-empty-webgpu-link-errors
...
vendor/wgpu: fix linker errors with empty project
2024-07-02 23:05:34 +02:00
Laytan Laats
761a50e145
vendor/wgpu: fix linker errors with empty project
2024-07-02 22:37:02 +02:00
Laytan Laats
5399093050
make preopens a slice and remove bad current_dir
2024-07-02 20:17:24 +02:00
Laytan Laats
0ef5191540
use slice.ptr_swap instead of alloca
2024-07-02 20:11:44 +02:00
Laytan Laats
10c68a8951
wasm: support vendor:stb/truetype and vendor:fontstash
2024-07-02 16:03:42 +02:00
Laytan Laats
4e18e1b191
wasi: make os.open work with absolute paths
2024-07-02 15:29:24 +02:00
Laytan Laats
6f1cc8071c
wasm: add foreign import and linking of wasm object files
2024-07-02 15:28:08 +02:00
flysand7
41282b5211
Add bindings for WOW64 API set
2024-07-02 21:56:04 +11:00
Jeroen van Rijn
0697fd0101
Merge pull request #3857 from flysand7/tlhelp-modentry
...
[sys/windows]: Fix the type declaration for MODULEENTRY32W
2024-07-02 12:42:18 +02:00
flysand7
62d107bea5
[sys/windows]: Fix the type declaration for MODULEENTRY32W
2024-07-02 21:34:54 +11:00
Andreas T Jonsson
b26f4e0766
Use pkgsrc llvm for NetBSD CI
2024-07-02 11:43:01 +02:00
Laytan Laats
7233149096
fix llvm assertion failure when const initializer is not the same type
2024-07-02 01:25:52 +02:00
Laytan Laats
c822f0b8c8
fix llvm assertion about metadata on non-instruction
2024-07-02 01:14:50 +02:00
Jeroen van Rijn
d912c6e320
Merge pull request #3849 from Feoramund/zero-mantissa
...
Don't factor trailing zeroes into mantissa division
2024-07-01 20:53:07 +02:00
Jeroen van Rijn
f7243eac74
Force cl.exe to parse Odin source as utf-8.
2024-07-01 20:48:00 +02:00
Jeroen van Rijn
c2ab2bf25a
Add UTF-8 BOM for ucg.c, because reasons.
2024-07-01 20:23:48 +02:00
gingerBill
b4ca044ae0
Merge pull request #3846 from Feoramund/add-more-net-tests
...
Add more `core:net` tests
2024-07-01 17:56:07 +01:00
gingerBill
a2b23de0a7
Sanity check for a nullptr
2024-07-01 12:24:46 +01:00
gingerBill
42ff711114
Fix #3515
2024-07-01 12:22:18 +01:00
gingerBill
544959326b
Add intrinsics.type_struct_has_implicit_padding #3844
2024-07-01 12:13:35 +01:00
gingerBill
942f3f5220
Add non_zero_* variants for #soa dynamic array
2024-07-01 12:04:29 +01:00
gingerBill
8ddfcf174d
Add #soa support to append directly
2024-07-01 11:51:28 +01:00
gingerBill
4086a62167
Fix showing error when not meant to
2024-07-01 11:50:35 +01:00
gingerBill
3a43928184
Add #no_broadcast to append_soa
2024-07-01 11:47:33 +01:00
gingerBill
7f6fe91896
Add #soa forms to reserve, clear, and resize
2024-07-01 11:37:21 +01:00
gingerBill
11617af8f5
Add support for make(#soa[]T) etc
2024-07-01 11:34:50 +01:00
gingerBill
4a2b87672c
Unify #soa code for structs and arrays
2024-07-01 11:11:06 +01:00
gingerBill
fb0b95bcad
Merge pull request #3760 from Feoramund/refactor-show-error-on-line
...
Refactor `show_error_on_line`
2024-07-01 11:03:29 +01:00
gingerBill
1a4edad63e
Merge pull request #3848 from laytan/wasm-c-abi-indirect-multifield-struct
...
make structs with multiple fields always return indirect in wasm c abi
2024-07-01 11:02:49 +01:00
Feoramund
8cd7fd95a3
Don't factor trailing zeroes into mantissa division
...
This should fix issues where `N00 / (pow+2)` results in a different number
than `N / pow`.
2024-06-30 22:18:25 -04:00
Laytan Laats
ef6a73c7ef
fix not setting cc before using it in abi computations
2024-07-01 01:30:44 +02:00
Laytan Laats
e3dde8caf8
make structs with multiple fields always return indirect in wasm c abi
2024-07-01 00:50:10 +02:00
Feoramund
8e64265aed
Replace unneeded transmute
2024-06-30 16:39:22 -04:00
Feoramund
1e7dfd0e34
Add more core:net tests
...
- UDP send & read
- DNS resolution
- Nonblocking socket option
2024-06-30 16:39:22 -04:00
gingerBill
13ace1dac9
Merge pull request #3839 from flysand7/tlhelp-fix
...
[sys/windows]: Fix the value for TH32CS_SNAPPROCESS constant
2024-06-30 20:15:33 +01:00
Jeroen van Rijn
efd933e221
Merge pull request #3842 from karl-zylinski/fix-poly-bitset-size
...
Fix for bit_set[$T] proc params always being generated as i8
2024-06-30 21:10:42 +02:00
Karl Zylinski
e0face1ac8
Make types like bit_set[$T] have their upper and lower bits overwritten by upper/lower from the source types when checking if polymorphic type is assignable. This fixes an issue where an i8 was always generated for bit_sets with generic elements, because it couldn't figure out upper/lower when check_bit_set_type was run. Fixes #2860
2024-06-30 20:36:51 +02:00
Feoramund
8b915aae5e
Update code for new -vet
2024-06-30 11:18:40 -04:00
Feoramund
f0cf1052d0
Fix FreeBSD recvfrom
...
`fromlen` must be a pointer, not a value.
2024-06-30 10:17:32 -04:00
Jeroen van Rijn
4fbd22b668
Merge pull request #3840 from H0mTanks/master
...
Add missing enum member for WSAEWOULDBLOCK in TCP_Send_Error for windows.
2024-06-30 11:29:31 +02:00
h0mtanks
2b615b09f0
fixed whitespace
2024-06-30 13:47:11 +05:30
h0mtanks
d1603ebac4
added missing would_block enum member
2024-06-30 13:42:55 +05:30
flysand7
561b96b20d
[sys/windows]: Fix the value for TH32CS_SNAPPROCESS constant
2024-06-30 13:34:08 +11:00
gingerBill
afe24a0d4d
Merge pull request #3838 from flysand7/windows-tlhelp
...
[core/windows]: Bind tlhelp.h functions from kernel32.dll
2024-06-30 02:52:35 +01:00
flysand7
2737ccab3d
[core/windows]: Bind tlhelp.h functions from kernel32.dll
2024-06-30 12:35:42 +11:00
Feoramund
8ed5cb283b
Re-implement the error squiggles with visual width
2024-06-29 18:55:12 -04:00
Feoramund
8b305a4c67
Add UCG library to Odin compiler
2024-06-29 18:42:56 -04:00
gingerBill
80592f0f51
Add -disallow-do in CI
2024-06-29 22:50:23 +01:00
gingerBill
af3401631a
Remove the -disallow-do aspect from -strict-style
2024-06-29 22:48:43 +01:00
gingerBill
5637ed9ecd
Merge pull request #3836 from laytan/run-wasi-demo-in-ci
...
wasi: make the demo run on wasi and run it in CI
2024-06-29 22:30:31 +01:00
Laytan Laats
604551eb2d
wasi: make the demo run on wasi and run it in CI
2024-06-29 23:15:31 +02:00
Jeroen van Rijn
476d0087c8
Fix bug in div3 fast path.
2024-06-29 23:14:12 +02:00
gingerBill
34fce83d66
Improve -strict-style rules for if-else statements
2024-06-29 20:04:34 +01:00
gingerBill
b1a1da6618
Add -vet-tabs
2024-06-29 19:54:31 +01:00
gingerBill
e296d6fb90
Fix loads of indentation issues with mixing spaces and tabs
2024-06-29 19:50:51 +01:00
gingerBill
90244a0849
Fix accidental deletion in the -strict-style help comment
2024-06-29 19:41:45 +01:00
gingerBill
f4abdf716e
Move microarch stuff to a separate file
2024-06-29 19:29:20 +01:00
gingerBill
f64d1df90b
Add note regarding -strict-style
2024-06-29 19:27:26 +01:00
gingerBill
888bf28076
-strict-style implies -disallow-do
2024-06-29 19:26:11 +01:00
gingerBill
103eccf104
More style improvements
2024-06-29 19:23:58 +01:00
gingerBill
663661db53
Update core to -strict-style
2024-06-29 19:16:32 +01:00
gingerBill
835e8bf87a
Update -strict-style
2024-06-29 19:15:33 +01:00
gingerBill
2187f3e7ff
-strict-style enforce 1TBS (mostly)
2024-06-29 19:14:24 +01:00
gingerBill
5413a8b744
Even more style fixes
2024-06-29 19:11:36 +01:00
gingerBill
3f9a58808c
More style improvements
2024-06-29 19:07:34 +01:00
gingerBill
e8517e2694
-strict-style: enforce case to be in the same column as switch
2024-06-29 18:56:45 +01:00
gingerBill
96330996a6
Fix indentation
2024-06-29 18:51:39 +01:00
gingerBill
b0cbda4ee0
Fix indentation of tests
2024-06-29 18:51:28 +01:00
gingerBill
930c929294
Indentation fixes
2024-06-29 18:49:57 +01:00
gingerBill
7f05b4caf2
Fix generation for unicode entities
2024-06-29 18:43:09 +01:00
gingerBill
6db748b4a4
Remove debug message
2024-06-29 16:18:43 +01:00
gingerBill
a935ade0d2
Keep -sanitize:address happy with bit_field loads
2024-06-29 16:18:07 +01:00
gingerBill
ff2d042313
Remove unneeded transmute
2024-06-29 13:54:15 +01:00
gingerBill
913c08a33e
Add bit_field to demo.odin
2024-06-29 12:56:46 +01:00
gingerBill
c88a1bef91
Add another -vet-cast check
2024-06-29 12:40:04 +01:00
gingerBill
706adb1232
Update for transmute -vet-cast
2024-06-29 12:16:43 +01:00
gingerBill
b9861a0cf6
cast to transmute
2024-06-29 12:14:21 +01:00
gingerBill
e46d772b6d
Add check for integer casts
2024-06-29 12:13:41 +01:00
gingerBill
c18c0a3364
Adhere to -vet-cast
2024-06-29 12:07:21 +01:00
gingerBill
d6b8544f50
Add internal flag for testing stuff
2024-06-29 12:04:31 +01:00
gingerBill
4b71c47fd5
Check for unneeded transmute with -vet-cast
2024-06-29 12:02:31 +01:00
gingerBill
704530497b
Rename -vet-identical-cast to -vet-cast; with minor code clean up
2024-06-29 11:44:45 +01:00
gingerBill
4be0fc05bb
Merge pull request #3832 from Feoramund/vet-identical-cast
...
Add `-vet-identical-cast`
2024-06-29 11:37:35 +01:00
gingerBill
52aa7085e4
Use f32 as the immediate type for addition and subtraction for complex32/quaternion64
2024-06-29 11:09:54 +01:00
gingerBill
9113f389d8
Merge pull request #3831 from Feoramund/fix-darwin-test-runner-cancel
...
Let Darwin safely panic in a test
2024-06-29 11:01:01 +01:00
gingerBill
55e9b8d994
Use explicit calling conventions
2024-06-29 10:48:41 +01:00
gingerBill
ee2a0c4010
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-06-29 10:47:15 +01:00
gingerBill
f974002839
Use f32 operations rather than f16 in complex32 and quaternion64 to improve accuracy and performance
2024-06-29 10:47:09 +01:00
gingerBill
83b575aec2
Merge pull request #3833 from karl-zylinski/consistent-default-dynamic-array-capacity
...
Consistent dynamic array default capacity and avoid unnecessary dynamic array allocations
2024-06-29 10:38:22 +01:00
gingerBill
906afa4154
Allow for when x in y { (minor oversight in syntax)
2024-06-29 10:13:15 +01:00
Karl Zylinski
679f9b4e41
Made default capacity of dynamic arrays more consistent.
...
Before this if you do `arr: [dynamic]int` and then append to arr, then it will have capacity 8.
But if you did `arr := make([dynamic]int, context.temp_allocator)` then arr would have capacity 16.
Now both `arr: [dynamic]int` and `arr := make([dynamic]int, context.temp_allocator)` will resut in arr having zero 0. The only reason to use `make` without an explicit len or cap now is because you want to set it up for a non-default allocator. After the first call to `append` it will now in both cases have capacity 8.
I also updated the documentation on the strings builder, both to reflect this, and also to fix it incorrectly saying that len would be 'max(16,len)', which wasn't true even before these changes.
2024-06-29 08:57:21 +02:00
Feoramund
b3caae6db4
Keep -vet happy
2024-06-28 23:14:03 -04:00
Feoramund
6496432b80
Add -vet-identical-cast
2024-06-28 23:14:03 -04:00
Feoramund
0ea0fac2f9
Call pthread_cancel on Darwin, with advisory comment
2024-06-28 20:47:37 -04:00
Feoramund
13539d3be1
Catch SIGTRAP in the test runner
...
Fixes `panic` for Darwin.
2024-06-28 19:43:03 -04:00
Feoramund
929cc48703
Merge Darwin signals into other UNIX-likes
...
They're all the same.
2024-06-28 19:03:43 -04:00
Jeroen van Rijn
06652bebce
Merge pull request #3829 from Feoramund/fix-vetted-test-name
...
Let `-vet` be used with `-define:ODIN_TEST_NAMES`
2024-06-28 23:06:25 +02:00
Feoramund
574342af6f
Let -vet be used with -define:ODIN_TEST_NAMES
2024-06-28 15:58:22 -04:00
Laytan Laats
fa5be93da2
re-raise signals from the odin run binary
2024-06-28 19:33:34 +02:00
Jeroen van Rijn
007832488d
Merge pull request #3827 from Feoramund/require-runtime-linalg-import
...
Require `base:runtime` import in `core:math/linalg`
2024-06-28 17:44:10 +02:00
Feoramund
2af121752a
Require base:runtime import in core:math/linalg
2024-06-28 11:34:35 -04:00
gingerBill
0c8924ea85
Merge pull request #3822 from jasonKercher/os2-rebase
...
os2 linux round 2
2024-06-28 15:43:18 +01:00
jason
6a894195cb
revert os2/process
2024-06-28 09:45:22 -04:00
jason
dc954307d7
fix assumption about std handles in os2/file.odin
2024-06-28 07:55:33 -04:00
jason
a15cbc474d
change error strings to an enumerated array in rodata; print_error takes a file argument
2024-06-28 07:45:24 -04:00
gingerBill
37afd469c6
Merge pull request #3339 from axxeny/patch-1
...
fix comments in core:container/queue.
2024-06-28 12:00:34 +01:00
gingerBill
853173a11b
Merge pull request #3517 from timosperisen/patch-1
...
Update builder.odin
2024-06-28 12:00:23 +01:00
gingerBill
a1ae6f161b
Merge pull request #3502 from ARtemachka/master
...
Fix typo in core_builtin
2024-06-28 12:00:10 +01:00
gingerBill
883f6c129a
Merge pull request #3643 from korvahkh/fix-omitempty-comma
...
encoding/json: Fix struct marshal() emitting comma after omitted field
2024-06-28 11:50:31 +01:00
gingerBill
861d51b760
Merge pull request #3825 from Valakor/wgpu
...
wgpu_native fixes
2024-06-28 11:49:35 +01:00
gingerBill
17efb87eef
Add -custom-attribute
2024-06-28 11:44:39 +01:00
gingerBill
1747fdc3f0
Fix signature
2024-06-28 11:07:54 +01:00
gingerBill
bef3ca98f0
Fix signature
2024-06-28 11:01:57 +01:00
gingerBill
e15c5c4692
Fix missing import
2024-06-28 10:32:16 +01:00
gingerBill
9a4ffa79db
Add missing libraries to examples/all
2024-06-28 10:17:00 +01:00
gingerBill
ec38215842
Fix #3803
2024-06-28 10:09:46 +01:00
gingerBill
67e9a6fd9b
Improve error reporting on "Failed to parse fail" and show the line error if possible
2024-06-28 10:04:08 +01:00
gingerBill
4824050c99
Merge pull request #3792 from Feoramund/core-uuid
...
Add `core:encoding/uuid`
2024-06-28 09:49:23 +01:00
gingerBill
35651cfc17
Improve tokenization for false integer literals but not effect possible float literals
2024-06-28 09:24:34 +01:00
gingerBill
dde7cb6e7f
Improve error message for #3754
2024-06-28 09:21:33 +01:00
gingerBill
862a04376f
Improve tokenizing wrong number literals
2024-06-28 09:16:01 +01:00
gingerBill
5a9698e8cb
Properly fix #3820
2024-06-28 09:08:57 +01:00
gingerBill
0c8a81d298
Fix #3819
2024-06-28 08:57:31 +01:00
gingerBill
06ff08b9cf
Fix #3820
2024-06-28 08:53:05 +01:00
gingerBill
52ea63f89c
Fix #3471
2024-06-28 08:43:25 +01:00
gingerBill
f883cd5053
Initialize default context in heap_allocator_other.odin
2024-06-28 08:33:12 +01:00
Matthew Pohlmann
4bf9de7237
SupportedLimitsExtras.chain should be a ChainedStructOut to properly chain from SupportedLimits
2024-06-27 21:53:16 -07:00
Matthew Pohlmann
0a504c2647
Some fixes to wgpu_native.
...
1. LogCallback should have the "c" calling convention and takes a
userdata pointer like other callbacks.
2. DevicePoll's wrappedSubmissionIndex argument is an optional in/out
parameter. The previous wrapper method was broken since it passed a
non-nil structure to the underlying API with invalid members.
2024-06-27 21:41:48 -07:00
Jeroen van Rijn
d31f88bfaa
Merge pull request #3823 from laytan/enforce-global-foreign-import-variables
...
disallow non-global foreign import of variables on wasm
2024-06-28 02:11:50 +02:00
Laytan Laats
b79d7e6917
disallow non-global foreign import of variables on wasm
2024-06-28 01:34:09 +02:00
Jeroen van Rijn
ed7d34beb0
Avoid sporadic wasm crash
2024-06-28 00:39:51 +02:00
Jeroen van Rijn
aba274cf75
Merge pull request #3821 from Kelimion/clang_override
...
Allow `ODIN_CLANG_PATH=clang-path` overrides for link stage.
2024-06-27 23:36:39 +02:00
Jeroen van Rijn
140ee036ce
wasm error is no longer relevant
2024-06-27 23:29:36 +02:00
Jeroen van Rijn
58cd75350b
Allow ODIN_CLANG_PATH=clang-path overrides
...
Link using `clang`, unless overridden by `ODIN_CLANG_PATH` environment variable.
Fixes #3783
2024-06-27 23:21:58 +02:00
jason
f24f72c280
convert all to use sys/linux over sys/unix; new implementations for pipe, process and env
2024-06-27 17:14:48 -04:00
jason
f22754fc90
sys/linux: fix some syscalls and types; add more to Sig_Action and Sig_Info; Pid int->i32
2024-06-27 16:29:47 -04:00
Jeroen van Rijn
a0a48bfe34
Fix alignment.
2024-06-27 21:56:26 +02:00
Jeroen van Rijn
9f8b84c212
Merge pull request #3815 from laytan/tlsf-fixes
...
tlsf: destroy first pool & properly zero memory
2024-06-27 19:50:24 +02:00
Laytan Laats
1c199f52d6
tlsf: destroy first pool & properly zero memory
2024-06-27 19:27:07 +02:00
gingerBill
521182a100
Merge pull request #3813 from tadeohepperle/fix-vulkan-codegen-arrays-as-proc-args
...
Fix `vender:vulkan` codegen for procedures with fixed size arrays are arguments
2024-06-27 16:34:17 +01:00
Jeroen van Rijn
aa27cd4b0b
Allow core:odin to parse @(require) import
2024-06-27 16:14:16 +02:00
gingerBill
b1d06ea03f
Merge pull request #3808 from karl-zylinski/fix-append-elem-max-confusion
...
Replace `max(8, 1)` in _append_elem with just `8` and a comment.
2024-06-26 21:14:08 +01:00
Jeroen van Rijn
e37afa3ada
Merge pull request #3814 from Kelimion/fix_fixed
...
Fix core:math/fixed.
2024-06-26 20:46:46 +02:00
Tadeo hepperle
b834bd32f5
fix typo
2024-06-26 20:31:43 +02:00
Jeroen van Rijn
3726f0b73c
Merge pull request #3812 from Feoramund/add-table-decorations
...
Add `write_decorated_table` to `text/table`
2024-06-26 20:15:11 +02:00
Jeroen van Rijn
c33bf7673f
Fix core:math/fixed.
2024-06-26 20:12:55 +02:00
Tadeo hepperle
67e69f7196
Merge branch 'master' into fix-vulkan-codegen-arrays-as-proc-args
2024-06-26 19:31:00 +02:00
Tadeo hepperle
18dadd94e3
fix proc parsing
2024-06-26 19:30:21 +02:00
Feoramund
ba354e0524
Add documentation for write_decorated_table
2024-06-26 12:53:34 -04:00
Feoramund
f13d30ad23
Add write_decorated_table API
2024-06-26 12:50:43 -04:00
Feoramund
ba05c74936
Enable core:net tests for FreeBSD
2024-06-26 10:05:24 -04:00
Feoramund
e61d893a74
Port core:net to FreeBSD
2024-06-26 10:05:24 -04:00
Feoramund
10ce76fcc2
Fix FreeBSD futex implementation
...
- Add missing size of timeout struct to `_umtx_op`.
- Use `WAIT_UINT` not `WAIT`, as the expected value is an unsigned integer.
- Use new native calls instead of libc.
2024-06-26 10:02:07 -04:00
Feoramund
c61f5bbfe7
Add core:sys/freebsd
2024-06-26 10:02:06 -04:00
Jeroen van Rijn
8d1827838f
Merge pull request #3807 from karl-zylinski/ctprint
...
Added fmt.ctprint
2024-06-25 22:52:48 +02:00
Karl Zylinski
f227a40652
Replace max(8, 1) in _append_elem with just 8 and a comment.
2024-06-25 22:48:14 +02:00
Karl Zylinski
4e2d12c540
Added fmt.ctprint
2024-06-25 22:32:20 +02:00
Jeroen van Rijn
5d1d98cef3
Merge pull request #3806 from NicknEma/windows_fixes
...
Update CommandLineToArgvW return type
2024-06-25 12:22:27 +02:00
NicknEma
845613c404
Update CommandLineToArgvW return type
...
It now returns a multi-pointer so it can be iterated without any casting.
2024-06-25 12:10:17 +02:00
gingerBill
93441a043a
Make runtime.heap_alloc contextless
2024-06-25 09:38:49 +01:00
gingerBill
c098739484
Remove @(warning) and #warning(...)
2024-06-25 09:36:59 +01:00
Jeroen van Rijn
e42029c5ed
wgpu ld -> dl
2024-06-25 01:35:26 +02:00
Jeroen van Rijn
d97fe41834
Mark deux
2024-06-24 22:45:12 +02:00
Jeroen van Rijn
d3d73590d3
Fix CSV comments.
2024-06-24 22:43:14 +02:00
Jeroen van Rijn
185e39e53d
Merge pull request #3791 from Feoramund/fix-text-table-alignment
...
Refactor `core:text/table`
2024-06-24 21:59:33 +02:00
Feoramund
8b05ec1765
Add string caching example documentation
2024-06-24 15:11:43 -04:00
Feoramund
fbd609fa37
Add complete example showcasing Unicode support
2024-06-24 15:04:45 -04:00
Feoramund
f325a08e57
Make core:text/table examples more complete
...
They should be completely copy-and-paste friendly now, without the
assumption of someone using `using table`.
2024-06-24 15:04:45 -04:00
Feoramund
7a43404ea1
Add Width_Proc documentation
2024-06-24 15:04:45 -04:00
Feoramund
7da96c484d
Remove table.dirty
2024-06-24 14:28:05 -04:00
Feoramund
e397bdf11d
Let WIDTH_PROC be specified as proc argument to write_*_table
2024-06-24 13:38:59 -04:00
Feoramund
67b4cb0038
Crunch the ranges
2024-06-24 13:18:54 -04:00
Jeroen van Rijn
8eafd9eb82
wgpu import
2024-06-23 22:19:29 +02:00
Feoramund
ca58d7771b
Use new API from_nanoseconds in uuid
2024-06-22 18:36:42 -04:00
Feoramund
8a4a3ed66e
Change how Time is constructed in uuid
2024-06-22 18:21:32 -04:00
Feoramund
4481f9c695
Clarify some uuid legacy documentation
2024-06-22 18:21:32 -04:00
Feoramund
5a75cac5b9
Add API for creating custom version 8 UUIDs
2024-06-22 18:21:32 -04:00
Feoramund
e9b882be05
Add vendor-specific version 8 UUID generation (hashing)
2024-06-22 18:21:32 -04:00
Feoramund
859cbf7d72
Test if v1 and v6 UUID node is set correctly
2024-06-22 18:21:32 -04:00
Feoramund
d559feb701
Add uuid test for timestamps
2024-06-22 18:21:32 -04:00
Feoramund
f6344577d3
Add UUID sorting tests
2024-06-22 18:21:32 -04:00
Feoramund
339b2b23f6
Add unsafe_write to uuid package
2024-06-22 18:21:32 -04:00
Feoramund
8b8f8c7f7d
Address minor organizational issues
2024-06-22 18:21:32 -04:00
Feoramund
95a9c9b016
Fix indentation
2024-06-22 18:21:32 -04:00
Feoramund
9b3a104640
Add buffer-based to_string to uuid package
2024-06-22 18:21:32 -04:00
Feoramund
9b265b2309
Improve time-related API in uuid package
...
- Let timestamps be specified by the user.
- Change `time_v*` to `raw_time_v*` and implement an API that returns
timestamps from the `time` package.
2024-06-22 18:21:32 -04:00
Feoramund
ea771d0cb7
Update uuid package documentation
2024-06-22 18:21:31 -04:00
Feoramund
fcdba334ea
Require CSPRNG in UUID generation where applicable
2024-06-22 18:21:31 -04:00
Feoramund
3aa232a894
Move v3 and v5 UUID procs to uuid/legacy
2024-06-22 18:21:31 -04:00
Feoramund
9866b54d59
Add version 6 UUID generation
2024-06-22 18:21:31 -04:00
Feoramund
525bfca4ef
Add version 1 UUID generation
2024-06-22 18:21:31 -04:00
Feoramund
4cfbd83b10
Add version 7 UUID generation
2024-06-22 18:21:31 -04:00
Feoramund
fee81985b4
Make UUID namespaces @(rodata)
2024-06-22 18:21:31 -04:00
Feoramund
6da99b888a
Make UUID Identfier only a distinct byte array
2024-06-22 18:21:31 -04:00
Feoramund
31873ed466
Fix wrong comments
2024-06-22 18:21:31 -04:00
Feoramund
4dacddd85e
Add core:encoding/uuid
2024-06-22 18:21:27 -04:00
Jeroen van Rijn
3af9d31bd5
Add time.from_nanoseconds
2024-06-23 00:19:24 +02:00
Jeroen van Rijn
dae9a8dfff
Merge pull request #3796 from Feoramund/fix-lack-of-str-arg-or-cont
...
Fix print segfault by missing argument in `or_*` shadowed error
2024-06-22 17:57:02 +02:00
Feoramund
f58eded5d2
Fix print segfault by missing argument in or_* shadowed error
2024-06-22 11:45:43 -04:00
Jeroen van Rijn
13c58948f4
Merge pull request #3793 from Kelimion/build_test_only
...
Add `-build-mode:test`
2024-06-21 16:12:13 +02:00
Jeroen van Rijn
9f696a646f
Add -build-mode:test.
2024-06-21 16:02:55 +02:00
gingerBill
bad4a6237e
Delete misc/roadmap.md
2024-06-21 00:02:12 +01:00
Feoramund
bf44a94065
Update core:text/table documentation
2024-06-20 18:22:03 -04:00
Feoramund
82d92dc46c
Use log.error instead of eprintf
2024-06-20 17:53:45 -04:00
Feoramund
b81458073e
Add new API to core:text/table
...
- `header/row_of_values`, same `header/row`, more verbose name
- `aligned_header/row_of_values`, set alignment for an entire row
- `header/row_of_aligned_values`, set alignment per value
2024-06-20 17:53:45 -04:00
Feoramund
585747bbbf
Clarify error message
2024-06-20 17:53:34 -04:00
Feoramund
99c955d124
Remove unneeded loc argument
2024-06-20 15:26:00 -04:00
Feoramund
fd28199178
Optimize printing of markdown tables
...
Check only once if the table has a header row, instead of every row.
2024-06-20 15:01:09 -04:00
Feoramund
dd099d9dd6
Add Unicode support to core:text/table
2024-06-20 15:01:09 -04:00
Feoramund
2241ca8e72
Use tabs to indent HTML tables
2024-06-20 13:06:32 -04:00
Feoramund
b66b960e7e
Don't build HTML tables
...
`build` only recalculates length and width information, and this is not
needed for HTML tables.
2024-06-20 13:06:32 -04:00
Feoramund
4a3684c5e8
Rename write_ascii_table to write_plain_table
2024-06-20 13:06:28 -04:00
Jeroen van Rijn
91cc006e8f
Fix unaligned store for rand
2024-06-20 17:54:37 +02:00
Jeroen van Rijn
ac4577ca66
Merge pull request #3790 from Feoramund/optimize-common-rng-dest-size
...
Optimize default RNG for the common case
2024-06-20 17:41:13 +02:00
Feoramund
1dfc89567e
Optimize default RNG for the common case
2024-06-20 11:27:51 -04:00
gingerBill
28e33d86de
Merge pull request #3776 from IllusionMan1212/os2-read-fix
...
fix(os2): check for 0 bytes read and return EOF
2024-06-20 15:37:41 +01:00
gingerBill
dab3c832e0
Add #warning(<string>) builtin compile time procedure
2024-06-20 15:32:30 +01:00
Jeroen van Rijn
94a8c38d86
Add GetNumberOfConsoleInputEvents
2024-06-20 15:19:25 +02:00
gingerBill
8c760e140f
Move import to a windows specific file
2024-06-20 12:38:09 +01:00
gingerBill
3db7780a2c
Add vendor:wgpu to examples/all
2024-06-20 12:20:06 +01:00
gingerBill
8b446fc88d
Fix wgpu paths for Windows
2024-06-20 12:18:26 +01:00
gingerBill
c9884906d9
Add #directory
2024-06-20 12:15:55 +01:00
gingerBill
5dc98336a8
Merge pull request #3524 from Feoramund/freebsd-amd64-syscall-errno
...
Add `intrinsics.syscall_bsd`
2024-06-20 11:47:01 +01:00
gingerBill
23351ca8be
Merge pull request #3137 from laytan/show-defineable
...
Add flags to show/export defineable values and warn if a -define is unused in the project
2024-06-20 11:45:52 +01:00
gingerBill
56383e45a7
Fix #3768
2024-06-20 11:44:00 +01:00
gingerBill
7184792f7a
Merge pull request #3740 from laytan/wgpu
...
Add `vendor:wgpu`
2024-06-20 11:39:58 +01:00
gingerBill
d4aa6c3288
Merge pull request #3788 from Beefster09/builder-utils
...
Add to_cstring for Builders
2024-06-20 11:34:03 +01:00
gingerBill
7703bc595c
Merge pull request #3789 from Feoramund/unicode-annex-11
...
Measure `East_Asian_Width` during grapheme decoding
2024-06-20 11:32:06 +01:00
Feoramund
e620645a03
Measure East_Asian_Width during grapheme decoding
2024-06-19 22:35:36 -04:00
Justin Snyder
1a6bb59125
drop unnecessary defer
2024-06-19 18:25:42 -06:00
Justin Snyder
271782d2f4
fix typo
...
apparently i had a moment of dyslexia
2024-06-19 17:53:34 -06:00
Justin Snyder
1b7c4c2efe
trim added null byte
2024-06-19 17:35:16 -06:00
Jeroen van Rijn
4380934283
Merge pull request #3787 from jasonKercher/more-windows-comm
...
Add more bindings for comm ports and console events
2024-06-19 23:32:12 +02:00
Jeroen van Rijn
21806e5fa5
Merge pull request #3786 from fabiansperber/fix-d3d11-infoqueue
...
Fix d3d11 IInfoQueue_VTable & Add LoadLibraryExW
2024-06-19 23:26:40 +02:00
jason
93e67f6bec
make -strict-style happy
2024-06-19 17:15:09 -04:00
jason
6b1e76985c
move DCB to types.odin; add more bindings for comm functions
2024-06-19 17:04:18 -04:00
Fabian Sperber
0e9bf86123
Fix d3d11 IInfoQueue_VTable & Add LoadLibraryExW
...
- wrong order & was missing PushStorageFilter & PushRetrievalFilter
2024-06-19 22:22:26 +02:00
Justin Snyder
8f2c4a7ecf
Add builder to_cstring
2024-06-19 11:55:19 -06:00
jason
e6d84d18d3
Merge remote-tracking branch 'origin/master' into more-windows-comm
2024-06-19 12:33:13 -04:00
jason
a9b6d28291
save before merging from upstream
2024-06-19 12:33:05 -04:00
Jeroen van Rijn
2797dc6452
Merge pull request #3785 from mgavioli/new_i18n_API
...
Separate I18N calls for immutable and for pluraliseable strings. Fixes #3687
2024-06-19 11:50:24 +02:00
Jeroen van Rijn
322b7f1f2f
Spell check i18n.odin.
2024-06-19 11:41:58 +02:00
Jeroen van Rijn
e0de52efa1
Spell check doc.odin.
2024-06-19 11:15:17 +02:00
Maurizio M. Gavioli
53755824fb
Separate the I18N calls for immutable strings and for pluraliseable strings.
...
Also update tests.
2024-06-19 10:10:26 +02:00
Jeroen van Rijn
7064166da2
Merge pull request #3767 from Feoramund/use-rng-context-in-test-runner
...
Setup `context.random_generator` in test runner
2024-06-19 09:51:13 +02:00
Feoramund
d4803583ff
Work around Windows test failure
...
I am uncertain why this works, but it does. Previously, `rtti_test` was
failing due to non-zero data appearing in the `l_buggy` `Buggy_Struct`.
The issue was caused by calling `runtime.default_random_generator` with
a pointer to the state, somehow. The pointer could be on the stack or in
the heap; it did not matter.
I found two workarounds.
- One is to move the RNG setup behind the call to `free_all`.
- The other is to construct the random generator manually.
Despite my digging and testing, I could find no reason as to why this
works or what the fundamental issue was to begin with. If anyone comes
upon this in the future with direct access to a Windows machine, I
recommend stepping through the program with a debugger to investigate
more deeply into why this happens.
2024-06-18 23:21:04 -04:00
Jeroen van Rijn
dff8a9153e
Merge pull request #3781 from Feoramund/add-missing-test-imports
...
Add missing imports to `core` test suite
2024-06-18 18:20:02 +02:00
Feoramund
e3f4772d01
Fix removal of temporary file in core:flags test
2024-06-18 11:06:49 -04:00
IllusionMan1212
c987b964c8
fix(os2): check for 0 bytes read and return EOF
2024-06-18 17:03:54 +02:00
Feoramund
6b25d17ef9
Add missing imports to core test suite
2024-06-18 10:38:43 -04:00
gingerBill
3d9db56410
Minor formatting changes to unicode stuff
2024-06-18 12:53:56 +01:00
gingerBill
02cd53d42c
Merge pull request #3700 from Feoramund/core-flags
...
Add package `core:flags`
2024-06-18 12:48:57 +01:00
gingerBill
de23965ecb
Merge pull request #3775 from Feoramund/unicode-graphemes
...
Add grapheme analysis facilities to `core:unicode`
2024-06-18 12:48:31 +01:00
gingerBill
e8c17ac356
Merge pull request #3778 from Feoramund/fix-2824
...
Allow custom `main` when `-no-entry-point` is set
2024-06-18 12:46:33 +01:00
gingerBill
dc03e8380d
Merge pull request #3779 from karl-zylinski/clarify-usage-of-temp-allocator-arena
...
Clarify when the arena in base:runtime should be used
2024-06-18 12:45:43 +01:00
Jeroen van Rijn
aad7ddf2d1
Merge pull request #3780 from destroycomputers/fix/rbtree/key-ordering-constraint
...
Loosen constraint on the Key type in rb & avl tree
2024-06-18 13:42:36 +02:00
destroycomputers
de44dd5412
Loosen constraint on the Key type in rb & avl tree
...
The current constraint on the `init_ordered' function accepts only
numeric types. While one still can init a non-numerically-keyed tree by
passing a comparator explicitly, the reason to disallow non-numeric
ordered types is nowhere to be found.
2024-06-18 13:31:45 +02:00
Karl Zylinski
11e586494b
Clarify that the arena in base:runtime shouldn't be used for anything but the default temp allocator. This is done by renaming the file in which it lives, and also by improving the comment above Arena :: struct {. This should avoid some confusion where people end up using the Arena in base:runtime because they thought it was the 'default arena'.
2024-06-18 12:48:16 +02:00
Jeroen van Rijn
dd364c0c0f
Merge pull request #3777 from Feoramund/fix-3047
...
Forbid private test cases
2024-06-18 12:09:58 +02:00
Feoramund
0196cc46e3
Allow custom main when -no-entry-point is set
2024-06-18 01:49:55 -04:00
Feoramund
eb5a66c944
Forbid private test cases
2024-06-18 01:28:05 -04:00
Feoramund
9e4899d35c
Add tests for decode_grapheme_clusters
2024-06-17 21:57:32 -04:00
Feoramund
63973f431e
Make core:unicode letter procs @(require_results)
2024-06-17 21:57:32 -04:00
Feoramund
1620a69398
Add decode_grapheme_clusters to core:unicode/utf8
2024-06-17 21:57:32 -04:00
Feoramund
1a93dfd28f
Fix indentation
2024-06-17 13:24:47 -04:00
gingerBill
f280ba8511
Merge pull request #3756 from matias-eduardo/empty_structs_hash_fmt
...
Handle empty structs in hash (#v) fmt
2024-06-16 19:54:28 +01:00
Jeroen van Rijn
a66ce4f871
Merge pull request #3773 from Kelimion/res_path_bug
...
Fix `rc.exe` bug with double-quoted `.res` path.
2024-06-16 19:27:13 +02:00
Jeroen van Rijn
fe3baae7a6
Merge pull request #3772 from Feoramund/fix-constant-wrong-type-bitset
...
Fix `bit_set` construction crash on constant non-integer field
2024-06-16 19:15:50 +02:00
Jeroen van Rijn
eebc0dd026
Fix rc.exe bug with double-quoted .res path.
2024-06-16 19:11:54 +02:00
Feoramund
78a5a27212
Fix bit_set construction crash on constant non-integer field
2024-06-16 12:27:42 -04:00
Jeroen van Rijn
339bafe6ff
Merge pull request #3770 from skaman/fix-slice-unique
...
Fix `slice.unique` wrong result
2024-06-16 13:48:21 +02:00
Jeroen van Rijn
0268be1925
Add tests for slice.unique and slice.unique_proc
2024-06-16 13:41:25 +02:00
Sandro Cavazzoni
e41878a64f
Fix slice.unique wrong result
...
When you try to make this array unique `[]int{1, 2, 4, 4, 5}` you get
`[]int{1, 4, 5}` instead of `[]int{1, 2, 4, 5}`.
Our index `i` should be increased even with both indices `i` and `j`
have the same value
2024-06-16 11:36:20 +02:00
Feoramund
8b31cddaba
Keep -vet happy
2024-06-15 15:49:05 -04:00
Feoramund
aab5338134
Add tests for core:math/rand
2024-06-15 15:49:05 -04:00
Feoramund
1a52cf1f1c
Use test's random generator
...
This removes the `create` calls when a test was only setting up a
generator, and it replaces them with `reset` when run in a loop.
2024-06-15 15:49:05 -04:00
Feoramund
5dfd303fd1
Setup default context.random_generator for tests
2024-06-15 15:44:56 -04:00
gingerBill
a619ea3bcd
Merge pull request #3766 from Feoramund/fix-rng-state
...
Fix `default_random_generator_proc` not using state
2024-06-15 20:36:10 +01:00
Feoramund
53140dca15
Fix default_random_generator_proc not using state
2024-06-15 12:54:30 -04:00
Jeroen van Rijn
ed99e77433
Merge pull request #3765 from Feoramund/add-short-test-logs
...
Add `ODIN_TEST_SHORT_LOGS` define
2024-06-15 18:01:49 +02:00
gingerBill
bacb915ff8
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-06-15 16:24:07 +01:00
gingerBill
e41ad2bf16
to_random_generator -> random_generator
2024-06-15 16:24:01 +01:00
gingerBill
4c7469a264
Merge pull request #3764 from Feoramund/test-runner-fixes
...
Fix half-implemented features in the test runner
2024-06-15 16:19:58 +01:00
Feoramund
753516c392
Add ODIN_TEST_SHORT_LOGS define
...
Strips out the procedure, date, and time information, for when you just
need to know the file, line, and message.
2024-06-15 11:18:40 -04:00
Feoramund
f353adc7fb
Prefer log.error over fail_now in this case
2024-06-15 10:53:21 -04:00
Feoramund
bb823d5ba0
Make testing.fail_now divergent
...
This is in line with the old way it worked on Windows.
2024-06-15 10:53:21 -04:00
gingerBill
1c940e3968
Remove dead variable
2024-06-15 15:53:16 +01:00
gingerBill
c97ffbecbc
Fix rand in container tests
2024-06-15 15:50:35 +01:00
gingerBill
2380720fa2
Fix core:sync/chan for rand
2024-06-15 15:46:48 +01:00
Feoramund
784408358d
Call cleanups after test signal
2024-06-15 10:46:47 -04:00
gingerBill
149ecafdef
Remove the need for rand in core:math/big
2024-06-15 15:43:57 +01:00
gingerBill
7ec17ecf98
Update core:math/rand to use context.random_generator and remove rand.Rand
2024-06-15 15:33:24 +01:00
gingerBill
318d5e4a7e
Add Reset mode
2024-06-15 15:17:23 +01:00
gingerBill
eaec8a2bbf
Add runtime.default_random_generator
2024-06-15 15:08:49 +01:00
gingerBill
c2a01096c4
Remove unneeded reassignment of r
2024-06-15 14:49:09 +01:00
gingerBill
827cb24023
Add random_generator.odin
2024-06-15 14:47:37 +01:00
gingerBill
dc4ec8638c
Add runtime.Random_Generator interface
2024-06-15 14:45:57 +01:00
Jeroen van Rijn
94ec647923
Merge pull request #3750 from Kelimion/dcb_bitfield
...
Update kernel32 struct DCB.
2024-06-15 12:14:27 +02:00
Feoramund
51a013fcf1
Work around BSD lack of core:net support
2024-06-15 01:32:48 -04:00
Feoramund
f28c6c3bba
Keep -vet happy
2024-06-15 00:50:12 -04:00
Feoramund
53e2cdf7af
Add core:flags to examples/all
2024-06-15 00:28:47 -04:00
Feoramund
76575e834b
Raise error on spaced UNIX-style flag with no value
2024-06-15 00:24:59 -04:00
Feoramund
42a5a2cf17
Fix memory leak in core:flags validation
2024-06-15 00:01:33 -04:00
Feoramund
c3acdeb310
Add -- parsing to UNIX-style core:flags
...
This will allow a user to indicate all arguments after `--` are parsed
into the variadic array.
2024-06-14 23:59:01 -04:00
Feoramund
d4e2fa0377
Refactor show_error_on_line
...
This should adequately solve any issues with Unicode alignment by
sidestepping the issue entirely. With this change, we make use of the
built-in ANSI facilities of the terminal to underline the text.
If the terminal does not support underlining, there are still the
fallback bold markers at the start and end of error locations.
2024-06-14 18:28:47 -04:00
Feoramund
582154f20d
Remove unused code from tokenizer
2024-06-14 15:44:50 -04:00
Jeroen van Rijn
908a6ff2d4
Elide unnecessary condition
2024-06-14 21:34:05 +02:00
Jeroen van Rijn
09b3f5a7a7
Merge pull request #3757 from thetarnav/patch-2
...
Add `#no_bounds_check` to `slice.equal`
2024-06-14 21:27:21 +02:00
Jeroen van Rijn
fa4fbbe1ce
Merge pull request #3758 from jones-josh/master
...
Fix big.shrink not actually shrinking
2024-06-14 20:27:03 +02:00
Josh Jones
759139089f
Fix big.shrink not actually shrinking
2024-06-14 19:58:13 +02:00
Damian Tarnawski
8ba644dd79
Add #no_bounds_check to slice.equal
2024-06-14 19:45:54 +02:00
Feoramund
8626d38db1
Fix displaying emptiness when error is on first line
2024-06-14 13:02:54 -04:00
Jeroen van Rijn
b19bf5bbda
Merge pull request #3732 from FrancisTheCat/master
...
add missing functions to core:sys/windows
2024-06-14 17:57:23 +02:00
Feoramund
ca481dc52d
Fix displaying error on wrong line with token at EOL
...
Previously, this would get a token on text like "\n*\n" where `*`
is the token's position, and it would advance off that line.
2024-06-14 11:51:03 -04:00
Franz Höltermann
c3302615a3
Merge branch 'master' of https://github.com/FrancisTheCat/Odin
2024-06-14 17:43:09 +02:00
Franz Höltermann
3c3f0f90c2
Fixed WinEventFlags
2024-06-14 17:41:21 +02:00
FrancisTheCat
cd5fa8523f
Merge branch 'odin-lang:master' into master
2024-06-14 16:34:21 +02:00
Franz Höltermann
ec7b77fc0f
Improved win32 bindings according to Kelimions suggestions with enums and bitsets
2024-06-14 16:32:41 +02:00
Matias Fernandez
4baf101f15
Handle empty structs in fmt with hash
2024-06-14 05:36:23 -04:00
Jeroen van Rijn
ff4787070d
Revert "Merge pull request #3744 from Mango0x45/master"
...
This reverts commit 45044de0b7 , reversing
changes made to 20c17ba6f9 .
2024-06-14 00:06:55 +02:00
Jeroen van Rijn
54a3cfb540
Merge pull request #3753 from Feoramund/fix-silent-token-fail
...
Fix compiler silently returning if `parse_packages` fails
2024-06-13 19:33:02 +02:00
Feoramund
c560553c21
Fix compiler silently returning if parse_packages fails
2024-06-13 13:01:51 -04:00
Thomas la Cour
acce9acb6d
Merge remote-tracking branch 'upstream/master' into sys-windows-2
2024-06-13 18:31:53 +02:00
Jeroen van Rijn
45044de0b7
Merge pull request #3744 from Mango0x45/master
...
Pad ‘^~~~^’-style diagnostic ranges properly
2024-06-13 17:34:17 +02:00
Jeroen van Rijn
c9c7d3270d
Merge branch 'master' of https://github.com/Mango0x45/Odin into pr/3744
2024-06-13 17:27:00 +02:00
Thomas Voss
9f7ac1469f
Generate ranges of the correct length
2024-06-13 17:24:56 +02:00
Jeroen van Rijn
ca9d1f940d
Just change squiggle_extra type to i32.
2024-06-13 17:23:30 +02:00
Thomas Voss
9f190f3937
Generate ranges of the correct length
2024-06-13 17:00:13 +02:00
Thomas Voss
657c516360
Pad ‘^~~~^’-style diagnostic ranges properly
2024-06-13 16:23:34 +02:00
Jeroen van Rijn
20c17ba6f9
Merge pull request #3751 from Kelimion/custom_formatter
...
Add example of a custom formatter.
2024-06-13 11:42:38 +02:00
Jeroen van Rijn
3d4e23d741
Add example of a custom formatter.
2024-06-13 11:33:37 +02:00
Jeroen van Rijn
50564a301e
Update kernel32 struct DCB.
2024-06-13 10:22:44 +02:00
Jeroen van Rijn
f8f6f2dada
Merge pull request #3749 from Feoramund/fix-w
...
Improve support for `%w`
2024-06-13 10:07:48 +02:00
korvahkh
104ca2ce22
Merge branch 'odin-lang:master' into fix-omitempty-comma
2024-06-13 01:27:44 +00:00
Feoramund
abe5c2ca83
Add test for %w
2024-06-12 21:07:15 -04:00
Feoramund
0c9f487783
Fix and document %w verb for core:fmt
2024-06-12 20:35:50 -04:00
gingerBill
a67df07392
Merge pull request #3742 from karl-zylinski/fix-raymath-matrix-to-float
...
Make rl.MatrixToFloatV do same thing in Odin as in C
2024-06-12 23:15:48 +01:00
Jeroen van Rijn
05972eb26b
Merge pull request #3746 from jasonKercher/add-commtimeouts
...
add COMMTIMEOUTS, get/setCommTimeouts
2024-06-12 21:50:10 +02:00
gingerBill
4ccc473e97
Merge pull request #3745 from karl-zylinski/rlgl-add-missing-types
...
rlgl: Pull in raylib and expose missing types
2024-06-12 20:48:22 +01:00
gingerBill
90815452ca
Merge pull request #3747 from Feoramund/fix-3739
...
Fix #3739
2024-06-12 20:48:02 +01:00
jasonkercher
a804463a57
add COMMTIMEOUTS, get/setCommTimeouts
2024-06-12 15:31:59 -04:00
Feoramund
33270f14a4
Fix #3739
2024-06-12 15:31:43 -04:00
Karl Zylinski
c7ea4ec71c
rlgl: Pull in raylib and expose missing types, so it is the same as rlgl.h. This makes rlgl less stand-alone, but I left some notes in rlgl.odin how to easily make it stand-alone if one really wants to.
2024-06-12 21:13:12 +02:00
Karl Zylinski
d37b5a7b67
Make rl.MatrixToFloatV transpose the matrix before transmuting it to [16]f32, so it does the same thing as the raymath version implemented in C.
2024-06-12 19:54:14 +02:00
Feoramund
1128bd1d7f
Use syscall_bsd on NetBSD
2024-06-12 13:34:36 -04:00
Feoramund
20c32c807d
Fix info.init_os_version on FreeBSD
...
It's possible for the return string to be longer than 128 characters
these days, so I've increased it to 1024, same as the other BSDs.
SYSCTL was otherwise erring out due to lack of buffer space.
2024-06-12 13:10:19 -04:00
Feoramund
5b5402fb23
Add intrinsics.syscall_bsd
...
This is a BSD-style syscall that checks for a high Carry Flag as the
error state. If the CF is high, the boolean return value is false, and
if it is low (no errors) then the boolean return value is true.
2024-06-12 13:07:13 -04:00
Laytan Laats
108b8feb35
Add vendor:wgpu
2024-06-12 17:22:02 +02:00
Jeroen van Rijn
603581aa53
Merge pull request #3738 from Kelimion/xml_attr
...
Xml attr
2024-06-12 14:06:40 +02:00
gingerBill
c5f7788652
Check to see if matrices are exactly the same type
2024-06-12 12:54:57 +01:00
gingerBill
f57c03c170
Improve matrix type hinting rules a little
2024-06-12 12:40:29 +01:00
Jeroen van Rijn
2fe961cbcd
Fold XML attribute whitespace.
2024-06-12 13:30:00 +02:00
Jeroen van Rijn
ebadff555d
Update XML reader to normalize whitespace, part 1.
2024-06-12 12:52:48 +02:00
gingerBill
cb45aa58fd
Merge pull request #3731 from karl-zylinski/rlgl-subpackage
...
Move rlgl to vendor:raylib/rlgl
2024-06-12 11:51:16 +01:00
gingerBill
e87c5bca58
Merge pull request #3737 from karl-zylinski/raylib-shader-location-index-any-int
...
Made rl.SetShaderValue etc take a c.int like in original raylib
2024-06-11 21:45:40 +01:00
Jeroen van Rijn
0398388a59
Merge pull request #3729 from Feoramund/fix-3460
...
Fix #3460
2024-06-11 20:32:37 +02:00
Thomas la Cour
8403952fd2
win32gen
2024-06-11 18:30:41 +02:00
Thomas la Cour
32dcb3caef
windows bindings test
2024-06-11 18:19:29 +02:00
Thomas la Cour
465ac74020
more windows stuff
2024-06-11 18:19:16 +02:00
Karl Zylinski
1a22f82f94
Changed rl.SetShaderValue etc to take a c.int like in original raylib.h. You should be able to use other values than the ShaderLocationIndex enum, that enum is only for build in things in raylib. Added #any_int on those procs so you can pass both int and also a ShaderLocationIndex.
2024-06-11 18:03:20 +02:00
gingerBill
35a845b93f
Fix indentation
2024-06-11 13:12:41 +01:00
gingerBill
3ff8952813
Replace panic(fmt.tprintf( antipattern with fmt.panicf
2024-06-11 13:11:14 +01:00
gingerBill
56c5e93fd1
Merge pull request #3728 from Feoramund/mem-any-int
...
Use `#any_int` for `reserve_*` and `resize_*` procs
2024-06-11 12:52:50 +01:00
gingerBill
39b166edd3
Merge pull request #3733 from Feoramund/ci-freebsd
...
Add FreeBSD to the CI
2024-06-11 12:51:42 +01:00
gingerBill
eaf1d88287
Merge pull request #3734 from Feoramund/fix-3730
...
Fix #3730
2024-06-11 12:50:41 +01:00
gingerBill
1dc90103bd
Make verification ignorable with a define flag
2024-06-11 12:30:24 +01:00
gingerBill
0b02c67cdf
Minor clean up for backend
2024-06-11 12:19:52 +01:00
gingerBill
9b0e87544a
Unify LLVMVerifyFunction invocations into on place
2024-06-11 12:07:22 +01:00
Feoramund
61c630bbf8
Fix #3730
2024-06-11 05:23:43 -04:00
Feoramund
0e6bcd0dbb
Add FreeBSD to CI
2024-06-11 04:16:42 -04:00
Feoramund
fc88de12c2
Implement absolute_path_from_handle for FreeBSD
2024-06-11 04:16:42 -04:00
Feoramund
a3da796d54
Fix file_size on FreeBSD
...
It was using the generic UNIX `fstat` implemented in Odin, which is more
than what is needed here.
This also avoids the issue of needing a proper
`absolute_path_from_handle` implementation for it to work without error.
2024-06-11 03:55:41 -04:00
Feoramund
40e99ebb10
Fix file open O_* flags on FreeBSD
2024-06-11 03:55:41 -04:00
Feoramund
c68560c573
Use correct __error link name for FreeBSD
2024-06-11 03:55:41 -04:00
Feoramund
76292c8ed5
Forbid all BSDs from running core:net tests
...
`net` is not yet implemented on them.
2024-06-11 03:55:41 -04:00
Franz Höltermann
c6c00c706a
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-06-11 09:37:20 +02:00
Franz Höltermann
6454c6f087
Added some missing functions to core/sys/windows
2024-06-11 09:35:59 +02:00
Karl Zylinski
c9e732d141
rlgl.RLGL_VERSION -> rlgl.VERSION
2024-06-11 08:59:30 +02:00
Karl Zylinski
d2cd96c3c8
Made rlgl.odin work as a subpackage of raylib. So now you import vendor:raylib/rlgl. Instead of rl.rlBegin(rl.RL_TRIANGLES) you now type rlgl.Begin(rlgl.TRIANGLES).
2024-06-11 08:46:44 +02:00
Karl Zylinski
34af2bb8ad
Moved rlgl.odin to subpackage 'raylib/rlgl'
2024-06-11 08:34:45 +02:00
Feoramund
bd198aeada
Fix #3460
2024-06-10 23:37:54 -04:00
Feoramund
50464bdce3
Use #any_int for reserve_* and resize_* procs
...
Resolves #3088
2024-06-10 20:51:58 -04:00
gingerBill
f1779c85de
Fix #3727
2024-06-10 18:50:53 +01:00
gingerBill
903e254e36
Merge pull request #3725 from laytan/add-forced-shutdown-to-test-runner
...
add forced shutdown to new test runner
2024-06-10 15:08:09 +01:00
gingerBill
eef2aef021
Fix #3724
2024-06-10 15:07:45 +01:00
gingerBill
c1e81dc14d
Fix #3726
2024-06-10 15:05:24 +01:00
gingerBill
fa3cae2bb0
Add intrinsics.procedure_of
...
```odin
foo :: proc(x: $T) { fmt.println(x) }
bar :: intrinsics.procedure_of(foo(int(123))) // parameters are never ran at compile time, similar to `size_of`
bar(333) // prints 333
```
2024-06-10 15:02:34 +01:00
Laytan Laats
71929f737b
add forced shutdown to new test runner
...
Currently, a Ctrl+c starts a graceful shutdown of the tests and runner.
Sometimes tests get stuck and this would never complete.
This simply adds an extra step, if Ctrl+c is given for the second time,
just `os.exit` right away.
2024-06-10 15:35:23 +02:00
gingerBill
1945218f6d
Improve parsing for label: #reverse for and label: #partial switch
2024-06-10 14:18:33 +01:00
Jeroen van Rijn
bedeaa34d9
Merge pull request #3723 from Feoramund/use-final-march
...
Use `get_final_microarchitecture()` for `ODIN_MICROARCH_STRING`
2024-06-10 11:40:01 +02:00
Feoramund
71a812e7fe
Use get_final_microarchitecture() for ODIN_MICROARCH_STRING
2024-06-10 05:30:16 -04:00
Jeroen van Rijn
741ee00b64
Merge pull request #3721 from Feoramund/add-tuning-consts
...
Add compilation-related constants
2024-06-10 10:31:12 +02:00
Jeroen van Rijn
d3ae70264e
Merge pull request #3720 from Feoramund/fix-force-inline-err-typo
...
Fix typo in a `#force_inline` error message
2024-06-10 10:25:09 +02:00
Jeroen van Rijn
c8b376f07f
Merge pull request #3719 from Feoramund/fix-orbranch-error
...
Fix `or_or_<branch>` error message
2024-06-10 10:21:05 +02:00
Feoramund
ff7fcb6d38
Add compilation-related constants
...
`ODIN_VERSION_HASH` is the `git` SHA hash of the commit the Odin
compiler was built with.
`ODIN_MICROARCH_STRING` is the string passed to `-microarch` when
the program was built.
`ODIN_OPTIMIZATION_MODE` is an enum value of which optimization mode was
used to build the program.
2024-06-10 03:47:20 -04:00
Feoramund
45d1328a85
Fix typo in a #force_inline error message
2024-06-10 00:50:16 -04:00
Feoramund
8702bf00d5
Remove _ in Syntax_Error verbose message
2024-06-09 22:47:43 -04:00
Feoramund
9d28f2e18c
Fix or_or_<branch> error messages
2024-06-09 22:46:45 -04:00
Jeroen van Rijn
5985c6e3df
Merge pull request #3718 from Feoramund/add-missing-big-atoi-alias
...
Add missing `string_to_int` alias in `core:math/big`
2024-06-10 03:58:56 +02:00
Jeroen van Rijn
82e2d1916f
Merge pull request #3717 from Feoramund/big-combo
...
Add permutation & combination procs to `core:math/big`
2024-06-10 03:47:55 +02:00
Feoramund
70820c2c40
Add missing string_to_int alias in core:math/big
2024-06-09 21:42:31 -04:00
Feoramund
fe5c278fca
Add test for core:math/big permutation & combination procs
2024-06-09 20:42:09 -04:00
Feoramund
f0d65112b8
Rename math/big test package
...
This is in line with the other tests, and it does not seem to affect
building the library.
2024-06-09 20:42:07 -04:00
Feoramund
5fbd876db1
Add permutation & combination procedures to core:math/big
2024-06-09 20:42:04 -04:00
Jeroen van Rijn
4ea593bde0
Merge pull request #3716 from Feoramund/slice-permute
...
Add in-place permutation iterator to `core:slice`
2024-06-09 22:42:43 +02:00
Feoramund
047b505836
Add test for slice.permute
2024-06-09 16:15:43 -04:00
Feoramund
1f64d8d5bd
Add slice.permute
2024-06-09 16:15:41 -04:00
gingerBill
7c529e990d
Add -target:freestanding_arm32 (experimental)
2024-06-09 17:48:46 +01:00
gingerBill
828870004b
Change indentation
2024-06-09 17:15:08 +01:00
Jeroen van Rijn
7e60e21934
Merge pull request #3714 from Kelimion/png_cleanup
...
PNG cleanup
2024-06-09 18:09:17 +02:00
Jeroen van Rijn
5be7d8e32d
Clean up PNG code.
2024-06-09 17:59:59 +02:00
Jeroen van Rijn
fc2ba81be0
Merge branch 'master' into png_cleanup
2024-06-09 17:13:43 +02:00
gingerBill
edcbca51c3
Merge pull request #3684 from odin-lang/tlsf-allocator
...
`core:mem/tlsf` - "Two-Level Segregated Fit" memory allocator
2024-06-09 15:54:46 +01:00
Jeroen van Rijn
3c7e2659ac
Merge branch 'master' into tlsf-allocator
2024-06-09 16:42:23 +02:00
Jeroen van Rijn
6b88d0a820
Use new blend helper
2024-06-09 16:37:27 +02:00
Jeroen van Rijn
d2a2c1e74e
Image: Add improved blending method and test it.
2024-06-09 16:10:06 +02:00
gingerBill
ef7c6b9895
Re Fix #3713
2024-06-09 14:07:07 +01:00
gingerBill
c17981ac38
Add edge case to error_operand_no_value
2024-06-09 14:02:01 +01:00
gingerBill
4b52f7fe2b
Fix #3713
2024-06-09 13:35:22 +01:00
gingerBill
8fcfd8c506
Fix sign flag
2024-06-09 13:21:22 +01:00
gingerBill
e0d0dc704c
Make f32(u8) etc do an immediate cast to f32(u32(u8)) in code generation
2024-06-09 13:20:48 +01:00
Jeroen van Rijn
14f08ff02b
Merge pull request #3712 from laytan/fix-large-ints-amd64sysv-abi
...
fix large ints amd64 sysv abi
2024-06-09 11:01:31 +02:00
Jeroen van Rijn
5d5ef78de9
Merge pull request #3711 from laytan/fix-swizzle-crash
...
fix swizzle crash due to wrong alignment
2024-06-09 11:00:15 +02:00
Jeroen van Rijn
e595bdc805
Merge pull request #3710 from laytan/fix-unreachable-with-complex-param-or-return-inits
...
fix unreachable hit when param and/or return have complex inits
2024-06-09 10:59:26 +02:00
Laytan Laats
6d862cc4e5
fix unreachable hit when param and/or return have complex inits
...
Fixes #3630
2024-06-09 04:43:19 +02:00
Laytan Laats
3628154849
fix swizzle crash due to wrong alignment
...
Fixes #3691
2024-06-09 03:33:23 +02:00
Laytan Laats
9ad9236c3b
fix large ints amd64 sysv abi
...
Fixes #3707
2024-06-09 02:47:05 +02:00
Jeroen van Rijn
0d698c7b53
Merge pull request #3709 from Feoramund/stop-low-swizzle
...
Prevent panic when `swizzle` called with < 2 indices
2024-06-08 23:14:55 +02:00
Feoramund
49f147cc86
Prevent panic when swizzle called with < 2 indices
...
The requirement for at least 2 indices has been sourced from
`lb_addr_swizzle` in `llvm_backend_general.cpp`, where there is an
assert to ensure the swizzle_count is `1 < n <= 4`.
2024-06-08 17:05:00 -04:00
Jeroen van Rijn
e5bf6fd3aa
Merge pull request #3708 from Feoramund/ignore-bmp-assets
...
Add `*.bmp` to core tests `.gitignore`
2024-06-08 22:45:08 +02:00
Feoramund
5c8f78a25a
Add *.bmp to core tests .gitignore
2024-06-08 16:43:45 -04:00
Jeroen van Rijn
1f4cfd52fd
Merge pull request #3706 from leidegre/os_read_dir_windows
...
Fixed error handling in read_dir on Windows
2024-06-08 17:14:49 +02:00
gingerBill
be0774acc8
Add error message on return a constant slice value from a procedure
2024-06-08 16:07:28 +01:00
Jeroen van Rijn
de7d3e2487
Update dir_windows.odin
2024-06-08 17:00:38 +02:00
gingerBill
7e994b6d21
Remove empty line preventing a suggestion from happening
2024-06-08 15:42:19 +01:00
John Leidegren
35e57fdef8
Fixed error handling in read_dir on Windows
2024-06-08 15:58:34 +02:00
gingerBill
371749d474
Make certain procedures "contextless" for microui
2024-06-08 14:48:04 +01:00
Jeroen van Rijn
575e5a255b
Merge pull request #3704 from Feoramund/fix-fmt-p-verb
...
Fix `%p` pointers not printing leading `0x`
2024-06-07 23:00:29 +02:00
Jeroen van Rijn
323a6e0728
Nuke ancient comment.
2024-06-07 22:19:01 +02:00
Feoramund
affd48c791
Add #caller_location to check in fmt tests
...
This makes it much easier to track down which line failed.
2024-06-07 16:08:37 -04:00
Feoramund
b65589d036
Add %p tests for fmt
2024-06-07 16:07:11 -04:00
Feoramund
61c481bd81
Fix %p pointers not printing leading 0x
2024-06-07 15:27:43 -04:00
Jeroen van Rijn
96c06185dd
Merge pull request #3701 from laytan/fix-thread-deadlock
...
Fix thread deadlock
2024-06-07 20:39:40 +02:00
Laytan Laats
00dfff7ee0
core/thread: fix a deadlock situation on unix
2024-06-07 20:28:09 +02:00
Laytan Laats
b35e72c82b
core/sync: fix wrong timeout calculation, time.Duration is ns already
2024-06-07 20:27:33 +02:00
Feoramund
edb685f04b
Add package core:flags
2024-06-07 13:16:13 -04:00
Jeroen van Rijn
7c977bb859
Merge pull request #3699 from laytan/macos-14.5
...
add MacOS 14.5 to 'core:sys/info' and 'odin report'
2024-06-07 17:44:09 +02:00
Laytan Laats
072825ac5a
add MacOS 14.5 to 'core:sys/info' and 'odin report'
2024-06-07 17:42:41 +02:00
Jeroen van Rijn
4c45f7d3ae
Merge pull request #3698 from laytan/utilize-odin-test-instead-of-scrips-to-run-tests
...
Utilise `odin test` instead of scripts to run tests
2024-06-07 17:36:23 +02:00
Jeroen van Rijn
11137cfec5
Merge pull request #3697 from laytan/add-error-message-for-unknown-test-log-level
...
add error message for unknown test log level
2024-06-07 17:11:48 +02:00
Laytan Laats
e627fcb0e6
fix not printing Error: when terminal has no color support
2024-06-07 16:58:23 +02:00
Laytan Laats
29250f2657
fix regression in test_issue_2395
2024-06-07 16:33:38 +02:00
Laytan Laats
9122c20d4b
update actions/checkout
2024-06-07 15:57:09 +02:00
Laytan Laats
0a528777e8
utilize odin test -all-packages instead of (make/bat) scripts for running tests
2024-06-07 15:50:00 +02:00
Laytan Laats
f2be35f1f0
remove caught unused define
2024-06-07 15:22:14 +02:00
Laytan Laats
ee93d7c05e
add error message for unknown test log level
...
It would previously just be a compilation error about a missing
return statement.
2024-06-07 15:13:09 +02:00
Laytan Laats
315695b4f8
collect and show docs of defineables
2024-06-07 15:08:41 +02:00
gingerBill
68781f8dd3
Remove unnecessary Wait_Signal checks
2024-06-07 00:11:00 +01:00
gingerBill
1d99bc0f87
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-06-06 23:55:54 +01:00
gingerBill
7044a7d776
Try to fix a possible race condition with polymorphic record parameters
2024-06-06 23:55:48 +01:00
Jeroen van Rijn
4b6fe2baa7
Merge pull request #3696 from Kelimion/bmp_save
...
BMP save
2024-06-07 00:23:55 +02:00
Jeroen van Rijn
ed060819f3
Test roundtripping BMP
2024-06-07 00:14:15 +02:00
Jeroen van Rijn
566119ff83
Add saving of 24 and 32-bit images to BMP format.
2024-06-06 23:53:15 +02:00
gingerBill
08612423b9
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-06-06 21:03:44 +01:00
gingerBill
ff37a7435c
Add parentheses around the foreign import paths
2024-06-06 21:03:35 +01:00
Laytan Laats
fa08690686
explicit integer conversions
2024-06-06 19:49:51 +02:00
Laytan Laats
b818a77131
check if -define is actually used
2024-06-06 19:46:01 +02:00
Laytan Laats
9a95049393
-show-defineables and -export-defineables
2024-06-06 19:44:54 +02:00
Jeroen van Rijn
b196b84ef2
Merge pull request #3695 from laytan/fix-linking-on-weird-linuxes
...
fix linking on weird linuxes
2024-06-06 19:37:31 +02:00
Laytan
e2eb3cdd8a
fix linking on weird linuxes
2024-06-06 19:23:36 +02:00
gingerBill
d0dbe9a1bd
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-06-06 17:59:19 +01:00
gingerBill
039bb8794a
Improve matrix_align_of logic when it has invalid inputs.
2024-06-06 17:59:12 +01:00
gingerBill
f010544eff
Merge pull request #3609 from Kelimion/bmp
...
Add core:image/bmp
2024-06-06 16:29:35 +01:00
Jeroen van Rijn
4a290f47ad
Re-add BMP test suite download.
2024-06-06 16:55:03 +02:00
Jeroen van Rijn
678fdae966
Rebased.
2024-06-06 16:32:18 +02:00
gingerBill
3a9b86628a
Add @(rodata) and @(static, rodata) where appropriate
2024-06-06 15:23:52 +01:00
gingerBill
bea47db495
Allow @(rodata) on @(static) variables
2024-06-06 15:20:47 +01:00
gingerBill
9ef43fc782
Add @(rodata)
2024-06-06 15:16:34 +01:00
Jeroen van Rijn
28ea9425fd
Add core:mem tests.
2024-06-06 14:59:19 +02:00
Jeroen van Rijn
72f6b5479d
Fix fls_uint
2024-06-06 14:42:19 +02:00
Jeroen van Rijn
0b6d73c86e
Add original LICENSE
2024-06-06 14:29:28 +02:00
gingerBill
971229fe66
Fix #3686
2024-06-06 13:27:55 +01:00
gingerBill
c4ef8e7f6c
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-06-06 13:02:16 +01:00
gingerBill
155516b897
Fix -ignore-warnings
2024-06-06 13:02:08 +01:00
Jeroen van Rijn
9b66b0c8e6
Merge pull request #3694 from rope-hmg/master
...
Updated SDL_CreateTexture to take `PixelFormatEnum` instead of `u32`
2024-06-06 13:03:16 +02:00
Hector
483015fe57
Updated SDL_CreateTexture to take PixelFormatEnum instead of u32
2024-06-06 11:47:59 +01:00
gingerBill
a73741d3b7
Merge pull request #3690 from laytan/orcas
...
Runtime support for orca
2024-06-06 11:03:51 +01:00
Jeroen van Rijn
fb2849e02e
Merge pull request #3693 from colrdavidson/x11-title-change-support
...
Add support functions for title changes, cursor config, and dnd
2024-06-06 11:48:16 +02:00
Colin Davidson
70592630a4
add support for title changes, cursor config, and dnd
2024-06-06 02:39:48 -07:00
Jeroen van Rijn
fcfc1cb97f
Nightly ZIP level 9
2024-06-05 22:26:03 +02:00
Jeroen van Rijn
cdd90a9a0b
Merge pull request #3688 from Kelimion/nightly
...
Rewrite upload_b2 nightly action against B2 SDK
2024-06-05 21:11:25 +02:00
Jeroen van Rijn
460ffe1aee
Rewrite upload_b2 nightly action against B2 SDK
2024-06-05 21:04:35 +02:00
laytan
08382cb05d
orca windows
2024-06-05 19:28:40 +02:00
Laytan Laats
8455e159f5
improve orca target
2024-06-05 20:57:39 +02:00
gingerBill
76d3be7912
Merge pull request #3683 from andreas-jonsson/test-make-cleanup
...
Minor cleanup of makefiles and scripts
2024-06-05 15:44:27 +01:00
gingerBill
97f0f72080
Merge pull request #3685 from markersniffen/sniffen
...
D3D11.odin - fix VIDEO_SUPPORT flag
2024-06-05 15:43:55 +01:00
gingerBill
a667878d23
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-06-05 15:43:21 +01:00
gingerBill
cbabcb0907
Fix #3682
2024-06-05 15:43:15 +01:00
gingerBill
fac9ce5d83
Change to init from create
2024-06-05 15:30:35 +01:00
gingerBill
d3342c2381
core:mem/tlsf - "Two-Level Segregated Fit" memory allocator
2024-06-05 15:15:39 +01:00
Mark Sniffen
cd4375061c
D3D11 - fixed VIDEO_SUPPORT flag
2024-06-05 10:11:18 -04:00
Andreas T Jonsson
f0e98372fb
Minor cleanup of makefiles and scripts
2024-06-05 15:37:02 +02:00
gingerBill
a747e47582
Merge pull request #3675 from Feoramund/fix-partial-infinity
...
Fix partial parsing of `infinity`
2024-06-05 12:48:44 +01:00
gingerBill
adcda88501
Merge pull request #3680 from andreas-jonsson/netbsd-arm64
...
ARM64 support for NetBSD
2024-06-05 12:47:29 +01:00
gingerBill
e7190aab41
Merge pull request #3681 from andreas-jonsson/netbsd-lwp-self
...
Proper thread identification on NetBSD
2024-06-05 12:47:23 +01:00
Andreas T Jonsson
929437c7bc
Fixed broken import
2024-06-05 11:17:13 +02:00
Andreas T Jonsson
ed6667ebf2
Propper thread identification on NetBSD
2024-06-05 11:06:14 +02:00
Andreas T Jonsson
58f07698e8
Added arm64 support for NetBSD
2024-06-05 10:18:47 +02:00
Jeroen van Rijn
c406bbb6e3
Merge pull request #3679 from Feoramund/fix-typos
...
Fix some typos
2024-06-05 09:30:10 +02:00
Feoramund
b2f9f0af68
Fix some typos
2024-06-04 19:01:30 -04:00
Feoramund
25feff3eb4
Permit parsing of incomplete infinity but do not return true
...
To clarify, `parse_f64` will indeed take `infi` to mean `+Inf` and
return that as the value, but it will not return `ok = true`. It treats
it as `inf` followed by any other trailing character.
`parse_f64_prefix` is the lenient one which will return true so long as
it finds some meaningful value.
2024-06-04 18:55:13 -04:00
Feoramund
1fc6ff91b2
Add test for infinity with trailing characters
2024-06-04 18:55:13 -04:00
gingerBill
2c580aa6fb
Merge pull request #3676 from laytan/fix-passing-pointer-to-constant-to-non-odin-cc
...
fix passing pointer to constant in non-odin cc
2024-06-04 23:12:46 +01:00
Jeroen van Rijn
f0a6fb4057
Merge pull request #3678 from Feoramund/fix-p-f64-p-doc
...
Strike incorrect note from `parse_f64_prefix` doc
2024-06-05 00:02:34 +02:00
Jeroen van Rijn
448c0d8dd3
Merge pull request #3677 from Feoramund/parse-compquat
...
Add `parse_complex/quaternion*` to `core:strconv`
2024-06-04 23:58:43 +02:00
Feoramund
b4cfae222c
Strike incorrect note from parse_f64_prefix doc
2024-06-04 17:50:19 -04:00
Feoramund
265e6aa781
Add parse_complex/quaternion* to core:strconv
2024-06-04 17:12:55 -04:00
Jeroen van Rijn
9d234998c0
Update create_nightly_json
2024-06-04 22:44:49 +02:00
Jeroen van Rijn
c2ddf4266f
Update delete_old_binaries.py
2024-06-04 22:26:51 +02:00
gingerBill
a0b1b8d1c3
Merge pull request #3673 from laytan/implement-foreign-import-improvements-on-vendor
...
Implement `#exists(path)` and use it to provide good errors for common missing vendor libraries
2024-06-04 19:57:09 +01:00
Laytan Laats
dbaf1a1ce0
compile stb_vorbis
2024-06-04 20:26:21 +02:00
Feoramund
c656a9e4cd
Fix and subsume test_issue_2087 into strconv test suite
...
The full "infinity" strings were expected to be partial consumes, but
this is not the case. That has been fixed and the relevant extra tests
from that file have been added to this test suite.
Fixes #2670
2024-06-04 14:23:48 -04:00
Laytan Laats
cd99625dd3
ci: compile needed libraries
2024-06-04 20:21:52 +02:00
Feoramund
7d670f6562
Add initial test suite for core:strconv
2024-06-04 14:20:31 -04:00
laytan
2a526058b3
fix passing pointer to constant in non-odin cc
2024-06-04 20:15:47 +02:00
Laytan Laats
3e159736cd
use #exists to provide good errors for common missing libraries
2024-06-04 20:13:51 +02:00
Feoramund
d33668fa91
Fix partial parsing of "infinity" in parse_f64_prefix
...
It was previously reporting an invalid number of characters parsed for
any string other than "inf", "+inf", or "-inf".
2024-06-04 13:24:46 -04:00
Laytan Laats
b47a15733d
implement #exists(path)
2024-06-04 19:06:13 +02:00
Laytan Laats
4f5b2bd127
fix crash when you have 2 #load_directory calls with the same path
2024-06-04 19:01:50 +02:00
gingerBill
3b7100f8e5
raygui: change c.int to their correct enum types
2024-06-04 16:17:49 +01:00
gingerBill
6b386631dd
Improve error message suggestion for passing enums to integers
2024-06-04 16:16:27 +01:00
gingerBill
11b1a48bf0
Fix extra_linker_flags for raylib on windows
2024-06-04 15:54:57 +01:00
gingerBill
72ce111a95
Keep -vet happy
2024-06-04 15:51:19 +01:00
gingerBill
606608c02b
Utilize foreign import constant strings for foreign imports
2024-06-04 15:49:17 +01:00
gingerBill
eacf2918ad
Merge pull request #3469 from hodgka/raylib_resizable_doc_patch
...
Fixed typo in raylib documentation
2024-06-04 15:41:15 +01:00
gingerBill
afcccfdec5
Merge pull request #3615 from puzzleddev/export-dependencies
...
Add build flag to export dependencies.
2024-06-04 15:40:54 +01:00
gingerBill
60a064984d
Merge pull request #3670 from colrdavidson/x11-tweaks
...
Correct X11 prefix issues
2024-06-04 15:02:03 +01:00
gingerBill
0504c12f04
Merge pull request #3672 from laytan/fix-old-llvm-debug-info
...
fix debug info IR error on LLVM < 13
2024-06-04 15:01:30 +01:00
Laytan Laats
7d29389834
fix debug info IR error on LLVM < 13
2024-06-04 14:41:42 +02:00
Colin Davidson
52ba3357ee
oops, missed shuffling a few x-funcs
2024-06-04 04:48:24 -07:00
Jeroen van Rijn
78a67ef31e
Merge pull request #3667 from Feoramund/fix-fmt-compquat-sign
...
Fix printing of duplicate signs in complex and quaternion types
2024-06-04 13:32:13 +02:00
Jeroen van Rijn
f9d59ef6d4
Merge branch 'master' into fix-fmt-compquat-sign
2024-06-04 13:25:57 +02:00
Jeroen van Rijn
c3b94b9e1d
Merge pull request #3646 from Feoramund/multi-test
...
Refactor the test runner
2024-06-04 13:23:52 +02:00
Jeroen van Rijn
02f11dfded
Merge branch 'master' of github.com:odin-lang/Odin
2024-06-04 11:27:01 +02:00
Jeroen van Rijn
303d86ab7e
Complete nightly scripts update to new b2 cli version
2024-06-04 11:26:57 +02:00
Jeroen van Rijn
50374d9396
Merge pull request #3640 from harold-b/fix-darwin-libc-open
...
Fix open() foreign libc signature on Darwin
2024-06-04 10:54:08 +02:00
Jeroen van Rijn
dfffc57536
Merge pull request #3668 from colrdavidson/x11-tweaks
...
add a few more x11 funcs, fix egl bug
2024-06-04 10:53:57 +02:00
Colin Davidson
e46e22e21b
add a few more x11 funcs, fix egl bug
2024-06-04 01:12:10 -07:00
Feoramund
eb93779f63
Fix duplicate sign printing of complex and quaternion types
...
Negative zero wasn't being detected (so it would appear as `+-0`), and
`+Inf` was appearing as `++Inf` when imaginary.
2024-06-03 19:51:17 -04:00
Feoramund
d2a9122176
Add fmt tests for printing complex and quaternion types
2024-06-03 19:48:09 -04:00
Jeroen van Rijn
36627d7d29
Merge pull request #3666 from Feoramund/add-missing-compquat
...
Add missing `Raw_*` complex and quaternion types
2024-06-04 01:28:18 +02:00
Jeroen van Rijn
f745a1c470
b2 uri
2024-06-04 00:22:49 +02:00
gingerBill
17225131f7
Try / rather than
2024-06-03 23:12:24 +01:00
gingerBill
c8f9af64db
Add print to delete_old_binaries.py
2024-06-03 23:01:39 +01:00
gingerBill
0ef0894213
Fix to bl.tok = path
2024-06-03 22:55:24 +01:00
gingerBill
dc6a8e5ffb
Fix typo
2024-06-03 22:44:12 +01:00
gingerBill
5b5106baee
Try updating nightly stuff
2024-06-03 22:36:54 +01:00
gingerBill
4dac577caa
Add attributes to Foreign_Import_Decl in clone
2024-06-03 22:21:54 +01:00
gingerBill
8e9716ea2f
Add ast.Foreign_Import_Decl to ast.clone
2024-06-03 22:20:39 +01:00
Feoramund
d7f6def8ad
Add aliases for Raw_* complex/quaternion types into core:mem
2024-06-03 17:18:27 -04:00
gingerBill
50b4a63fe1
Add ast.Foreign_Impot_Decl.fullpaths to walk.odin
2024-06-03 22:02:35 +01:00
Jeroen van Rijn
2cb3028086
Merge pull request #3664 from reduf/fix-signatures-of-some-functions
...
Fix signatures of two Win32 functions
2024-06-03 22:06:07 +02:00
Feoramund
88598c2c64
Make use of runtime.Raw_* types in core:math/linalg
2024-06-03 15:58:33 -04:00
Feoramund
97f1d12e04
Add missing Raw_* types for complex and quaternion
2024-06-03 15:41:14 -04:00
Feoramund
4e1dd4ced2
Move Raw_Complex/Quaternion types to base:runtime
2024-06-03 15:40:28 -04:00
Laurent Dufresne
1617060f46
Fix type of two Win32 functions
2024-06-03 20:41:31 +02:00
Feoramund
0ff130d82b
Fix ad hoc printf in test runner signal handler
2024-06-02 23:36:04 -04:00
Feoramund
fa29974dab
Use Warning log level for reporting memory leaks
...
Works well with `-define:ODIN_TEST_LOG_LEVEL=warning`.
2024-06-02 23:21:44 -04:00
Feoramund
7764ab2ab0
Prevent test runner deadlock on NetBSD
...
Add `pthread_testcancel` to `core:sys/unix`
2024-06-02 21:27:36 -04:00
Feoramund
6a5633df2d
Fix wrong PTHREAD_CANCEL_ASYNCHRONOUS on FreeBSD and OpenBSD
...
The test runner was deadlocking when a test raised a signal on FreeBSD.
This is untested on OpenBSD, but I have referenced this file:
https://github.com/openbsd/src/blob/master/include/pthread.h
2024-06-02 20:41:25 -04:00
Feoramund
c8539fe411
Revert "Disable NetBSD tests until 'undefined reference to stdout' is solved."
...
This reverts commit 21a1ddfbae .
2024-06-02 19:29:27 -04:00
Feoramund
ac9484206b
Fix STDIN, STDOUT, STDERR handles for BSDs
...
Tested on FreeBSD 14.0 and NetBSD 10.0
OpenBSD is untested, but link names were sourced from:
https://github.com/openbsd/src/blob/master/include/stdio.h
According to this, OpenBSD shares the same layout as NetBSD.
FreeBSD has the same as Darwin in this regard.
2024-06-02 19:29:27 -04:00
Jeroen van Rijn
10d354aea8
Merge pull request #3662 from Feoramund/fix-3660
...
Fix #3660 and #3661
2024-06-02 23:22:16 +02:00
Feoramund
f030603f0d
Fix #3660
...
This also prevents a segfault if you do `odin build .odin -file`
2024-06-02 16:47:46 -04:00
Feoramund
f77ce359ce
Be pedantic about not overwriting Odin errors
...
I was encountering bounds-check error messages being overwritten during
a test, if the test failed for another reason and sent a log message.
The original intent of having this check inside of the above `if` block
was that if a test sent an error message, then it was assumed an
overwrite would be safe, but it's completely possible for a test to fail
for a legitimate reason, then do an unrelated bounds check somewhere
else that would be buried under the animation.
This change will make sure that, no matter what, the progress display
will not trigger a clear if a signal was raised. There's still no
guarantee that bounds-check messages will be printed properly, and it's
best to redirect STDERR.
The only way that can be fixed is if they get a similar hook to
`context.assertion_failure_proc`.
2024-06-02 15:51:26 -04:00
Feoramund
3f1249c27e
Tell user about ODIN_TEST_RANDOM_SEED option
2024-06-02 15:34:13 -04:00
Feoramund
8d8c42e962
Use T.seed in tests where applicable
2024-06-02 15:30:23 -04:00
Jeroen van Rijn
60d0c03134
Strip old test runner back out of internal, issues and vendor
2024-06-02 21:15:25 +02:00
Jeroen van Rijn
9d8d864400
Plug leak in AES tests.
2024-06-02 21:12:24 +02:00
Jeroen van Rijn
21a1ddfbae
Disable NetBSD tests until 'undefined reference to stdout' is solved.
2024-06-02 21:03:22 +02:00
Feoramund
890fe07c6e
Disable FANCY_OUTPUT in Odin test scripts
...
This should tidy up the CI output logs a bit.
2024-06-02 14:54:32 -04:00
Feoramund
d581dbbec5
Keep test runner main thread from using 100% of a CPU core
2024-06-02 14:54:32 -04:00
Feoramund
5e3e958574
Add -define:ODIN_TEST_LOG_LEVEL to set lowest log level
2024-06-02 14:54:32 -04:00
Feoramund
6a9203328b
Log thread count at test run start
...
Provides a helpful info message about the option to change how many
threads are used per run.
2024-06-02 14:54:32 -04:00
Feoramund
5db65aa796
Make it easier to learn about ODIN_TEST_CLIPBOARD
2024-06-02 14:54:32 -04:00
Feoramund
cb00b8022b
Add note about SIGSEGV edge case on UNIX-likes
2024-06-02 14:54:32 -04:00
Feoramund
4875f745c8
Remove Windows test runner in favor of libc implementation
2024-06-02 14:54:32 -04:00
Feoramund
ccdbd4b6ce
Simplify casts in mem.Rollback_Stack procs
2024-06-02 14:54:32 -04:00
Feoramund
9dcf345795
Set thread pool is_running to false on shutdown
2024-06-02 14:54:32 -04:00
Feoramund
21064fbb60
Clear thread pool task data on restart
2024-06-02 14:54:32 -04:00
Feoramund
45fa9d8148
Expand documentation comment for ODIN_TEST_NAMES
2024-06-02 14:54:32 -04:00
Feoramund
cb8faf5b74
Remove -test-name in favor of test runner option
...
`-define:ODIN_TEST_NAMES=...` is capable of selecting test by package
and name or name only, with the ability to access packages included by
`-all-packages`.
2024-06-02 14:54:32 -04:00
Feoramund
6a5d51f0d6
Use more concise way of satisfying -vet
2024-06-02 14:54:31 -04:00
Feoramund
433ca538bf
Be specific about platforms not implementing test runner signal handler
2024-06-02 14:54:31 -04:00
Feoramund
d1723664a7
Catch SIGILL, SIGFPE, SIGSEGV in the test runner
2024-06-02 14:54:31 -04:00
Feoramund
fb37572c4c
Rename signal_handler.odin to signal_handler_libc.odin
2024-06-02 14:54:31 -04:00
Jeroen van Rijn
6050bc3bf6
Add missing benchmarks build.bat.
2024-06-02 14:54:31 -04:00
Jeroen van Rijn
306169699c
Update ci.yml
2024-06-02 14:54:31 -04:00
Jeroen van Rijn
3354212f8e
Update ci.yml
...
Disable benchmark on Windows for a moment.
2024-06-02 14:54:31 -04:00
Jeroen van Rijn
54dae06ad1
Update CI
2024-06-02 14:54:31 -04:00
Jeroen van Rijn
8d93379e29
Factor benchmarks out into tests\benchmark\<pkg>
2024-06-02 14:54:29 -04:00
Jeroen van Rijn
62b7d8de97
Port tests\core\net
2024-06-02 14:47:09 -04:00
Jeroen van Rijn
dacb0f7786
Port tests\core\thread
2024-06-02 14:47:09 -04:00
Jeroen van Rijn
5b1ffba915
Port testing\core\time
2024-06-02 14:47:09 -04:00
Jeroen van Rijn
a406ff7063
Port tests\core\strings
2024-06-02 14:47:09 -04:00
Jeroen van Rijn
9ba02e888d
Port tests\core\slice
2024-06-02 14:47:09 -04:00
Jeroen van Rijn
ed0384c102
Port tests\core\runtime
2024-06-02 14:47:09 -04:00
Jeroen van Rijn
80b115748f
Port tests\core\reflect
2024-06-02 14:47:09 -04:00
Jeroen van Rijn
9829a02571
Port tests\core\odin
2024-06-02 14:47:09 -04:00
Jeroen van Rijn
8383a45b62
Port tests\core\text\match
2024-06-02 14:47:09 -04:00
Jeroen van Rijn
b0faab29e0
Port tests\core\math, math\linalg\glsl and math\noise
2024-06-02 14:47:09 -04:00
Jeroen van Rijn
d7bfbe0552
Port testing\core\text\i18n
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
39fd73fe17
Port testing\core\hash
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
6f7c5a7577
Port tests\core\fmt
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
d334b8c72a
Port tests\core\path\filepath
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
9d0f4833bf
Port tests\core\encoding\xml
...
Made them run in parallel as well.
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
6641a6f6c9
Port tests\core\encoding\varint
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
601df0e8f7
Port tests\core\encoding\json
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
1b32e27aa4
Port tests\core\encoding\hxa
...
And fix a few leaks in `core:encoding/hxa` while at it.
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
3404dea8ac
Port tests\encoding\hex
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
40b20fb473
Port tests\core\c\libc
2024-06-02 14:47:08 -04:00
Feoramund
b74b956fda
Remove unneeded import
2024-06-02 14:47:08 -04:00
Feoramund
1f6a6f2cd3
Support deterministic random seeding of tests
...
Add a new option `ODIN_TEST_RANDOM_SEED` which is picked from the cycle
counter at startup, if it's not specified by the user.
This number is sent to every test in the `T` struct and reset every test
(just in case).
2024-06-02 14:47:07 -04:00
Jeroen van Rijn
a27b167218
Update tests\core\encoding\cbor to use new test runner.
...
It was leaky and required a substantial number of `loc := #caller_location` additions to parts of the core library to make it easier to track down how and where it leaked.
The tests now run fine multi-threaded.
2024-06-02 14:47:07 -04:00
Jeroen van Rijn
6a1649d8aa
Update using new defaults for memory + reporting width
2024-06-02 14:47:07 -04:00
Feoramund
84ad71fdb3
Support ODIN_TEST_PROGRESS_WIDTH=0
...
This will automatically calculate how wide the progress bars should be
based on the package with the greatest number of tests.
The progress width is now capped to 100.
2024-06-02 14:47:07 -04:00
Feoramund
49fa66370f
Report test memory usage only if there's an issue
...
Adds new option `ODIN_TEST_ALWAYS_REPORT_MEMORY`, for when you always
want to see the memory usage report.
2024-06-02 14:47:07 -04:00
Feoramund
e1a3c0e21d
Track memory in the test runner by default
2024-06-02 14:47:07 -04:00
Feoramund
bf42e39b1c
Be specific about int size for Rollback_Stack asserts
...
This should fix tests failing on 32-bit platforms.
2024-06-02 14:47:07 -04:00
Jeroen van Rijn
c531427ee5
Update -define for crypto
2024-06-02 14:47:07 -04:00
Feoramund
b7e1ae7073
Change test runner options to SCREAMING_SNAKE_CASE
...
This commit also changes the name of `test_select` to `ODIN_TEST_NAMES`,
to better conform with the already-existing `-test-name:<name>` option.
2024-06-02 14:47:07 -04:00
Feoramund
e11f3d2520
Fix missing - for define in tests/core/build.bat
2024-06-02 14:47:07 -04:00
Feoramund
dcfda195d2
Send terminal control code to STDOUT instead
...
`STDERR` might be redirected, and this code signals to the terminal to
show the cursor again. Otherwise, the cursor will be invisible.
2024-06-02 14:47:07 -04:00
Feoramund
a1c5bebac7
Fix ANSI redraw eating last log line
2024-06-02 14:47:07 -04:00
Feoramund
89d8df28be
Combine multi-line attributes onto one line
2024-06-02 14:47:07 -04:00
Feoramund
dffc3af86c
Remove safe_heap_allocator from test runner
...
I was under the impression that the default `context.allocator` was not
thread-safe, but I've been told that this is not the case.
2024-06-02 14:47:06 -04:00
Feoramund
eadfbb1318
Forbid singleton allocations from shrinking their block offset
2024-06-02 14:47:06 -04:00
Feoramund
1afc235359
Use plain sort for internal_tests
2024-06-02 14:47:06 -04:00
Feoramund
09ef08f035
Add more sanity checking to mem.Rollback_Stack
2024-06-02 14:47:06 -04:00
Feoramund
0f675fa436
Use uintptr where applicable in mem.Rollback_Stack
2024-06-02 14:47:06 -04:00
Feoramund
568b746c98
Fix indentation
2024-06-02 14:47:06 -04:00
Jeroen van Rijn
a0b2ea6d6e
Update tests\core\crypto
2024-06-02 14:46:59 -04:00
Jeroen van Rijn
a463e282db
Update core:container tests
2024-06-02 14:34:31 -04:00
Jeroen van Rijn
e3181c13c6
Update core:compress tests
2024-06-02 14:34:31 -04:00
Jeroen van Rijn
22c092f846
Delete duplicated flag.
2024-06-02 14:34:31 -04:00
Jeroen van Rijn
eb3d6d7d75
Update core:image tests to use new runner.
2024-06-02 14:34:31 -04:00
Feoramund
852f694bee
Get tests passing again
...
`T` no longer has a writer assigned to it.
`test_core_cbor.odin` has global state and is run with `odin test`,
so I've set it to use only one thread.
2024-06-02 14:34:31 -04:00
Feoramund
87ea4a2652
Temporarily disable Windows-specific test runner
...
I do not have a Windows machine to test the refactored test runner, and
I am unsure if it would even run correctly on Windows without this
disabled.
2024-06-02 14:34:31 -04:00
Feoramund
d03024088a
Remove unneeded code
2024-06-02 14:34:31 -04:00
Feoramund
b6c4dfb68d
Refactor the test runner
...
Changes
- Support multi-threaded testing.
- Support `set_fail_timeout` on all platforms.
- Display an animated progress report.
- Setup all tests with a context logger.
- Give all tests their own separate custom allocators.
- Support tracking test memory usage.
- Display a summary of the failed tests at the end.
- Let users select only specific tests to run.
- Support copying failed tests to the clipboard to run again.
- Support catching SIGINT (CTRL-C) to cancel early.
- Record context in cleanup procs.
- Write all log messages to STDERR for easy redirection.
- Possibly more I've forgotten.
New Options
- `-define:test_threads=N`: Specify thread count.
- `-define:test_thread_memory=B`: Specify initial memory block size in bytes to each thread.
- `-define:test_track_memory=true`: Track the memory usage of individual tests.
- `-define:test_fancy=false`: Disable animated progress report.
- `-define:test_select=package.test_name,...`: Run only select tests.
- `-define:test_clipboard=true`: Copy names of failed tests to the clipboard.
- `-define:test_progress_width=24`: Change the width of the animated progress bars.
2024-06-02 14:34:31 -04:00
Feoramund
95c2e020ff
Share libc signal definitions with more platforms
...
I confirmed that these 3 platforms share the same signal definitions
from these sources.
Haiku: https://github.com/haiku/haiku/blob/master/headers/posix/signal.h
OpenBSD: https://github.com/openbsd/src/blob/master/sys/sys/signal.h
NetBSD: http://fxr.watson.org/fxr/source/sys/signal.h?v=NETBSD
2024-06-02 14:34:30 -04:00
Feoramund
50dffaf131
Add mem.Rollback_Stack
2024-06-02 14:34:30 -04:00
Feoramund
fc4f6b87bb
Add core:encoding/ansi package
2024-06-02 14:34:30 -04:00
Feoramund
8137b9dd75
Add mem.tracking_allocator_reset
2024-06-02 14:34:30 -04:00
Feoramund
558c330028
Add task-stopping functionality to thread.Pool
2024-06-02 14:34:30 -04:00
Feoramund
1875e7c36a
Make log.do_*_header argument orders consistent
2024-06-02 14:34:30 -04:00
Feoramund
7d4da6eaa7
Fix trailing space with only .Date log option
2024-06-02 14:34:30 -04:00
Feoramund
8ae375dbff
Move log timestamping out to do_time_header proc
2024-06-02 14:34:30 -04:00
Jeroen van Rijn
c07a46abc9
Merge pull request #3635 from Yawning/feature/aes
...
core/crypto: Add AES
2024-06-01 21:42:59 +02:00
Yawning Angel
c751e4b2eb
core/crypto/aes: Add AES implementation
2024-06-01 22:55:42 +09:00
Yawning Angel
1ade62b630
core/crypto/_aes/ct64: Add GHASH
2024-06-01 22:55:42 +09:00
Yawning Angel
cba58924a8
core/crypto/_aes: 64-bit portable implementation
2024-06-01 22:55:42 +09:00
Yawning Angel
f49575f1fb
core/simd/x86: Add the AES-NI intrinsics
2024-06-01 22:55:42 +09:00
gingerBill
72a5e74ef3
Merge pull request #3658 from laytan/wasm64p32-runtime-fixes
...
wasm: fix runtime.js even more for wasm64p32
2024-05-31 23:17:52 +01:00
gingerBill
881340fd3b
Merge pull request #3659 from thetarnav/unreachable
...
Add unreachable to base/builtin/builtin.odin
2024-05-31 23:17:08 +01:00
Damian Tarnawski
451dc645df
Add unreachable to base/builtin/builtin.odin
2024-05-31 21:55:40 +02:00
Laytan Laats
8a521648b9
wasm: fix runtime.js even more for wasm64p32
...
- make the int size configurable in the `runWasm` call, no more
constants to hunt down and change
- make storeU64 and storeI64 handle bigints, this is needed in the
odin_dom library
- fix alignment issues within init_event_raw
2024-05-31 20:57:15 +02:00
gingerBill
5628cfabe5
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-05-31 16:35:38 +01:00
gingerBill
31a9b3f428
core:encoding/ini
2024-05-31 16:35:30 +01:00
Jeroen van Rijn
e12ff63b16
Merge pull request #3657 from laytan/fix-wasm64p32-procs
...
wasm: fix target wasm64p32 runtime procs
2024-05-31 17:03:52 +02:00
Laytan Laats
3a0ec3d6a8
wasm: fix target wasm64p32 runtime procs
...
LLVM generates calls with `i32` regardless of target, so if a call to
any of these procs was generated this failed to compile.
I opted to fix by changing from `int` to `i32` on wasm64p32 and adding
`#any_int` so existing code keeps working.
2024-05-31 16:32:27 +02:00
gingerBill
ffded3d557
Merge pull request #3655 from iErik/master
...
core:sys/linux - Add support for Unix Domain Socket addresses
2024-05-31 10:32:19 +01:00
gingerBill
ae63fd9230
Fix #3649
2024-05-30 23:08:42 +01:00
gingerBill
6d9957d7e4
Fix types again
2024-05-30 21:59:01 +01:00
gingerBill
e737122ce8
Add experimental target orca_wasm32
2024-05-30 21:58:27 +01:00
gingerBill
8db87170a9
Clean up handle_link_name handling of link_suffix
2024-05-30 21:53:23 +01:00
gingerBill
ba1e9c8abe
Fix #3651
2024-05-30 21:50:30 +01:00
gingerBill
66acbb7fed
Add @(link_suffix=<string>)
2024-05-30 21:48:23 +01:00
Erik Isidore
0514ee0410
PR#3655 - small linter issue correction
2024-05-30 16:12:20 -03:00
gingerBill
7bcf33c881
Merge pull request #3656 from laytan/microui-optional-clipboard
...
microui: make clipboard optional during init
2024-05-30 17:37:35 +01:00
Laytan Laats
6bbe7d88b8
microui: make clipboard optional during init
...
Clipboard is an optional addition to the microui functionality, but the
init function makes it look like it is required. Additionally, a bunch of
the examples both on the Odin-Lang/examples repo and others are now
"broken".
2024-05-30 16:19:33 +02:00
gingerBill
7058d6f320
Merge pull request #3652 from Dudejoe870/compile-time-hash
...
Add #hash built-in directive for compile-time string hashing
2024-05-30 11:30:26 +01:00
gingerBill
f86bb11f84
Merge pull request #3653 from laytan/fix-wheel-event-js-wsam
...
wasm: fix the WheelEvent not storing data properly
2024-05-30 11:13:44 +01:00
gingerBill
5391605961
Merge pull request #3654 from laytan/darwin-fix-sdkpath
...
darwin: fix sysroot retrieval for some systems
2024-05-30 11:13:32 +01:00
Erik Isidore
f6e699cd22
core:sys/linux - Add support for Unix Domain Socket addresses
2024-05-30 00:14:00 -03:00
Laytan Laats
eeb057b76d
darwin: fix sysroot retrieval for some systems
...
Got a report on Discord that the current way didn't work for a user,
this change did work and I confirmed with @harold-b (who initially added
this) that it also works for them and is actually a better way.
2024-05-30 01:53:38 +02:00
Laytan Laats
692ca13ffd
wasm: fix the WheelEvent not storing data properly
...
A `WheelEvent` is also an instanceof `MouseEvent` so it was never
hitting the if statement for the `WheelEvent`.
2024-05-30 01:49:30 +02:00
Dudejoe870
9b78061c8f
Initial hash directive implementation
2024-05-28 22:42:10 -05:00
gingerBill
ba8672ad29
Merge pull request #3650 from yay/destroy-multi-logger-no-pointer
...
Take logger itself, not a pointer to logger in multi-logger destructor.
2024-05-29 00:49:02 +01:00
Vitalii Kravchenko
223c987db2
Take logger itself, not a pointer to logger in multi-logger destructor.
2024-05-28 21:13:25 +01:00
gingerBill
74524b6050
Merge pull request #3644 from odin-lang/foreign-import-improvements
...
Allow `foreign import` import paths to be evaluated in the semantic phase rather than parsing
2024-05-28 12:18:15 +01:00
Jeroen van Rijn
23852c16be
Merge pull request #3647 from Feoramund/fix-core-data-comments
...
Make `ODIN_OS`, `ODIN_BUILD_MODE` comments congruent to underlying data
2024-05-28 09:14:44 +02:00
Jeroen van Rijn
4c6b824658
Merge pull request #3648 from Feoramund/rem-unused-prime-code
...
Remove unused code in `internal_random_prime`
2024-05-28 08:55:04 +02:00
Feoramund
01ad69413a
Remove unused code in internal_random_prime
2024-05-28 01:36:44 -04:00
Feoramund
fa6e07d976
Make ODIN_OS, ODIN_BUILD_MODE comments congruent to underlying data
...
Sourced from `src/checker.cpp`.
2024-05-28 01:32:20 -04:00
gingerBill
d91054b615
Change parser to use ^Expr rather than string for the foreign import paths
2024-05-28 00:27:13 +01:00
gingerBill
a1b8749e74
Delay checking foreign import paths until after global scope is checked
2024-05-28 00:23:23 +01:00
gingerBill
38fffff06a
Begin moving foreign import import paths to be evaluated in the semantic phase rather than parsing.
2024-05-27 23:51:43 +01:00
korvahkh
a7a6ff8c69
encoding/json: Fix struct marshal() emitting comma after omitted field
...
Previously:
```odin
package main
import "core:fmt"
import "core:encoding/json"
T :: struct {
a: string `json:",omitempty"`,
b: string,
}
main :: proc() {
data, _ := json.marshal(T{b = "foo"})
fmt.println(string(data))
}
```
would output:
```
{,"b":"foo"}
```
which is not correct.
Also cleaned up some whitespace while I'm at it.
2024-05-27 16:59:46 -05:00
gingerBill
74ac2667e7
Merge pull request #3642 from 2nafish117/fix-pitch-from-quat
...
Fix pitch_from_quaternion
2024-05-27 22:24:46 +01:00
shashank
fb6248925a
fix pitch_from_quaternion
2024-05-27 23:38:50 +05:30
Harold Brenes
2ecf909be0
Fix open() foreign libc signature on Darwin
2024-05-27 11:55:58 -04:00
Jeroen van Rijn
75f1215ed2
Merge pull request #3639 from yay/destroy-file-logger-no-pointer
...
Make destroy_file_logger take logger instead of logger pointer.
2024-05-27 17:25:59 +02:00
Vitalii Kravchenko
bdc4daca54
Make destroy_file_logger take logger instead of logger pointer.
2024-05-27 16:19:44 +01:00
gingerBill
6d163cee8a
Merge pull request #3638 from harold-b/fix-darwin-libc-proc-sigs
...
Fix a few darwin libc signatures with incorrect parameters.
2024-05-27 02:06:50 +01:00
Harold Brenes
cfd4fc835b
Fix a few darwin libc signatures with incorrect parameters.
2024-05-26 19:40:08 -04:00
gingerBill
8421950546
Merge pull request #3637 from laytan/revert-clang++-detection
...
revert `$(llvm-config --bindir)/clang++` to get the cpp compiler
2024-05-26 19:16:32 +01:00
Laytan Laats
5027cfb618
revert $(llvm-config --bindir)/clang++ to get the cpp compiler
...
A few reports of either people not having this clang++ or having it but
it not finding system headers. On top of that, the reason we added this
in the first place was a bug that surfaced on clang-18 which we've since
fixed.
Order will now be clang++ from path, then the llvm bindir clang++, then an
error.
This can all still be overwritten with `CXX=blah make` like before.
2024-05-26 20:11:07 +02:00
gingerBill
149ae70be1
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-05-26 12:17:09 +01:00
gingerBill
64bdb3a097
Fix #3630 (first part)
2024-05-26 12:17:03 +01:00
gingerBill
ef7a155f9a
Merge pull request #3633 from korvahkh/fix-slice-has-affix
...
Fix slice.has_prefix & slice.has_suffix
2024-05-25 21:48:31 +01:00
korvahkh
58ae96c821
Fix slice.has_prefix & slice.has_suffix
...
The needle was the element type instead of the slice type.
2024-05-25 15:52:35 -05:00
Jeroen van Rijn
cfadca04f9
Merge pull request #3628 from IllusionMan1212/bitset-json-marshalling-fix
...
fix(core/encoding/json): remove Unsupported_Type return when marshalling bit_set
2024-05-25 08:34:59 +02:00
IllusionMan1212
65a4a56a83
fix(core/encoding/json): remove Unsupported_Type return when marshalling bit_set
2024-05-25 00:45:30 +02:00
Jeroen van Rijn
fb22c59d1b
Merge pull request #3625 from Kelimion/iso8061
...
Add dedicated ISO 8601 parser.
2024-05-24 23:56:20 +02:00
Jeroen van Rijn
b945e3e708
Limit to max of 9 fraction second digits, part deux.
2024-05-24 23:48:18 +02:00
Jeroen van Rijn
1473374bba
Limit to max of 9 fraction second digits.
2024-05-24 23:45:46 +02:00
Jeroen van Rijn
3526042f1e
Add dedicated ISO 8601 parser.
2024-05-24 23:40:14 +02:00
Jeroen van Rijn
e1c4b9b06a
Allow lowercase z TZ indicator.
2024-05-24 19:16:24 +02:00
Jeroen van Rijn
ff34970d79
Merge pull request #3623 from yay/allow-space-in-rfc-3339
...
Allow space (in addition to T and t) as RFC 3339 date/time separator.
2024-05-24 19:10:04 +02:00
Vitalii Kravchenko
ff94ca9e42
Allow space (in addition to T and t) as RFC 3339 date/time separator.
2024-05-24 18:03:52 +01:00
gingerBill
590db0838a
Fix types
2024-05-24 17:21:00 +01:00
Jeroen van Rijn
d698d4cdae
Merge pull request #3621 from laytan/enable-default-temp-allocator-wasm
...
wasm: enable default temp allocator
2024-05-24 15:42:51 +02:00
Jeroen van Rijn
d99e1616cf
Merge pull request #3620 from Kelimion/deprecate_odin_printer
...
Deprecate `core:odin/printer` in favor of OLS.
2024-05-24 15:02:59 +02:00
Laytan Laats
aa72050586
wasm: enable default temp allocator
...
After #3592 I think it makes sense to also enable the temp allocator by default
2024-05-24 15:01:02 +02:00
Jeroen van Rijn
b7cecc5762
Keep -vet happy.
2024-05-24 14:57:48 +02:00
Jeroen van Rijn
5c06480ce0
Add core:container/rbtree to examples/all
2024-05-24 14:55:21 +02:00
Jeroen van Rijn
dc744411c5
Deprecate core:odin/printer + format in favor of OLS.
2024-05-24 14:49:11 +02:00
Jeroen van Rijn
e2af3652c5
Merge pull request #3619 from Kelimion/csv_iterator
...
Add iterator_next(&r) to CSV.
2024-05-24 14:06:42 +02:00
Jeroen van Rijn
479d301e92
Merge pull request #3614 from Kelimion/rbtree
...
Add `core:container/rbtree`
2024-05-24 14:04:56 +02:00
Jeroen van Rijn
11e57fd3fd
Address concerns.
2024-05-24 13:58:30 +02:00
tim4242
0cba33075f
Add the option to export dependencies as JSON.
2024-05-24 13:44:38 +02:00
Jeroen van Rijn
2a4ddbb7be
Remove core:mem import in example.
2024-05-24 13:35:32 +02:00
Jeroen van Rijn
3b739dc5cc
Add iterator_next(&r) to CSV.
2024-05-24 13:26:12 +02:00
gingerBill
0658778a30
Merge pull request #3611 from hstormo/textbox
...
vendor/microui: nicer textbox
2024-05-24 11:51:09 +01:00
gingerBill
1081e9ac09
Fix enum definition for bit_set use
2024-05-24 11:41:56 +01:00
Jeroen van Rijn
c43d189a33
Fix package line.
2024-05-24 01:43:17 +02:00
tim4242
8664b88c8f
Improved depdendency formatting to support paths containing spaces
2024-05-24 01:20:45 +02:00
tim4242
7934e92d14
Initial dependency file generation
2024-05-24 01:04:41 +02:00
Håkon Stormo
4328562e2c
Satisfy -vet
2024-05-23 23:50:26 +02:00
Håkon Stormo
ee79c409b4
microui: use the text_edit procs
2024-05-23 23:28:58 +02:00
Håkon Stormo
d3bbe29faa
text_edit: better handle failure to resize underlying buffer
2024-05-23 23:28:39 +02:00
Jeroen van Rijn
410876b36a
Add core:container/rbtree
...
Add a red-black tree with configurable $Key and $Value.
Also includes tests that verify it maintains RB invariants, doesn't leak.
Originally based on the CC0 implementation from literateprograms.org.
But reworked to the same API used by @Yawning's excellent `core:container/avl` for ease of use.
2024-05-23 23:00:00 +02:00
Håkon Stormo
f411fcedb0
microui: textbox cut/copy/paste
2024-05-23 21:38:37 +02:00
Håkon Stormo
043ddd83a9
microui: textbox selection
2024-05-23 21:36:31 +02:00
gingerBill
7dc1f114b9
Add shadow suggestion
2024-05-22 22:22:41 +01:00
gingerBill
f3f08c264f
Be very particular with the cases for the error notes
2024-05-22 21:55:48 +01:00
gingerBill
2f35ee9671
Improve errors a lot for assigning procedures of the wrong signature
2024-05-22 21:52:15 +01:00
gingerBill
856537f0ce
Fix #3603
2024-05-20 15:54:53 +01:00
gingerBill
bc706f8b0c
Fix indexing type when using a #row_major matrix
2024-05-20 15:04:15 +01:00
gingerBill
a68c635c00
Remove constant indexing for matrix value propagation
2024-05-20 15:00:43 +01:00
gingerBill
f600562ca5
Improve fmt parsing of struct field tags
2024-05-20 14:45:49 +01:00
gingerBill
5ed93563a1
Merge pull request #3606 from Kelimion/fmtfix
...
Fix the way '%32b' and other prefixed numbers are written.
2024-05-20 14:29:50 +01:00
gingerBill
c49a291347
Merge pull request #3607 from Szwagi/fix-atomic-memory-order
...
Fix Odin to LLVM memory order mapping for .Relaxed and .Consume
2024-05-20 14:29:06 +01:00
Kamil T
f6ef395057
Fix Odin to LLVM memory order mapping for .Relaxed and .Consume
2024-05-20 13:57:08 +01:00
Jeroen van Rijn
e0d3d68ce5
Fix the way '%32b' and other prefixed numbers are written.
2024-05-20 14:42:13 +02:00
gingerBill
46b3e7b6fa
Fix for &v in &fixed_array
2024-05-20 13:36:32 +01:00
gingerBill
a80011c830
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-05-20 13:32:22 +01:00
gingerBill
542c3d7561
Improve "Expected a type" syntax error
2024-05-20 13:32:16 +01:00
gingerBill
f641399870
Merge pull request #3604 from matias-eduardo/master
...
remove extra newline in enumerated array hash fmt
2024-05-20 10:52:41 +01:00
gingerBill
891fefe117
Merge pull request #3592 from laytan/wasm-gpa
...
add a default heap/general purpose allocator for wasm to `base:runtime`
2024-05-20 10:38:09 +01:00
gingerBill
5473758467
Add intrinsics type_is_matrix_row_major & type_is_matrix_column_major
2024-05-20 10:15:21 +01:00
gingerBill
8eb7fe1859
Merge pull request #3482 from andreas-jonsson/netbsd-ci
...
NetBSD CI setup
2024-05-20 10:03:32 +01:00
gingerBill
8dec4f6ed3
Merge pull request #3570 from jasonKercher/linux-arm32
...
Get the compiler to build and work on arm32 Linux
2024-05-20 00:05:57 +01:00
gingerBill
b6d5be8593
Merge pull request #3593 from harold-b/fix-build-sysroot-macos
...
Attempt to automatically resolve the sysroot on build_odin.sh on macOS
2024-05-19 23:59:44 +01:00
gingerBill
1207d64c64
Fix intrinsics.ptr_sub
2024-05-19 23:55:45 +01:00
Matias Fernandez
a9629679ed
remove extra newline in enumerated array hash fmt
2024-05-18 23:24:05 -04:00
Jeroen van Rijn
c091b0d060
Merge pull request #3602 from Kelimion/qoifix
...
Apply fix to QOI decoder as well.
2024-05-18 19:48:37 +02:00
Jeroen van Rijn
58a1bb32e5
Apply fix to QOI decoder as well.
2024-05-18 19:41:07 +02:00
Jeroen van Rijn
5b92425e93
Merge pull request #3601 from Kelimion/qoifix
...
Fix qoi encoding bug.
2024-05-18 14:06:25 +02:00
Jeroen van Rijn
7955f4ddf1
Fix qoi encode bug.
2024-05-18 13:59:50 +02:00
gingerBill
98f8624447
Merge pull request #3594 from laytan/runtime-wasm64p32-fixes
...
correctly load/store uint&int in the runtime.js for wasm64p32
2024-05-17 17:32:36 +01:00
Laytan Laats
e08b51ed73
correctly load/store uint&int in the runtime.js for wasm64p32
2024-05-17 16:32:34 +02:00
Jeroen van Rijn
cf10c6d993
Merge pull request #3598 from Kelimion/i18n-fix
...
i18n: Add section merge + duplicate key detection to gettext.
2024-05-17 15:57:17 +02:00
Jeroen van Rijn
f8c4ee3d3c
i18n: Add section merge + duplicate key detection to gettext.
2024-05-17 15:50:37 +02:00
Jeroen van Rijn
419641ad8f
Merge pull request #3596 from Kelimion/i18n-fix
...
Fix .mo contexts
2024-05-17 14:26:57 +02:00
Jeroen van Rijn
6139da3d41
Fix .mo contexts
...
Fixes #3590
- `get("key")`
- `get("context", "key")`
2024-05-17 14:15:56 +02:00
Jeroen van Rijn
b51eb53d04
Merge pull request #3595 from Kelimion/i18n-fix
...
Fix .mo parser: Number of plurals
2024-05-17 12:15:40 +02:00
Jeroen van Rijn
5a76b3c7c5
Fix .mo parser: Number of plurals
...
Fixes #3591
Added plur.mo to tests
2024-05-17 12:00:20 +02:00
Harold Brenes
f1b291ed62
Attempt to automatically resolve the sysroot on build_odin.sh on macOS
2024-05-16 17:53:41 -04:00
Laytan Laats
f42b1c4973
add a default heap/general purpose allocator for wasm to base:runtime
2024-05-16 23:08:40 +02:00
gingerBill
ab8e3db7e9
Remove bad code
2024-05-16 17:18:37 +01:00
gingerBill
575b268e88
Fix more #soa changes
2024-05-16 17:15:38 +01:00
gingerBill
7cf62f00c3
Correct #soa RTTI usage
2024-05-16 16:30:45 +01:00
gingerBill
c9b1c99a40
Fix soa_zip and soa_unzip
2024-05-16 16:27:09 +01:00
gingerBill
32245e93a1
Fix #3514 along with soa.a[i] bounds checking
2024-05-16 16:18:21 +01:00
gingerBill
330d6117e3
Fix #3589
2024-05-16 15:43:08 +01:00
gingerBill
b2dc5cc812
Fix error reporting for enforce new switch/for syntax
2024-05-16 15:32:15 +01:00
gingerBill
a344bc4c0e
Remove the old switch/for semantics entirely and enforce switch &x in y
2024-05-16 14:39:16 +01:00
gingerBill
e71cd871c4
Reimplement -build-mode:static/-build-mode:lib
2024-05-16 14:27:05 +01:00
Andreas T Jonsson
a93bbf6f92
Merge branch 'master' into netbsd-ci
2024-05-16 13:48:44 +02:00
gingerBill
f9fd8f0c25
Merge pull request #3439 from andreas-jonsson/netbsd
...
NetBSD support
2024-05-15 10:33:52 +01:00
gingerBill
59c33dd9fc
Add Fstat_Callback for File.user_fstat
2024-05-14 18:57:03 +01:00
gingerBill
6f9dcb4e02
Add missing @(require_results)
2024-05-14 18:46:45 +01:00
gingerBill
2b43535961
Fix typo
2024-05-14 18:45:47 +01:00
gingerBill
61826594c9
Add comment state to prefer virtual.Arena over runtime.Arena
2024-05-14 18:37:23 +01:00
gingerBill
9a487ccb6f
Delete dead code
2024-05-14 18:35:24 +01:00
gingerBill
453fc5182b
Remove all uses of context stuff in os2
2024-05-14 18:34:05 +01:00
gingerBill
450b9ceaec
Add @(require_results) everywhere in os2
2024-05-14 18:25:15 +01:00
gingerBill
48c1822709
Move utility stuff to internal_util.odin
2024-05-14 18:14:44 +01:00
gingerBill
91b7cdaad2
Mock out temp_file.odin stuff
2024-05-14 18:11:50 +01:00
gingerBill
361be301fa
Use internal temp_allocator()
2024-05-14 17:24:37 +01:00
gingerBill
ecd7846ec3
Clean up allocator stuff into allocators.odin
2024-05-14 17:10:53 +01:00
gingerBill
e05315831f
Fix #3586
2024-05-14 00:18:38 +01:00
gingerBill
7734b12f9a
Fix #3587
2024-05-14 00:16:32 +01:00
gingerBill
20f8f9012d
Attempt at fixing #3588
2024-05-14 00:11:57 +01:00
gingerBill
0cf9dcd314
Make .. ranges a complete error rather than a warning now.
...
This should have been an error years ago.
2024-05-13 18:15:29 +01:00
gingerBill
8fa20fb875
Extra check for field being nullptr
2024-05-13 14:44:53 +01:00
gingerBill
1b593fc1ca
Correct core:intrinsics to base:intrinsics
2024-05-13 13:27:44 +01:00
gingerBill
215ef3d985
Make core:runtime etc a warning, and an error with -vet
2024-05-13 13:26:47 +01:00
gingerBill
8808e5584a
If only warnings exist on print_all_errors, next time it is called, clear the error list.
...
This is mostly only syntax errors too
2024-05-13 13:26:22 +01:00
gingerBill
54ebfa6179
Fix hanging on thread.join for windows where the thread had not been started
2024-05-13 12:58:18 +01:00
gingerBill
4bdc8548bd
Fix #3554
2024-05-13 12:55:49 +01:00
gingerBill
6dc0ee3877
Fix #3577
2024-05-13 12:54:01 +01:00
gingerBill
8d687a959d
Fix #3516
2024-05-13 12:52:28 +01:00
gingerBill
8b4a8e4d80
Fix #3569
2024-05-13 12:49:12 +01:00
gingerBill
90f26368d9
Merge pull request #3572 from Feoramund/fix-unix-nonstart-thread-stall
...
Fix joining non-`Started` threads from blocking main thread
2024-05-13 12:45:02 +01:00
gingerBill
e4ec7cc3f3
Merge pull request #3580 from Feoramund/suggest-test-all-packages
...
Suggest `-all-packages` flag when testing empty directory
2024-05-13 12:42:48 +01:00
gingerBill
34c8739b69
Fix #3578
2024-05-13 12:42:06 +01:00
gingerBill
d1217340f5
Fix #3573
2024-05-13 12:26:01 +01:00
gingerBill
4eab735b13
Minor clean up of is_terminating code
...
This does not fix all known issues with it
2024-05-13 12:24:50 +01:00
gingerBill
f8d235b6f5
Fix #3581 due to typo
2024-05-13 12:02:02 +01:00
gingerBill
7905f0533f
Fix #3582 by disallowing it
2024-05-13 12:01:16 +01:00
gingerBill
3fb0d52a74
Fix #3585
2024-05-13 11:57:04 +01:00
gingerBill
07a538cd82
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-05-13 11:54:05 +01:00
gingerBill
facae34354
Fix #3584
2024-05-13 11:53:59 +01:00
Andreas T Jonsson
5541f60233
Check examples/all on NetBSD
2024-05-13 10:02:48 +02:00
Andreas T Jonsson
bde8407ce8
Merge branch 'netbsd' into netbsd-ci
2024-05-13 10:01:12 +02:00
Andreas T Jonsson
6298d4a36c
Fixed some build tags in vendor libs
2024-05-13 10:00:19 +02:00
Andreas T Jonsson
3e181af409
Merge branch 'netbsd' into netbsd-ci
2024-05-13 09:44:27 +02:00
Andreas T Jonsson
88528f7613
Updated makefiles to exclude some tests on BSDs
2024-05-13 09:41:54 +02:00
Andreas T Jonsson
5d82f0cad5
Merge branch 'master' into netbsd
2024-05-13 09:21:32 +02:00
Feoramund
971201182a
Fix read_directory() skipping directories on UNIX-likes
2024-05-12 19:52:36 -04:00
Feoramund
1935811b2c
Suggest -all-packages if testing empty directory
2024-05-12 19:51:19 -04:00
Jeroen van Rijn
1183f4794b
Merge pull request #3579 from Kelimion/test_string_compare
...
Test string compare
2024-05-12 23:52:39 +02:00
Jeroen van Rijn
23545c3f37
Enable in Makefile
2024-05-12 23:47:42 +02:00
Jeroen van Rijn
41b8f06f51
Add 1 more each for < and >
2024-05-12 23:43:05 +02:00
Jeroen van Rijn
55d21f4c2f
Test string compare
...
To avoid regression of the bug fixed in f8581537e4 .
2024-05-12 23:38:17 +02:00
gingerBill
f8581537e4
Fix >= for strings
...
How did this not get noticed?!?!
2024-05-12 20:25:13 +01:00
gingerBill
0f76c22c46
Check for illegal use of distinct
2024-05-12 17:48:06 +01:00
gingerBill
6bfaf4a093
Fix another oversight for bit_field endian with 1-byte types
2024-05-11 22:36:17 +01:00
gingerBill
f650690f61
Merge pull request #3574 from jasonKercher/i386-syscall6
...
fix 6 argument syscall on i386
2024-05-11 21:50:49 +01:00
gingerBill
321e4c45b0
Merge pull request #3576 from korvahkh/json-marshal-no-nil
...
encoding/json: Properly marshal `#no_nil` unions
2024-05-11 21:50:26 +01:00
korvahkh
9b759f39fc
encoding/json: Properly marshal #no_nil unions
...
Previously the first variant of a `#no_nil` would always be output as
`null`, and following variants would be treated as the wrong type.
2024-05-11 14:36:56 -05:00
Jeroen van Rijn
3a3ae6d0df
Fix and re-enable .doc tests.
2024-05-11 19:25:35 +02:00
gingerBill
ad0053b798
Make doc writer use the old "Ordered Insertion" based PtrMap
2024-05-11 16:24:37 +01:00
gingerBill
8e263de4aa
Fix error message handling
2024-05-11 13:59:06 +01:00
gingerBill
811d53b305
Generalize to any 1-byte element in bit_field
2024-05-11 13:48:19 +01:00
gingerBill
aea28d5189
Allow edge-case where backing type of a bit_field is (array of) u8, to allow any endian type
2024-05-11 13:47:33 +01:00
jason
20752d904b
fix 6 argument syscall on i386
2024-05-10 23:06:49 -04:00
Feoramund
33c6f75a2e
Fix joining non-Started threads from blocking main thread
2024-05-10 17:24:45 -04:00
jasonkercher
2183140e71
arm32 now compiles and runs demo
2024-05-10 13:24:43 -04:00
Andreas T Jonsson
f428e30211
Minor code cleanup
2024-05-10 17:49:56 +02:00
Jeroen van Rijn
2250eb3e78
Enable core:fmt tests.
2024-05-10 17:05:18 +02:00
gingerBill
aebb5a5178
Merge pull request #3506 from IllusionMan1212/windows-hid
...
core/sys/windows: added various procedures and constants for the hid library
2024-05-10 16:03:13 +01:00
gingerBill
b4d0b1d17d
Merge pull request #3544 from ntn9995/fix-parser-empty-or-no-pkg
...
Fix core:odin/parser crashing on empty and/or no package files
2024-05-10 16:01:16 +01:00
gingerBill
20d35acce1
Fix parser
2024-05-10 15:59:14 +01:00
gingerBill
6c4672c158
Merge pull request #3566 from Feoramund/fmt-refactor
...
Refactor `wprintf`
2024-05-10 15:56:26 +01:00
gingerBill
3095f46d7e
Add runtime.Typeid_Bit_Field
2024-05-10 15:50:47 +01:00
ikarus
3add85e7a7
fix typo & free memory when skipping empty files
2024-05-10 14:51:09 +01:00
gingerBill
ad5c9469d8
Fix #3522
2024-05-10 14:22:43 +01:00
gingerBill
710bb4369f
Fix #3567
2024-05-10 13:55:15 +01:00
Andreas T Jonsson
a9b94f4019
Merge branch 'netbsd' into netbsd-ci
2024-05-10 13:34:02 +02:00
gingerBill
944fdd11f2
Keep -vet happy
2024-05-10 12:03:08 +01:00
gingerBill
07739b48ee
Merge pull request #3565 from wschiefer/update-d3d12
...
Update d3d12 API
2024-05-10 12:00:39 +01:00
gingerBill
b269fd00f0
Merge pull request #3560 from wschiefer/add-more-win32-console-apis
...
Add more win32 console APIs
2024-05-10 12:00:28 +01:00
gingerBill
04c391074d
Merge pull request #3561 from wschiefer/update-dxgi
...
Adding DXGI 1.5 & 1.6 APIs
2024-05-10 12:00:11 +01:00
Andreas T Jonsson
a45e69e656
Removed dead code
2024-05-10 09:12:56 +02:00
Andreas T Jonsson
b72c2edabb
Merge branch 'master' into netbsd
2024-05-10 09:04:52 +02:00
Andreas T Jonsson
273e4c6b4c
Changed target data layout
2024-05-10 08:47:51 +02:00
Andreas T Jonsson
f1491280ab
Fixed invalid alignment
2024-05-10 08:16:10 +02:00
Feoramund
fb2549a7da
Extend test suite for fmt
2024-05-09 19:44:16 -04:00
Feoramund
11180e36ae
Amend fmt documentation
2024-05-09 19:38:44 -04:00
Feoramund
8c111f1baf
Fix %e printing incorrect precision
...
For example, `%.2e` with 30.56 as the value would produce `30.60e+01`,
as opposed to C's printf producing `30.6e+01`.
2024-05-09 19:37:17 -04:00
Feoramund
5e149d2cae
Refactor wprintf
...
- Extracts common code between C and Python-like syntax into its own
sub-procedures.
- Fixes Python-like syntax from treating `}` as a verb.
- Makes C-like syntax treat ' ' as a missing verb.
- Fixes EXTRA arguments being formatted with options that were
previously set, instead using default options now.
- Makes error messaging more consistent between C and Python-like
syntax.
- Requires argument index to be specified immediately before the verb
in C-like syntax, per the documentation, instead of after `%` _or_
before the verb.
- Tracks argument usage through a `bit_set`, allowing for reporting of
unused arguments even when reordered.
- Moves exit for C-like syntax if next byte is `%` to beginning of
block instead of needlessly trying to parse through all options.
- Pops next unused argument for unspecified formatters like `%i` or
`{}`, instead of taking the argument after the last one used.
- Fixes unspecified precision `%.f` from not setting precision to zero,
per the documentation.
2024-05-09 19:28:04 -04:00
Jeroen van Rijn
41bd8cf714
Merge pull request #3563 from laytan/fix-duplicate-suggestions
...
fix duplicate suggestions and add missing newline
2024-05-09 20:20:18 +02:00
Jeroen van Rijn
1604f37cb8
Merge pull request #3564 from laytan/fix-some-vet-style-failures
...
fix a couple of `-vet-style` failures
2024-05-09 20:19:46 +02:00
Waldemar Schiefer
935865a978
Update d3d12 API
2024-05-09 19:46:02 +02:00
Laytan
d7fdccb08c
fix a couple of -vet-style failures after f54977336b
2024-05-09 19:39:48 +02:00
Laytan
98827c867d
fix duplicate suggestions and add missing newline
2024-05-09 19:21:39 +02:00
Jeroen van Rijn
8a1e7bb6fb
Merge pull request #3562 from Kelimion/bitset_to_enum_slice
...
Bitset to enum slice
2024-05-09 18:03:42 +02:00
Jeroen van Rijn
8f706a14f8
Add allocator param.
2024-05-09 17:58:48 +02:00
Jeroen van Rijn
e5af98eabe
Simplify bitset_to_enum_slice
2024-05-09 17:55:50 +02:00
Jeroen van Rijn
858c78b844
Pass new -vet-style check.
2024-05-09 17:47:19 +02:00
Jeroen van Rijn
a61d8daec1
Add make version of bitset to slice.
2024-05-09 17:44:39 +02:00
Waldemar Schiefer
cceac781e7
Add DXGI 1.5 & 1.6 APIs
2024-05-09 17:36:26 +02:00
Jeroen van Rijn
113feacbc7
Merge pull request #3559 from Kelimion/bitset_to_enum_slice
...
Add slice.enum_slice_to_bitset & slice.bitset_to_enum_slice
2024-05-09 17:21:04 +02:00
Jeroen van Rijn
7bcf3b1a0d
Add slice.enum_slice_to_bitset & slice.bitset_to_enum_slice
2024-05-09 17:15:45 +02:00
gingerBill
f54977336b
With -vet-style, give suggestion of separating where clauses with a comma rather than '&&'
...
This improves the error messages
2024-05-09 15:56:00 +01:00
gingerBill
b0f0e4d02a
Add intrinsics type_bit_set_elem_type & type_bit_set_underlying_type
2024-05-09 15:47:09 +01:00
Waldemar Schiefer
abcbb8b47a
Add more win32 console APIs
2024-05-09 16:41:09 +02:00
gingerBill
d85c8f0b2c
Fix #3555
2024-05-09 10:58:57 +01:00
gingerBill
97e9c50d11
Fix #3556
2024-05-09 10:44:06 +01:00
gingerBill
9b75656400
Merge pull request #3308 from laytan/llvm-18
...
Support LLVM 18 (non-windows targets for now)
2024-05-08 13:39:57 +01:00
ikarus
60b6c798a5
tabs for indentation
2024-05-08 09:07:53 +01:00
IllusionMan1212
ad3675cdd6
core/sys/windows: added various procedures and constants related to the hid library
2024-05-07 21:18:25 +02:00
Laytan Laats
9d1db48549
remove is_packed bodge
2024-05-07 17:25:17 +02:00
Laytan
b0b60fe7ed
fix segfault in release builds of the compiler with clang++-18
2024-05-07 16:52:46 +02:00
Laytan
87b099b5aa
fix merge conflict
2024-05-07 16:52:46 +02:00
Laytan Laats
77efdcd899
fix packed gep loads with wrong alignment
2024-05-07 16:52:46 +02:00
Laytan Laats
58c0abb98d
revert wrong approach in fixing the load alignment
2024-05-07 16:52:46 +02:00
Laytan
d93cc18dac
fix packed gep loads with wrong alignment
2024-05-07 16:52:46 +02:00
Laytan Laats
ecddf3b7f1
llvm-18: cleanup
2024-05-07 16:52:46 +02:00
Laytan Laats
a3821615dc
llvm-18: fix windows build error because of include
2024-05-07 16:52:46 +02:00
Laytan Laats
f9a7d2bf04
llvm-18: enable static map calls on non amd64sysv targets
2024-05-07 16:52:46 +02:00
Laytan
c219ca5b1b
llvm-18: fix undocumented breaking change on i128 alignment
2024-05-07 16:52:46 +02:00
Laytan Laats
f64e8ffd64
llvm-18: fix linking the compiler with clang-18
2024-05-07 16:52:46 +02:00
Laytan Laats
e3e04ffa22
llvm-18: enable sroa and static map calls
2024-05-07 16:52:46 +02:00
Laytan
043dd98e91
fix demo out of bounds error
2024-05-07 16:52:46 +02:00
Laytan
b91e7f5c51
llvm-18: linux (amd64)
2024-05-07 16:52:46 +02:00
Laytan Laats
bb58926b7a
llvm 18: general unix and darwin specifics
2024-05-07 16:52:46 +02:00
gingerBill
1d3c061add
Fix typo
2024-05-07 15:52:13 +01:00
gingerBill
de5ce90fa7
Add metadata to packed structs field accesses to state it is packed
2024-05-07 15:28:09 +01:00
gingerBill
3f7a369aa1
Check for specialization in typeid/T for parapoly records
2024-05-07 14:53:02 +01:00
gingerBill
94b4af5d36
Merge pull request #3540 from VictorSohier/handle-fixed-soa-arrays
...
Handle fixed soa arrays
2024-05-07 14:33:25 +01:00
gingerBill
e378516011
Merge pull request #3547 from hnakamur/pass_size_to_epoll_create
...
sys/linux: Pass size to epoll_create
2024-05-07 14:33:18 +01:00
Jeroen van Rijn
2b1afa0762
Merge pull request #3521 from Su3h7aM/correct-clang++
...
Uses correct `clang++` binary for non-standard versions
2024-05-07 13:25:59 +02:00
gingerBill
0cec2d7827
Fix #3527
2024-05-07 11:51:06 +01:00
gingerBill
8d96c68528
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-05-07 11:42:53 +01:00
gingerBill
0da6a3e214
Fix #3530
2024-05-07 11:42:48 +01:00
gingerBill
41d38bf964
Merge pull request #3468 from Feoramund/fix-pthread-cancel
...
Fix discrepancy with pthread cancelability state
2024-05-07 11:30:07 +01:00
gingerBill
05a1704898
Fix #3464
2024-05-07 11:24:21 +01:00
gingerBill
1818df786d
Free memory for the error messages just in case
2024-05-07 11:21:12 +01:00
gingerBill
b23f1dd5ff
Merge neighbouring error messages with the same location
2024-05-07 11:19:16 +01:00
Jeroen van Rijn
96abe8627c
Merge pull request #3551 from Feoramund/fix-max-bitfield-size
...
Fix lack of adding to `total_bit_size`
2024-05-07 00:47:15 +02:00
Feoramund
6ec7845249
Fix #3531
...
Individual `bit_field` size was not being added to the total size.
Error message was changed to be more explicit.
2024-05-06 18:30:04 -04:00
Victor Sohier
56b62996c3
Remove breakpoint hook
2024-05-06 18:20:20 -04:00
Victor Sohier
6cb0f5d8c5
Explicitly handle previously implicitly handled case
2024-05-06 18:04:35 -04:00
Hiroaki Nakamura
df53fec828
sys/linux: Pass size to epoll_create
...
Without this fix, you can see a random size value is passed to
epoll_create by using strace.
2024-05-06 21:44:59 +09:00
ikarus
16fbfd0418
ignore empty files and errors on no package
2024-05-06 09:25:22 +01:00
Victor Sohier
a9b18c1ec0
Formatting
2024-05-05 21:15:41 -04:00
Victor Sohier
8e4f9cb777
Fix: Fixed #soa arrays
2024-05-05 21:08:33 -04:00
gingerBill
15f7148eae
Merge pull request #3526 from laytan/target-features
...
Improve target features support
2024-05-05 21:50:57 +01:00
gingerBill
1e5267c8e7
Merge pull request #3532 from laytan/fix-invalid-json
...
fix invalid JSON when an error does not have a position
2024-05-05 16:48:12 +01:00
gingerBill
96a4cecee5
Merge pull request #3536 from laytan/linux-fix-open-bits
...
sys/linux: fix open bits
2024-05-05 16:47:42 +01:00
gingerBill
8ba36ca85c
Merge pull request #3535 from Feoramund/freebsd-arm64-minimal
...
Minimally support compiling Odin on FreeBSD arm64
2024-05-05 16:47:28 +01:00
Laytan Laats
eaab17f8fb
sys/linux: fix open bits
2024-05-05 14:16:21 +02:00
Feoramund
1165d65c94
Minimally support compiling Odin on FreeBSD arm64
...
This is enough to get Odin itself compiling and the demo running.
2024-05-05 07:26:45 -04:00
Laytan Laats
ee818304f3
fix invalid JSON when an error does not have a position
2024-05-05 00:01:14 +02:00
Su3h7aM
30ff15e538
build: uses correct clang++ binary for non-standard versions
2024-05-03 13:20:51 -03:00
gingerBill
17a01a81d8
Merge pull request #3528 from laytan/fix-some-sync-issues
...
Fix some sync issues
2024-05-03 17:14:50 +01:00
gingerBill
595726e6c5
Merge pull request #3369 from joakin/fix-dynamic-library-from-vendor-on-linux
...
Fix vendor dynamic libraries not working on Linux
2024-05-03 17:14:32 +01:00
gingerBill
fed03e896c
Merge pull request #3525 from Feoramund/fix-more-error-racecond
...
Fix more race conditions in error reporting
2024-05-03 17:14:13 +01:00
gingerBill
2201f365a1
Allow #no_alias on multi-pointers
2024-05-03 14:51:02 +01:00
gingerBill
f2505b096d
Improve error message's suggestion for if !integer
2024-05-03 14:22:30 +01:00
gingerBill
242307dd44
Revert to old StringMap internal layout
2024-05-03 12:34:12 +01:00
Laytan Laats
8aab395c70
darwin: fix minimum os version check not being inclusive
2024-05-02 21:18:49 +02:00
Laytan Laats
8506e64345
sync: fix deadlock in one shot event
2024-05-02 20:49:29 +02:00
Andreas T Jonsson
1d3845abf5
Added prebuilt clang17
2024-05-02 16:52:46 +02:00
Andreas T Jonsson
ecaa26710b
Fixed invalid package name
2024-05-02 14:50:13 +02:00
Andreas T Jonsson
9de9223578
Use custom llvm binaries
2024-05-02 14:38:54 +02:00
Andreas T Jonsson
021271091a
Merge branch 'netbsd' into netbsd-ci
2024-05-02 09:34:17 +02:00
Andreas T Jonsson
7feff1c113
Merged with master
2024-05-02 09:27:46 +02:00
Laytan Laats
25f1d0906d
compiler: improve target features support
2024-05-02 00:59:52 +02:00
Feoramund
67b786c738
Fix more race conditions in error reporting
2024-05-01 16:41:02 -04:00
Jeroen van Rijn
fd582015fe
Remove stray binary.
2024-04-30 20:58:36 +02:00
Jeroen van Rijn
58e12f0b17
Merge pull request #3520 from flysand7/sys-linux-oflags
...
[sys/linux]: Fix bit numbers for open flags
2024-04-30 20:40:24 +02:00
flysand7
9ffa4a4eb1
[sys/linux]: Fix bit numbers for open flags
2024-05-01 05:24:02 +11:00
gingerBill
eb06cb5d23
Merge pull request #3518 from laytan/sysinfo-arm-additions
...
sys/info: add arm feature detection, fix Linux implementation, show more CPU info on Darwin
2024-04-30 12:48:48 +01:00
gingerBill
5c1201fa42
Fix #3459
2024-04-30 09:10:00 +01:00
Laytan Laats
c0ca26ac17
sys/info: add missing @(private)'s
2024-04-30 00:24:09 +02:00
Laytan Laats
b41395e3b4
sys/info: update doc.odin
2024-04-30 00:24:09 +02:00
Laytan Laats
d40c207fde
sys/info: retrieve better CPU description on Darwin
...
Previously either `ARM` or `ARM64`, now you get something like `Apple
M1`
2024-04-30 00:24:09 +02:00
Laytan Laats
8660718ebe
sys/info: add feature detection for Darwin and Linux ARM
2024-04-30 00:24:09 +02:00
Laytan Laats
485afb011c
sys/info: improve platform_linux
...
1. fix the `linux.open` call, passing `{ .RDONLY }` becomes `0x00000001`
while `RDONLY` is supposed to be `0x00000000`
2. fix the case where `/etc/os-release` starts with `PRETTY_NAME`
`strings.index` was used but was checking `> 0` while `0` is valid
3. remove unneccesary temporary allocations
4. simplify the logic
2024-04-30 00:24:09 +02:00
Laytan Laats
9e94e9dac1
sys/info: remove unneccesary build tags
2024-04-30 00:24:09 +02:00
Laytan Laats
cebe6bd982
sys/unix: add sysctlbyname for darwin
2024-04-30 00:24:09 +02:00
Laytan Laats
c58da76562
sys/darwin: fix sysctl and sysctlbyname syscalls
2024-04-30 00:24:09 +02:00
Laytan Laats
e896efdaeb
sys/info: add easy way of getting the MacOS version
2024-04-30 00:24:09 +02:00
Timo
2918baa3e8
Update builder.odin
...
Modify documentation-text for procedure write_f64 :
change type f32 to f64
2024-04-29 20:22:53 +02:00
gingerBill
ff0973e0f5
Merge pull request #3513 from thetarnav/patch-2
...
Remove instrinsics and utf16 imports from os/os_js
2024-04-29 16:51:45 +01:00
Damian Tarnawski
ae322739b5
Remove instrinsics and utf16 imports from os/os_js
2024-04-29 16:59:52 +02:00
gingerBill
f6345d20f7
Merge pull request #3508 from Feoramund/fmt-alloc-print-reqres
...
Require results for non-buffered `print` procs
2024-04-29 12:04:58 +01:00
gingerBill
227aab8f39
Merge pull request #3507 from IllusionMan1212/glsl-fix
...
fix(linalg/glsl): incorrect quat by vector3 multiplication
2024-04-29 12:04:07 +01:00
gingerBill
d6824ea607
Merge pull request #3505 from Feoramund/allow-disabled-init-procs
...
Allow `@(init)` procs to be `@(disabled)`
2024-04-29 12:03:54 +01:00
gingerBill
2f88ded81a
Merge pull request #3504 from Feoramund/fix-racecond-error-va
...
Fix race condition in `error_va`
2024-04-29 12:03:26 +01:00
Feoramund
bbebb4ad60
Fix unseen print call in demo
2024-04-28 17:20:52 -04:00
Feoramund
700f9c94bd
Combine adjacent sbprint*/to_string calls
...
The `sbprint*` procs already return a string conversion.
2024-04-28 17:18:46 -04:00
Feoramund
c712de0cd0
Require results for non-buffered print procs
2024-04-28 17:17:01 -04:00
IllusionMan1212
1f5f417116
fix(linalg/glsl): incorrect quat by vector3 multiplication
2024-04-28 21:44:34 +02:00
Feoramund
a573161abd
Allow @(init) procs to be @(disabled)
2024-04-28 14:42:04 -04:00
Feoramund
f1c13d6bd8
Fix race condition in error_va
...
If the error count exceeded `MAX_ERROR_COLLECTOR_COUNT`, multiple
threads could print and exit simultaneously, causing a segfault.
This change moves the mutex lock back before the conditional.
2024-04-28 14:03:11 -04:00
Artsiom Babukh
805bb69c6c
Fix typo in core_builtin
2024-04-28 15:27:34 +00:00
gingerBill
a37826e646
Merge pull request #3268 from olesya-wo/core-mem-tracking_allocator-improve
...
Improved statistics for core/mem/Tracking_Allocator
2024-04-28 16:01:01 +01:00
gingerBill
3b4169c903
Merge pull request #3495 from Feoramund/fix-rune-literal-error-double-reporting
...
Fix invalid rune literal reported twice
2024-04-28 15:22:05 +01:00
gingerBill
0eb97dba6e
Merge pull request #3496 from laytan/allow-default-to-nil-allocator-on-wasm
...
wasm: allow `-default-to-nil-allocator`
2024-04-28 15:21:45 +01:00
gingerBill
fa5e6d2d84
Merge pull request #3497 from laytan/fix-buddy-allocator-wrong-query-info
...
fix: buddy allocator wrong query info pointer
2024-04-28 15:21:35 +01:00
gingerBill
4668dafa2b
Merge pull request #3498 from laytan/add-fprint-to-wasm
...
wasm: add the `fprint` procedures to `fmt`
2024-04-28 15:21:27 +01:00
Laytan Laats
cc5faecced
wasm: add the fprint procedures to fmt
...
This makes the `log` package work on wasm
2024-04-28 16:10:04 +02:00
Laytan Laats
0530f86a48
fix: buddy allocator wrong query info pointer
2024-04-28 16:09:03 +02:00
Laytan Laats
4fea5720a5
wasm: allow -default-to-nil-allocator
2024-04-28 16:05:41 +02:00
gingerBill
30cfdd73b0
Add extra asserts
2024-04-28 14:45:59 +01:00
gingerBill
950fd2d5ce
Rename trace_linux.odin to trace_cpp.odin
2024-04-28 13:52:52 +01:00
gingerBill
74d75fb7fb
Correct types on windows
2024-04-28 13:51:46 +01:00
gingerBill
7ee2c1084f
Update doc.odin
2024-04-28 13:51:10 +01:00
gingerBill
c0b7dd7da6
Remove need for allocator and MAX_FRAMES in trace.frames
2024-04-28 13:05:19 +01:00
gingerBill
be09584ea5
Increase MAX_FRAMES
2024-04-28 12:56:53 +01:00
gingerBill
5ac8e8f9fd
Add doc.odin
2024-04-28 12:52:02 +01:00
gingerBill
2eea06fc73
Set in_resolve for linux
2024-04-28 12:51:10 +01:00
gingerBill
0fa269811a
Change layout of Frame_Location
2024-04-28 12:49:17 +01:00
gingerBill
6c185a5dca
Add core:debug/trace for Linux
2024-04-28 12:43:27 +01:00
gingerBill
f428f26c8e
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-04-28 12:05:21 +01:00
gingerBill
44c9b988bb
Add default debug/trace to do nothing
2024-04-28 12:05:15 +01:00
Feoramund
29987c20c0
Fix invalid rune literal reported twice
...
The tokenizer and the parser were reporting it in different positions.
This way, they'll report in the same spot.
2024-04-28 07:02:21 -04:00
gingerBill
51d4dde63c
Merge pull request #3494 from Feoramund/fix-3481
...
Clear unused `global_error_collector.curr_error`
2024-04-28 11:59:18 +01:00
gingerBill
362aa82f59
Begin work on core:debug/trace
2024-04-28 11:58:16 +01:00
Feoramund
ebfbe4d260
Clear unused global_error_collector.curr_error
...
This should cleanly prevent acknowledging duplicate errors on the same
position as seems to be the intent based on the prior `else if`
condition.
2024-04-28 06:44:28 -04:00
gingerBill
e71cf96bbc
Keep -vet happy
2024-04-28 11:35:51 +01:00
gingerBill
383c17e842
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-04-28 11:31:55 +01:00
gingerBill
00b1a41540
Add stack frame procedures for core:sys/windows
2024-04-28 11:31:50 +01:00
PucklaJ
37b026cb9b
[sys/linux] Directly call syscall in execve on arm64
2024-04-28 12:00:40 +02:00
PucklaJ
d1a205e2cf
[sys/linux]: Remove clone syscall and call it directly in fork on arm64
2024-04-28 11:56:19 +02:00
PucklaJ
7f301790d0
[sys/linux] Change flags parameter of execveat to bit_set
2024-04-28 11:48:18 +02:00
Jeroen van Rijn
8fd318ea7a
Merge pull request #3492 from DreepyYunky/Add-SetMenu
...
Add `SetMenu()`
2024-04-27 20:04:15 +02:00
Yunky
1deb53cddb
Add SetMenu
2024-04-27 18:58:46 +01:00
gingerBill
05b5b8503d
Merge pull request #3491 from Feoramund/fix-json-omitempty
...
Fix `omitempty` in `json.marshal`
2024-04-27 15:32:21 +01:00
PucklaJ
b0fe6212bb
[sys/linux]: Fix return statement
2024-04-27 13:21:04 +02:00
gingerBill
5e1b376e22
Disallow for x in bitset_or_map if x is a variable that matches the "key"
2024-04-27 10:34:17 +01:00
Feoramund
309a770cbf
Fix omitempty in json.marshal
2024-04-27 05:24:59 -04:00
gingerBill
393e4a9db6
Generalize Odin call-based "iterators" to work with more than 2-values: for x, y, z, w in iterate(&it)
...
It has an artificial limitation of 100 values because if you need for than that, you're doing something wrong.
2024-04-27 09:53:02 +01:00
gingerBill
efae99971b
Fix missing _ =
2024-04-27 09:19:50 +01:00
gingerBill
4454849252
Add attributes to procedures in text/scanner
2024-04-27 09:16:36 +01:00
gingerBill
c752d0b541
Fix printing of big endian integers in a bit_field
2024-04-27 09:16:18 +01:00
gingerBill
5969796fbf
Merge pull request #3490 from odin-lang/new-string-map
...
Change layout of compiler hash map types
2024-04-27 09:03:05 +01:00
gingerBill
6520794764
Fix wrong allocator usage
2024-04-27 08:50:05 +01:00
gingerBill
9d3f835e31
Merge pull request #3462 from Yawning/feature/math-sys-rand
...
core:math/rand: Use `crypto.rand_bytes()` for the system RNG
2024-04-27 08:43:02 +01:00
gingerBill
70aa2ff90a
Merge pull request #3489 from Feoramund/fix-build-freebsd
...
Fix wrong llvm-config in build script for FreeBSD
2024-04-27 08:40:23 +01:00
gingerBill
a60a7f64b9
Merge pull request #3483 from laytan/negative-improvements
...
improve some Negative_Read/Negative_Write logic
2024-04-27 08:38:29 +01:00
gingerBill
2368014d06
Merge pull request #3486 from Feoramund/fix-chan-memleak
...
Fix memory leak in `sync/chan`
2024-04-27 08:37:52 +01:00
Feoramund
92402a75f6
Fix wrong llvm-config in build script for FreeBSD
2024-04-26 18:40:59 -04:00
gingerBill
4bea5dbac1
Correct map usage
2024-04-26 15:09:08 +01:00
gingerBill
2b26384b89
Implement dumb PtrMap
2024-04-26 15:04:46 +01:00
gingerBill
c685b404ea
Implement dumb StringMap
2024-04-26 14:15:22 +01:00
gingerBill
a3e77dcc3b
Minor clean up
2024-04-26 13:25:08 +01:00
gingerBill
7305478261
Minor changes
2024-04-26 13:12:23 +01:00
gingerBill
94e0707456
Fix minor bug
2024-04-26 13:12:15 +01:00
Feoramund
f95bb77f72
Fix memory leak in sync/chan
2024-04-26 05:19:52 -04:00
Andreas T Jonsson
6bbdbb4447
Added missing core:sys/info package for NetBSD
2024-04-26 11:04:27 +02:00
Andreas T Jonsson
22fa420c4f
Should pass 0 as the rest of futex arguments
2024-04-25 22:22:59 +02:00
Andreas T Jonsson
9a008d10f3
Merge branch 'master' into netbsd
2024-04-25 22:04:40 +02:00
Andreas T Jonsson
3000508c02
Switched to native futex on NetBSD
2024-04-25 21:50:34 +02:00
Laytan Laats
d3bd1c2110
improve some Negative_Read/Negative_Write logic
...
Returns the actual error if one is set, instead of swallowing it for the
less descriptive negative error.
Also fixes a out-of-bounds slice error in `bufio.writer_write` because
it wasn't checking the returned `m`.
2024-04-25 19:08:48 +02:00
gingerBill
f745fff640
Merge pull request #3467 from laytan/clang-18-linking-backport
...
fix linking with clang-18
2024-04-25 16:09:17 +01:00
Andreas T Jonsson
c1ff7894df
Should only run BSD tests
2024-04-25 13:47:55 +02:00
gingerBill
8f4e3b552e
Merge pull request #3478 from laytan/fix-send-event-proc-signature
...
sys/darwin/foundation: fix Application->sendEvent signature
2024-04-25 12:32:10 +01:00
gingerBill
1ea353dbf7
Merge pull request #3479 from laytan/support-0-sized-return-arm64-abi
...
compiler: support returning 0 sized types in arm64 abi
2024-04-25 12:31:56 +01:00
Andreas T Jonsson
b6eaadb9a8
Fixed invalid git path
2024-04-25 13:31:33 +02:00
Andreas T Jonsson
f53abf736b
Print the path of the git safe directory
2024-04-25 13:25:46 +02:00
Andreas T Jonsson
4c9c0899a9
Added git safe directory config
2024-04-25 13:14:09 +02:00
Andreas T Jonsson
2b8836e29a
Fixed broken export
2024-04-25 13:03:19 +02:00
Andreas T Jonsson
101abb3004
Simple CI setup for NetBSD
2024-04-25 12:46:55 +02:00
Andreas T Jonsson
ce80c37c75
Fixed potential memory leak
2024-04-25 11:04:44 +02:00
Andreas T Jonsson
642391eb49
Implemented absolute_path_from_handle for NetBSD
2024-04-25 09:45:28 +02:00
Andreas T Jonsson
8ffe577a15
Added missing build tags in core
2024-04-25 09:43:54 +02:00
gingerBill
e3d41f0a9e
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-04-24 20:55:22 +01:00
gingerBill
3b53c99576
Improve support for big-endian bit_fields
2024-04-24 20:55:18 +01:00
Laytan Laats
a4cec2e8b8
sys/darwin/foundation: fix Application->sendEvent signature
2024-04-24 19:51:08 +02:00
Laytan Laats
e8c5bb4629
compiler: support returning 0 sized types in arm64 abi
2024-04-24 19:50:39 +02:00
gingerBill
c72a269b7c
Merge pull request #3477 from laytan/fix-macos-versions
...
ci: fix macOS versions
2024-04-24 17:48:45 +01:00
gingerBill
94d35d9918
Disallow mixing endian types within a bit_field
2024-04-24 17:31:31 +01:00
Laytan Laats
448827c0e4
ci: fix macOS versions
2024-04-24 18:29:28 +02:00
gingerBill
04278cd654
Remove line info in message with -json-errors
2024-04-24 17:13:53 +01:00
gingerBill
15942fbf25
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-04-24 17:01:16 +01:00
gingerBill
214537b420
Improve codegen for bit_field [N]T compound literals
2024-04-24 17:01:09 +01:00
gingerBill
c330e5b5c1
Improve codegen for bit_field compound literals with an integer backing
2024-04-24 14:46:34 +01:00
PucklaJ
a2ad66cd9d
[sys/linux]: Add clone syscall and use it in fork for arm64
2024-04-24 15:32:43 +02:00
PucklaJ
2bf00d9b3f
[sys/linux]: Add flags parameter to execveat and fix execve on arm64
2024-04-24 15:15:38 +02:00
gingerBill
ec5a84a537
Improve code generation for loading bit_field fields
2024-04-24 13:10:58 +01:00
gingerBill
5b6c96cd18
Merge pull request #3466 from laytan/fix-proc-args-debug-info
...
fix direct proc args debug info
2024-04-23 13:07:25 +01:00
Yawning Angel
e2fa9be7e2
core/math/rand: Use core:crypto for the system RNG
...
This removes some code duplication and expands support for the system
RNG to all targets that `core:crypto` supports.
2024-04-23 11:47:43 +09:00
Yawning Angel
a6eb64df6c
core/crypto: Add a HAS_RAND_BYTES constant
2024-04-23 11:47:43 +09:00
alec hodgkinson
3b632b4d90
Fixed typo in raylib documentation
2024-04-22 15:13:52 -07:00
Feoramund
9cdb7b2584
Fix discrepancy with pthread cancelability state
2024-04-22 17:16:33 -04:00
Laytan
d1a1e8f646
fix linking with clang-18
...
Because we currently just use the clang from the user's path linking
suddenly breaks when the user updates their system clang to 18 with an
error about an unknown option -arch.
I had already fixed it for my LLVM 18 PR but it seems like a good idea
to get this in already to avoid that breakage (had a few people come to
the Discord with it and an issue).
This fixes #3461
2024-04-22 20:58:54 +02:00
gingerBill
75fcd50b9a
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-04-22 18:41:51 +01:00
gingerBill
c6a446fe87
Add check for build. and run. typos
2024-04-22 18:41:48 +01:00
Laytan Laats
90369b669b
fix direct proc args debug info
2024-04-22 19:36:24 +02:00
gingerBill
f5719ae47c
Merge pull request #3465 from thetarnav/fmt-printfln-js
...
Add printfln and eprintfln procs to fmt_js.odin
2024-04-22 16:01:36 +01:00
Andreas T Jonsson
384137d4e9
Use PHYSMEM64 on NetBSD
...
I realize we should use PHYSMEM64 on NetBSD. So we can not share code with FreeBSD.
2024-04-22 10:15:52 +02:00
Andreas T Jonsson
1b15d8b453
Added build tag
...
Added build tag to rand_bsd.odin and fixed build warning.
2024-04-22 09:32:19 +02:00
Damian Tarnawski
2a70faca14
Add printfln and eprintfln functions to fmt_js.odin
2024-04-21 22:37:04 +02:00
Yawning Angel
902e877467
repo: Add more test binaries to .gitignore
2024-04-21 21:22:05 +09:00
Jeroen van Rijn
caa8863c97
Merge pull request #3455 from Hyrtwol/normalize-path
...
Normalize ODIN_ROOT path
2024-04-20 12:08:12 +02:00
Thomas la Cour
ebb1a07dd0
spelling
2024-04-20 09:37:30 +02:00
Thomas la Cour
0a16f7a6f1
normalize_path
2024-04-20 09:37:30 +02:00
gingerBill
3620e62ff7
Merge pull request #3453 from GoNZooo/gonz.add-nosignal-broken-pipe
...
fix(net/linux): add `NOSIGNAL` to `send` options
2024-04-19 14:05:49 +01:00
gingerBill
d84b29866f
Merge pull request #3447 from matias-eduardo/fix-soa-hash-formatting
...
fix #soa '%#v' formatting
2024-04-19 14:05:15 +01:00
Andreas T Jonsson
50cbb802b7
Fixed bug report information for NetBSD
2024-04-19 14:44:35 +02:00
Rickard Andersson
68f663ea85
fix(net): fix return type for send_tcp
...
Was `.Connection_Closed` but this is only inferrable if our return type
is not a sub-union of another.
2024-04-19 15:39:04 +03:00
Rickard Andersson
efc84cd390
docs(net): add comment about EPIPE -> Connection_Closed
2024-04-19 15:37:20 +03:00
gingerBill
ea49331799
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-04-19 13:33:02 +01:00
gingerBill
059175de3b
Do not print column of a runtime.Source_Code_Location if the column == 0
2024-04-19 13:32:55 +01:00
Rickard Andersson
7b95562827
feat(net): turn EPIPE into Connection_Closed
2024-04-19 15:29:28 +03:00
Rickard Andersson
c44f618b7d
fix(net): add NOSIGNAL to send options
...
This is a better default than not having it, since it turns errors that
would be signals into error values instead. We could take these as
options but given that we currently don't I think this at the very least
improves on the status quo.
2024-04-19 15:17:21 +03:00
joakin
60ef4fda4d
Recognize dynamic library names like libraylib.so.5.0.0
2024-04-19 13:35:53 +02:00
Andreas T Jonsson
a23c378513
Make the linter happy
2024-04-19 12:32:09 +02:00
Andreas T Jonsson
dd95a8d11d
More std lib fixes
...
Just selecting the same codepath as other BSD's for the most part.
2024-04-19 10:42:09 +02:00
Jeroen van Rijn
1b143b9fa3
Merge pull request #3452 from mgavioli/Fix_i18n_get-section_number_default
...
Fix #3451 - `core:text/i18n` default `number` value in `get_*_section`
2024-04-19 09:24:17 +02:00
Maurizio M. Gavioli
ec7e75a57f
Fix #3451 - core:text/i18n default number value in get_*_section proc.
...
In the to procs `get_single_section()` and `get_by_section()` the `number` parameter should have a default of `1` rather than `0`.
See the issue for more details.
2024-04-19 08:23:28 +02:00
gingerBill
20223345a4
Return partial reads
2024-04-19 00:33:31 +01:00
gingerBill
3812d5e002
Only override the comma value on *_init if it is "invalid"
2024-04-19 00:19:02 +01:00
Andreas T Jonsson
07fc07822d
Added some libc bindings for NetBSD
2024-04-18 16:22:07 +02:00
Andreas T Jonsson
41d4dfbcd5
Fixed concurrency issue
...
Fixed broken thread policy causing deadlocks.
2024-04-18 16:20:49 +02:00
gingerBill
2416380f34
Enforce as global constant
2024-04-18 12:56:18 +01:00
gingerBill
5200e3fe7a
Set __$ti- stuff to be private linkage
2024-04-18 12:45:20 +01:00
gingerBill
b72d49ceb5
Set linkage to private for __$type_info_data
2024-04-18 12:41:05 +01:00
gingerBill
689982a38d
Force runtime type table to be in rodata/rdata section
2024-04-18 12:22:41 +01:00
gingerBill
334e08c750
Update numerous package declaration names
2024-04-18 12:17:39 +01:00
gingerBill
f84a092977
Fix typo.
2024-04-18 11:28:46 +01:00
gingerBill
aad41fc762
Fix #3445
2024-04-18 11:27:42 +01:00
gingerBill
ece78d22d2
Add -no-type-assert and ODIN_NO_TYPE_ASSERT
2024-04-18 11:22:31 +01:00
gingerBill
5c52f3cf2f
Add ODIN_NO_BOUNDS_CHECK
2024-04-18 11:13:44 +01:00
gingerBill
889cd5461c
Add @(optimization_mode="size") to runtime.print_type
2024-04-18 11:00:47 +01:00
gingerBill
6127339c56
Add #force_no_inline to many of the runtime print procedures
2024-04-18 10:59:02 +01:00
Andreas T Jonsson
38640d5d9e
Updated core lib and did cleanup
...
Updated core with some path related functions and did some minor code cleanup.
Most of the standard library function is just a matter of copy what is there for the other BSDs.
2024-04-18 10:12:42 +02:00
Matias Fernandez
e296b050ee
fix #soa '%#v' formatting
2024-04-17 22:54:30 -04:00
gingerBill
9bbe26f80f
Merge pull request #3441 from Chickenkeeper/copy-from-string-docs-fix
...
Correct `copy_from_string` docs
2024-04-17 13:50:08 +01:00
gingerBill
7cd2bc26f4
Clear error message on collisions with using on struct fields
2024-04-17 13:31:32 +01:00
Andreas T Jonsson
2055f2b933
Fixed link warnings
...
Hardlink libc functions to the correct version on NetBSD 10 since we do not use the micro-magic from C.
2024-04-17 09:46:57 +02:00
Andreas T Jonsson
80067a959b
Added thread name
...
Call pthread_setname_np with the correct number of arguments on NetBSD.
2024-04-17 09:42:41 +02:00
Chris
6dcf38b85b
Correct copy_from_string docs
2024-04-16 21:36:54 +01:00
gingerBill
a61ae7c861
Fix #3427
2024-04-16 13:31:49 +01:00
Andreas T Jonsson
4558f3992a
Initial commit of NetBSD port
2024-04-16 14:27:29 +02:00
gingerBill
8a0f9ae108
Print to string buffer before printing errors
2024-04-16 13:15:23 +01:00
Jeroen van Rijn
fd1eb17771
Merge pull request #3437 from Feoramund/fisher-yates-shuffle
...
Implement Fisher-Yates shuffle
2024-04-16 10:28:35 +02:00
Feoramund
3e449e93dd
Implement Fisher-Yates shuffle
2024-04-15 17:07:05 -04:00
Jeroen van Rijn
436c5dc40c
Merge pull request #3436 from karl-zylinski/fix-vet-unused-in-dynlib
...
Fix for dynlib:initialize_symbols not passing -vet-unused
2024-04-15 21:55:12 +02:00
Karl Zylinski
0729f2b4fb
Fix for dynlib:initialize_symbols not passing -vet-unused
2024-04-15 21:26:30 +02:00
gingerBill
76229cabfa
Fix typo
2024-04-15 15:44:03 +01:00
gingerBill
a7e492e2c2
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-04-15 15:40:43 +01:00
gingerBill
69db9c6390
Add loads of nil checks when doing s.builder
2024-04-15 15:40:32 +01:00
Jeroen van Rijn
6def86bb4b
Merge pull request #3431 from Feoramund/fix-randprime-2ndmsb
...
Fix `big.internal_random_prime` with `Second_MSB_On`
2024-04-15 16:30:16 +02:00
gingerBill
38c1fd5824
Keep -vet happy
2024-04-15 14:35:51 +01:00
gingerBill
d5e6d722d3
Merge pull request #3045 from laytan/cbor
...
encoding/cbor
2024-04-15 14:28:52 +01:00
gingerBill
2af777b6cb
Merge pull request #3419 from puzzleddev/fixup-d3d12-thiscall-affected-methods
...
Fixup vendor/d3d12 calling convention mistakes
2024-04-15 13:19:19 +01:00
gingerBill
5bda2546f7
Merge branch 'master' of https://github.com/odin-lang/Odin
2024-04-15 12:43:50 +01:00
gingerBill
36644a3c09
Add template specialization for compared against "" with String internally
2024-04-15 12:43:45 +01:00
gingerBill
7e582dd671
Add basic suggestion to missing package name
2024-04-15 12:43:27 +01:00
gingerBill
c7ac28f6a1
Merge pull request #3434 from flysand7/sys-linux-fixes
...
[sys/linux]: Fix syscall calls for open and fstat
2024-04-15 12:28:59 +01:00
flysand7
4bfa1ea76c
[sys/linux]: Fix syscall calls for open and fstat
2024-04-15 22:16:03 +11:00
gingerBill
758ace844c
Merge pull request #3428 from mgavioli/fix_core_docs
...
Fix the format of some `doc.odin` files of the `core` library…
2024-04-15 12:12:20 +01:00
gingerBill
b9d7b8d616
Merge pull request #3429 from flysand7/sys-linux-wait4-fix
...
[sys/linux]: Fix signature on wait4 syscall
2024-04-15 11:51:51 +01:00
Feoramund
a294f067a9
Fix big.internal_random_prime with Second_MSB_On
2024-04-15 05:49:15 -04:00
gingerBill
2e29687cee
Fix #3425
2024-04-15 10:28:14 +01:00
flysand7
a0e25be196
[sys/linux]: Fix signature on wait4 syscall
2024-04-15 11:16:52 +11:00
Maurizio M. Gavioli
a0cff82320
Fix the format of some doc.odin files of the core library which did not made into the documentation.
...
`c/frontend/tokenizer`:
add proper "Example:" header to demo example code,
removed empty lines.
`container/bit_array`:
moved comment before package;
aligned narrative lines to left margin;
converted case lines into bulleted lines ("- ");
converted individual examples to single-tab-indented preformatted text.
`dynlib`:
removed "//+build ignore" line;
added newline at EOF.
`image/netpmb`:
converted indented lines of "Reading", "Wrting" and "Some syntax..." into bulleted lists;
"Formats" indented lines kept as they are as the preformatted text seems relevant to keep the alignments;
doubly indented lines kept as single-indented to keep them different (as the format does not allow for two-level bulleted lists);
removed empy lines.
`os/os2`: WIP, not modified
`sys/info`:
removed "//+build ignore" line;
converted tab-indented initial description into regular left-margin comment;
moved uncommented sample code within the doc comment as an "Example:";
moved simple- and double-tabbed separate comments with sample Windows and macOS outputs within the doc comment as bulleted headlines with preformatted output listings;
removed now empty comments and blank lines after the package line.
`text/i18n`:
removed "//+build ignore" line;
moved the pacakge line at the end;
de-indented the tab-indented introductory narrative;
moved sample code comments into the doc comment as tab-indented code with a proper "Example:" heading;
removed "```" MD attempts at code formatting.
`text/table`:
unindented the comment lines of a descriptive kind;
headlines of major subdivisions are marked as bold;
kept code samples as tab-indented preformatted text (as there are several of them, the standard "Example:" and "Output:" headings cannot be used) removing the "```" MD attempts at code formatting;
removed in-between blank lines.
2024-04-14 17:18:08 +02:00
Jeroen van Rijn
d510d5e49f
Merge pull request #3426 from Kelimion/crlf
...
Tell Git to always treat Makefile and build_odin.sh as Nix EOL
2024-04-14 16:51:42 +02:00
Jeroen van Rijn
9591eb2ed5
Tell Git to always treat Makefile and build_odin.sh as Nix EOL
2024-04-14 16:41:10 +02:00
gingerBill
21969fec61
Merge pull request #3421 from laytan/add-odin-root-command
...
add `odin root` command
2024-04-13 22:44:53 +01:00
gingerBill
6ee818b394
Merge pull request #3422 from wrapperup/add-dxc-vendor-docs
...
Add dxc to all_vendor.odin, fix dxc build on freebsd/openbsd
2024-04-13 22:42:03 +01:00
wrapperup
b22e43c335
add freebsd, openbsd to dxcdef_unix.odin
2024-04-13 15:27:02 -04:00
gingerBill
6dc9fdb718
Merge pull request #3420 from laytan/fix-wasm-runtime-store-string-with-unicode
...
fix wasm runtime.js storeString to support Unicode
2024-04-13 20:15:41 +01:00
wrapperup
f252084b1f
add dxc to all_vendor.odin
2024-04-13 15:05:51 -04:00
Laytan Laats
9f97056c14
add 'odin root' command
2024-04-13 20:08:57 +02:00
Laytan Laats
d2ca91b830
fix wasm runtime.js storeString to support Unicode
2024-04-13 19:34:13 +02:00
gingerBill
59705035f9
Merge pull request #3365 from yay/core-foundation-security
...
Core Foundation and Security core packages.
2024-04-13 10:56:24 +01:00
Vitalii Kravchenko
befb0f7868
Core Foundation and Security vendor libraries.
2024-04-13 00:11:42 +01:00
tim4242
d5bb67e9e6
Fixup vendor/d3d12 calling convention mistakes
2024-04-12 20:47:02 +02:00
Jeroen van Rijn
f086b4710a
Merge pull request #3418 from blob1807/add-url-fragment-to-split-join-url
...
core:net Add support for URL fragments
2024-04-12 17:19:29 +02:00
blob1807
a4d16e97a1
Fix CI's parser
2024-04-13 01:14:55 +10:00
blob1807
6348b56c8b
Move rounded tests
2024-04-13 00:57:36 +10:00
blob1807
2d1260bec9
uniformity change
...
small change to check things uniform
2024-04-13 00:47:49 +10:00
blob1807
c753711d86
Added support for URL fragments
...
Added support for a URL's fragment/anchor to `split_url` & `join_url` in `core:net` plus 4 new tests to cover it.
2024-04-13 00:39:32 +10:00
gingerBill
5726b7d954
Remove warning on clang
2024-04-12 14:51:22 +01:00
gingerBill
4240e0025e
Improve scalar -> array assignment when the scalar is constant in LLVM
2024-04-12 14:20:46 +01:00
gingerBill
caa344c88d
Simplify scalar -> array conversions in LLVM to use a loop after a certain size
2024-04-12 14:05:36 +01:00
gingerBill
46b9bd8c0e
Improve error messages for switch and for r-values with a suggestion
2024-04-12 13:35:14 +01:00
gingerBill
3426af2d6c
Fix #3415
2024-04-12 12:33:25 +01:00
gingerBill
efc3f9916e
Fix #3414
2024-04-12 12:30:16 +01:00
Jeroen van Rijn
95bc1892f5
Merge pull request #3413 from hodgka/trig_funcs_doc
...
Added docs for trig function procedure groups
2024-04-11 19:02:41 +02:00
alec hodgkinson
4cdadeedc3
Added docs for trig function procedure groups
2024-04-11 09:55:43 -07:00
gingerBill
cb0a57eaa9
Add -target:freestanding_amd64_win64
2024-04-11 17:18:51 +01:00
Arseniy Poroshin
77a0e50298
fix comments in core:container/queue.
2024-03-26 22:39:43 +00:00
Beau McCartney
43e8da2e06
shm_open: comment with notes abt permissions
2024-03-19 09:36:49 -06:00
Beau McCartney
1758bd683e
sys_shm_open: fchmod the returned descriptor to get correct perms
...
this doesn't happen by default
2024-03-16 12:13:00 -06:00
Eric Johnson
4b7f32c287
Update mem doc example formatting
2024-03-15 12:26:01 -07:00
Beau McCartney
24f9e16dfd
sys_open() calls _sys_open_mode() to get a permission flags integer
...
_sys_open_mode() does exactly what sys_open() was originally doing
inline, I simply factored it into a separate function so that other
wrappers could call it (similar to _sys_permission_mode())
2024-03-15 08:32:25 -06:00
Beau McCartney
56a29685b4
darwin: sys_shm_open() helper
...
wraps syscall_shm_open() in the same way that sys_open() wraps
syscall_open()
2024-03-15 08:27:27 -06:00
Beau McCartney
cf949e541f
helper function to convert Open_Flags bitset to a u32
...
- analagous to _sys_permission_mode()
- uses the already-existing conversion logic in sys_open()
2024-03-15 08:26:25 -06:00
Beau McCartney
44167800ad
darwin: syscall wrappers for shm_open() and shm_unlink()
2024-03-15 08:26:03 -06:00
olesya-wo
51a4d97f03
type conversion fix
2024-03-12 18:25:54 +03:00
olesya-wo
d979129a50
Naming and type changes
2024-03-12 16:32:17 +03:00
olesya-wo
9045c9ed0c
Improved statistics for core/mem/Tracking_Allocator
2024-03-12 13:53:31 +03:00
Laytan Laats
9a5f3fed8c
encoding/cbor: fix conflict
2024-03-04 17:29:30 +01:00
Laytan Laats
04bd3cc525
encoding/cbor: rename diagnose to to_diagnostic_format to be clearer
2024-03-04 17:26:19 +01:00
Laytan
9fc8587e2c
encoding/cbor: untouch net/common.odin
2024-03-04 17:26:19 +01:00
Laytan
2a39c60fe4
encoding/cbor: respect default to panic allocator
2024-03-04 17:26:19 +01:00
Laytan
b11d839fb6
encoding/cbor: make temp allocations more explicit
2024-03-04 17:26:19 +01:00
Laytan
0076c07076
encoding/cbor: core -> base
2024-03-04 17:26:19 +01:00
Laytan
a664d9804f
encoding/cbor: remove usage of incl_elem and excl_elem
2024-03-04 17:26:19 +01:00
Laytan Laats
c4e45d509a
encoding/cbor: adhere to new quaternion rules of master
2024-03-04 17:26:19 +01:00
Laytan Laats
c1cf6c1a95
encoding/cbor: add general docs and example
2024-03-04 17:26:19 +01:00
Laytan Laats
317931a3c5
encoding/cbor: deterministically store bit sets as big endian
2024-03-04 17:26:19 +01:00
Laytan Laats
759d095548
encoding/cbor: ignore struct fields with cbor:"-"
2024-03-04 17:26:19 +01:00
Laytan Laats
7854aa22d9
encoding/cbor: fix unused import
2024-03-04 17:26:19 +01:00
Laytan Laats
72d5b87b52
encoding/cbor: clean
2024-03-04 17:26:19 +01:00
Laytan Laats
154e0d41c6
encoding/cbor: fix wrong allocator bug
2024-03-04 17:26:19 +01:00
Laytan Laats
3fccc77829
encoding/cbor: clean and fixup some allocations
2024-03-04 17:26:19 +01:00
Laytan Laats
85f1a60cf3
encoding/cbor: cleanup comments about tags
2024-03-04 17:26:19 +01:00
Laytan Laats
cb8bb8bfd8
encoding/cbor: cleanup default temp allocator
2024-03-04 17:26:19 +01:00
Laytan Laats
46b58ad48d
encoding/cbor: don't zero bytes we are going to write/read to/from anyway
2024-03-04 17:26:19 +01:00
Laytan Laats
7283b5e75c
encoding/cbor: minor things
2024-03-04 17:26:19 +01:00
Laytan Laats
21e6e28a3a
encoding/cbor: add decoder flags and protect from malicious untrusted input
2024-03-04 17:26:19 +01:00
Laytan Laats
d77ae9abab
encoding/cbor: fully support marshal/unmarshal of unions
2024-03-04 17:26:19 +01:00
Laytan Laats
363769d4d3
encoding/cbor: cleanup base64 tag
2024-03-04 17:26:19 +01:00
Laytan Laats
b6c47e7963
encoding/base64: add decode_into, add tests
2024-03-04 17:26:17 +01:00
Laytan Laats
5533a327eb
encoding/cbor: initial package implementation
2024-03-04 17:25:34 +01:00
marcs feh
9c6574e053
Merge branch 'odin-lang:master' into master
2024-02-11 23:55:39 +00:00
marcs feh
fc113315f6
Merge branch 'odin-lang:master' into master
2024-02-02 21:56:40 -03:00
marcs-feh
d931bfcf83
resolve conflict
2024-01-26 16:23:16 -03:00
marcs-feh
b58627490b
Adjust signture + Fix rebase conflict
2024-01-26 12:10:15 -03:00
marcs feh
dbaa82b581
Merge branch 'odin-lang:master' into master
2024-01-24 20:10:44 -03:00
marcs-feh
84123cc879
sys/linux: Adjust ioctl signature to fit the actual Linux Kernel implementation
2024-01-24 13:40:50 -03:00
marcs-feh
7b1f58a06a
sys/linux: Add binding to ioctl syscall + fd consts
...
Add binding to ioctl syscall, due to the vast nature of this syscall
adding more device specific request values is possible. Also added the
stdin, stdout and stderr, to constants.odin
2024-01-22 16:09:44 -03:00
jakubtomsu
fe268a9dd2
Add nullptr check back
2023-11-25 13:29:28 +01:00
jakubtomsu
3c25d93eae
Check for variadic param default val
2023-11-25 13:20:34 +01:00