Commit Graph

5018 Commits

Author SHA1 Message Date
gingerBill 4458ca4585 Fix #4126 2024-08-24 11:40:02 +01: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
Jeroen van Rijn 1bcc074223 dash 2024-08-21 14:18:12 +02:00
Jeroen van Rijn 6b4b0cea5d Add table-driven (in)definite article to some errors. 2024-08-20 22:13:31 +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
gingerBill 2a0785037b Fix switch val in ptr 2024-08-19 12:19:45 +01: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 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 Laats b2e64b7ce0 implement lshrti3 on wasm 2024-08-18 17:09:57 +02: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 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 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
FourteenBrush 12813e5d48 Fix 'odin [run|test] --' giving a compiler out of bounds 2024-08-14 21:37:40 +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 324d9c2284 Fix doc writer bug caused by using an iterator rather than a for loop 2024-08-14 13:02:23 +01:00
gingerBill fd5376ba88 Allow @(require_results) on foreign blocks 2024-08-14 11:28:49 +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
Davi 4bb51249d1 Error if assigning to rodata variable with index 2024-08-13 23:28:34 -03:00
Laytan Laats efe68c2e24 posix: add package 2024-08-14 01:44:35 +02:00
Laytan Laats ac68a9d52c update MacOS releases 2024-08-14 00:00:50 +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 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
Laytan Laats a1d518442a fix type hint propogation for shift
Fixes #3856
2024-08-12 23:39:07 +02: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 Laats f22ff21039 fix max alignments 2024-08-12 17:05:51 +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 Laats 99aa0d3a35 fix type switching over internal pointer union
Fixes #3947
2024-08-12 00:02:05 +02:00
Laytan Laats e3f375afd8 fix c_vararg bit_set
Fixes #4051
2024-08-11 17:00:49 +02:00
Laytan Laats f5fe0de0fd add clarity for diverging mismatch error 2024-08-10 23:34:35 +02:00
Laytan Laats 6918d8aaa6 possibly fix init_core_type_info race condition 2024-08-10 21:03:40 +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 2bf055ec6e Delete empty file after access check. 2024-08-07 19:38:36 +02: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