Robin Voetter
073289d0da
spirv: disable new behavior tests that do not pass
...
Some new behavior tests have recently been added, and not all of these
pass with the SPIR-V backend.
2023-07-01 19:45:09 +02:00
Loris Cro
97a1b046ea
autodoc: fix scoring bug when matching full decl name
2023-07-01 17:38:18 +02:00
Emile Badenhorst
35a8e8a06c
Fixed Autodoc rendering of @truncate builtin ( #16263 )
...
* fixed autodoc rendering of @trucate builtin
* Changed to LHS for typeRef
* autodoc: fix typeref for `truncate`
---------
Co-authored-by: Loris Cro <kappaloris@gmail.com>
2023-07-01 16:43:17 +02:00
Robin Voetter
aa398034eb
testing: disable printing for targets that do not support it
...
The SPIR-V cannot print the helpful error messages from the
std.testing module. This commit overrides the default print
function used here to one that only prints if the target supports
it. For now, its only done for SPIR-V, but this function could
be adapted to more targets that need it.
2023-07-01 14:29:11 +02:00
Robin Voetter
74f40ddd11
spirv: enable simplified default panic handler
...
SPIR-V cannot print, so we cannot yet use the fancy default
panic handler. Instead we will just use the infinite loop
one for now.
2023-07-01 14:27:57 +02:00
Robin Voetter
8eee392862
spirv: fix up todos & errors from intern pool changes
...
This replaces the implementation of constant() which one that
is directly based on the intern pool rather than the Zig type tag
too.
2023-07-01 14:27:12 +02:00
Jacob Young
f571438fc0
Unrevert "Sema: preserve extern struct field alignment"
...
This unreverts commit 1a2468abfcd8b539193d943c1eefb71319cc7b88.
2023-06-30 23:24:52 -04:00
Jacob Young
2282c27885
Remerge pull request #15995 from mlugg/fix/union-field-ptr-align
...
Sema: copy pointer alignment to union field pointers
This is an unrevert of 43c98dc11567eeb38be041c7dad179c53156f3df.
2023-06-30 23:23:26 -04:00
mlugg
402b958e19
std.pdb: fix incorrect field alignment in ptrCast
2023-06-30 23:23:03 -04:00
mlugg
730f2e0407
Sema: copy pointer alignment to struct field pointers
2023-06-30 23:23:03 -04:00
mlugg
5b594139d9
Sema: copy pointer alignment to union field pointers
...
This implements the semantics as discussed in today's compiler meeting,
where the alignment of pointers to fields of default-layout unions
cannot exceed the field's alignment.
Resolves : #15878
2023-06-30 23:23:01 -04:00
Ryan Liptak
2eae013378
fs.path: Fix Windows path component comparison being ASCII-only
...
We can use eqlIgnoreCaseUtf8 to get Unicode-aware Windows-compliant case insensitive path component comparison
2023-06-30 15:29:43 -07:00
Ryan Liptak
cfcf9cd9b7
Add os.windows.nls.upcaseW, a cross-platform implementation of RtlUpcaseUnicodeChar
...
This allows doing Windows-style case insensitive comparisons from any target, but means that it will need to include its own copy of the uppercase data table (5,088 bytes) to do so.
When targeting Windows, the ntdll functions are used instead to avoid including a redundant copy of the uppercase data in the resulting binary.
2023-06-30 15:29:43 -07:00
Evan Haas
0a6cd257b9
translate-c: Use @constCast and @volatileCast to remove CV-qualifiers
...
Instead of converting a pointer to an int and then back to a pointer.
2023-06-29 23:36:56 +03:00
Michael Dusan
614bc6755e
openbsd: add root certificate scanning
...
patch by @bilaliscarioth, thank you!
closes #16168
2023-06-29 10:29:28 -07:00
Jacob Young
43c98dc115
Revert "Merge pull request #15995 from mlugg/fix/union-field-ptr-align"
...
This reverts commit 40cf3f7ae5fbfb84b7af6b27e6296ee858b209ef, reversing
changes made to d98147414d084bc41b00ba9c0be8c7b82ad4e76c.
2023-06-29 00:23:19 -04:00
Jacob Young
1a2468abfc
Revert "Sema: preserve extern struct field alignment"
...
This reverts commit 4620972d086ebb3b7686a79914876488c6dfd171.
2023-06-29 00:23:19 -04:00
Evan Haas
77dcd903a0
langref: Add c_char to the list of primitive types
2023-06-28 17:35:22 -07:00
Lauri Tirkkonen
82520a214c
std.crypto.hash.sha2: require avx2 on x86_64
...
according to
https://www.intel.com/content/www/us/en/docs/intrinsics-guide/index.html#text=vpalignr&ig_expand=283,283,284,283,283&techs=AVX_ALL
the vpalignr instruction requires AVX2 support
2023-06-28 17:33:02 -07:00
Krzysztof Wolicki
0c1bfe271e
autodoc: Correct a comment about types from std.builtin
2023-06-28 19:03:24 +02:00
Krzysztof Wolicki
2984a75804
autodoc: Try to handle all InternPool.Index types good enough
2023-06-28 19:03:24 +02:00
Ian Johnson
4dacaa1e12
Autodoc: add preference for / search
...
Closes #16081
2023-06-28 18:16:16 +02:00
Bertie Wheen
7166407d8f
langref: correct ordering of @xFromY builtins
2023-06-28 17:38:41 +03:00
Alex Kladov
4620972d08
Sema: preserve extern struct field alignment
...
In
extern struct { x: u32, y: u16 }
we actually know that y's alignment is `@alignOf(u32)`, and not just
`@alignOf(u16)`.
closes : #16134
2023-06-28 16:36:32 +02:00
zooster
28f515acd7
behavior: test slicing array of zero-sized values
...
Closes #15343
2023-06-28 14:00:18 +03:00
Motiejus Jakštys
910ad92e0e
ld: support -version-script
...
gettext uses this version and, surely enough, it is supported by lld
2023-06-28 09:32:10 +02:00
r00ster91
adf0718316
behavior: boolean vector with 2 or more elements
...
Closes #12169
2023-06-27 19:57:23 -04:00
r00ster91
d01641f6be
test cases: fix typo in filename
2023-06-27 19:57:23 -04:00
r00ster91
2cc9c99ebf
behavior: if-@as-if chain
...
Closes #8952
2023-06-27 19:57:23 -04:00
r00ster91
c647799e5e
test cases: expected optional type in for loop
...
Closes #10674
2023-06-27 19:57:23 -04:00
r00ster91
5e9fe84d24
test cases: array inside of anonymous struct
...
Closes #7525
2023-06-27 19:57:23 -04:00
r00ster91
10218dd096
test cases: never-inline call of inline function with comptime parameter
...
Closes #5995
2023-06-27 19:57:23 -04:00
r00ster91
18fe951e24
test cases: returning undefined [:0]const u8
...
Closes #5947
2023-06-27 19:57:23 -04:00
r00ster91
78da0e40a8
test cases: taking pointer of global tagged union
...
Closes #11619
2023-06-27 19:57:23 -04:00
r00ster91
413a86f7eb
behavior: correct alignment for elements and slices of aligned array
...
Closes #11751
2023-06-27 19:57:23 -04:00
r00ster91
c040c0f45a
test cases: @intCast on vector
...
Closes #11770
2023-06-27 19:57:19 -04:00
r00ster91
2463f4df77
addrspace: small cleanups
2023-06-27 19:50:17 -04:00
r00ster91
8385b2c379
Sema.analyzeBodyInner: fix some spaces
2023-06-27 19:50:17 -04:00
r00ster91
40e002ae2b
std.builtin.StackTrace: don't print extra newline after stack trace
2023-06-27 19:49:54 -04:00
r00ster91
7213234f0c
test cases: taking address of extern var as constant
...
Closes #5344
2023-06-27 19:08:27 -04:00
r00ster91
d10456eb8d
test cases: maximum sized integer literal
...
Closes #12116
2023-06-27 19:08:27 -04:00
r00ster91
11c32c756f
fix u65529 and above overflowing in more places
...
See also #15537
2023-06-27 19:08:24 -04:00
Krzysztof Wolicki
5804f3f757
autodoc: walkResultTypeRef returns Zig's undefined instead of 0th type
2023-06-27 19:07:39 +02:00
Krzysztof Wolicki
7f648c297e
autodoc: Added u0, i0 to correctly indexed types
2023-06-27 19:07:39 +02:00
Luuk de Gram
622c5f3200
Merge pull request #16207 from Luukdegram/wasi-threads
...
WASI: Implement experimental threading support
2023-06-27 18:28:26 +02:00
mlugg
ff37ccd298
Air: store interned values in Air.Inst.Ref
...
Previously, interned values were represented as AIR instructions using
the `interned` tag. Now, the AIR ref directly encodes the InternPool
index. The encoding works as follows:
* If the ref matches one of the static values, it corresponds to the same InternPool index.
* Otherwise, if the MSB is 0, the ref corresponds to an InternPool index.
* Otherwise, if the MSB is 1, the ref corresponds to an AIR instruction index (after removing the MSB).
Note that since most static InternPool indices are low values (the
exceptions being `.none` and `.var_args_param_type`), the first rule is
almost a nop.
2023-06-27 01:21:32 -07:00
yujiri8
dae516dbdf
improve documentation of std.sort.*Context functions ( #16145 )
2023-06-27 00:51:06 -07:00
Jacob Young
d881d841ed
Sema: use tmp_hack_arena as a temporary solution for lifetime issues
...
All of this code is expected to get rewritten anyway.
Closes #16216
2023-06-27 00:46:31 -07:00
Andrew Kelley
d9e867172e
Merge pull request #16233 from jacobly0/tls
...
crypto.tls.Client: fix occasional crash in `readvAdvanced`
2023-06-27 00:45:49 -07:00
Jacob Young
9343c31c38
Sema: fix @min/@max type resolution with all runtime args
...
Closes #16229
2023-06-26 18:46:25 -07:00