Vexu
6dde769279
Simplify stores, use sext for signed ints
2020-03-12 22:02:58 +02:00
Vexu
ce19638cd4
disable test on mipsel
2020-03-12 17:31:10 +02:00
Vexu
710b05b153
support @atomicRmw at comptime
2020-03-12 16:46:16 +02:00
Vexu
9262f065f5
Move abi size checking to codegen
2020-03-11 16:48:18 +02:00
Vexu
ec906a9771
fix codegen, update docs
2020-03-11 13:55:52 +02:00
Vexu
1f66435a6b
support cmpxchg at comptime
2020-03-11 12:02:05 +02:00
Vexu
64e60d8ae2
special case atomic operations on zero bit types
2020-03-11 10:29:15 +02:00
Vexu
21809c3300
support non power of two integers in atomic ops
2020-03-11 09:24:53 +02:00
Vexu
ee5b00a8b9
use atomic bools in std lib
2020-03-10 22:54:47 +02:00
Vexu
8dc188ebe0
support atomic operations with bools
2020-03-10 22:33:32 +02:00
Andrew Kelley
675f01f176
Merge pull request #4590 from xackus/fix-4587
...
fix failed assert on generic fn opaque return type
2020-03-09 22:10:57 -04:00
LemonBoy
1f44b29724
ir: Fix codegen of ?*T types where T is zero-sized
...
* Fix codegen for optional types that decay to a pointer, the type
behaves as a boolean
* Fix comptime evaluation of zero-sized arrays, always initialize the
internal array elements
Closes #4673
2020-03-09 22:08:56 -04:00
Andrew Kelley
638d5c3aca
Merge pull request #4700 from Vexu/noasync
...
Implement new noasync syntax
2020-03-09 18:36:01 -04:00
xackus
e7cc456421
better error messages and more tests
2020-03-09 22:33:18 +01:00
Andrew Kelley
52c01840ce
Merge branch 'LemonBoy-fix-4527'
...
closes #4531
2020-03-09 14:24:51 -04:00
Andrew Kelley
7db6da7cb8
lazy_cmp_zero only resolves type is zero bits for alignof
2020-03-09 14:24:04 -04:00
LemonBoy
14bbb82832
ir: Fix lazy comparison between @alignOf and zero
...
Closes #4527
2020-03-09 14:05:38 -04:00
daurnimator
648f94c027
std: add some definitions for netlink sockets
2020-03-09 13:02:38 -04:00
Andrew Kelley
6ab156ce7d
Merge pull request #4695 from leroycep/feature-inode-stat
...
Expose file inode number on posix and file index on windows
2020-03-09 13:01:26 -04:00
Ryan Liptak
9b1b44b41c
Windows: Fix std.fs.realpath/os.realpathW for directories
2020-03-09 12:59:17 -04:00
Vexu
3fd2cd4367
add LemonBoy's test
2020-03-09 18:43:09 +02:00
Vexu
03c1431f9c
disallow resume and suspend in noasync scopes
2020-03-09 15:51:51 +02:00
Vexu
3618256c97
implement noasync scopes
2020-03-09 12:33:24 +02:00
Vexu
6f8d732599
update parsers to new noasync syntax
2020-03-09 12:23:30 +02:00
LeRoyce Pearson
25d9ab95dd
Use os.ino_t for everything
...
Also, define ino_t for windows
2020-03-08 21:52:36 -06:00
LeRoyce Pearson
cb84875eed
Define ino_t for systems not yet defining it
...
Also, use ino_t instead of u64 in fs.File.INode
2020-03-08 18:31:18 -06:00
LemonBoy
e2fd289a33
ir: Create usize result_loc for array subscript expr
...
Allow the subscript expression to infer the resulting type.
Closes #4169
2020-03-08 18:52:44 -04:00
LemonBoy
06d0dac0fb
ir: Prevent crash in compiler error
...
Anonymous containers have no struct_field->type AstNode set, let's
always use the field node itself to make the error messages consistent.
Closes #4691
2020-03-08 18:12:50 -04:00
LeRoyce Pearson
e1c1ca9903
Add documentation about Stat.inode
2020-03-08 15:47:50 -06:00
LeRoyce Pearson
55077435bf
Expose file inode (linux) and file index (windows)
2020-03-08 15:19:02 -06:00
xackus
7782c76bee
fix failed assert on generic fn opaque return type
2020-03-08 18:05:45 +01:00
Andrew Kelley
f90fe1f8f2
Merge pull request #4687 from daurnimator/fix-typo
...
Fix grammar from "C pointers cannot point opaque types"
2020-03-08 12:44:56 -04:00
Andrew Kelley
a5cb19c0ac
Merge pull request #4690 from Vexu/translate-c
...
Translate-c fixes
2020-03-08 12:43:49 -04:00
LemonBoy
2b1316954f
std: One more cpuid fix
...
Don't read from stale eax value, rework the logic a bit so that's clear
what's going on.
2020-03-08 12:43:32 -04:00
Vexu
692a974c3e
translate-c reject structs with VLAs
2020-03-08 12:11:37 +02:00
Vexu
5aa993cd61
translate-c fix nested loops without blocks.
2020-03-08 11:26:53 +02:00
daurnimator
c8050a931c
Strip trailing whitespace from src/ir.cpp
2020-03-08 19:18:25 +11:00
daurnimator
b85bb152bf
Fix grammar in error message
2020-03-08 19:18:06 +11:00
Andrew Kelley
9e60c89601
Revert "Translate C: Group generated casts"
...
This reverts commit 895672b3f96aab1f5bad3446f5186a047f29412c.
2020-03-08 03:53:06 -04:00
Andrew Kelley
8b80cb3072
Revert "translate-c remove redundant grouping, fix nested loops without blocks."
...
This reverts commit abe7305e169be2047d65f96e6525d3828684f058.
2020-03-08 03:52:52 -04:00
Jared Miller
cf38ce9701
Implement UTF-8 to UTF-16LE literal conversion
2020-03-07 19:21:28 -05:00
Andrew Kelley
6ac76bc25e
add missing errors to std.os.windows.CreateDirectoryError
2020-03-07 19:13:21 -05:00
Andrew Kelley
0720f338d4
add std.event.Loop pread and faccessat
...
progress towards std lib tests passing with evented I/O mode
2020-03-07 19:13:21 -05:00
LemonBoy
c5885f012a
std: Fix version detection on x86
...
Call xgetbv only if X{SAVE,RESTORE} and AVX are detected.
Closes #4670
2020-03-07 18:53:34 -05:00
Andrew Kelley
c25d9417d3
fix std.fs.makeDirAbsolute
...
closes #4671
2020-03-07 15:14:47 -05:00
Vexu
abe7305e16
translate-c remove redundant grouping, fix nested loops without blocks.
2020-03-07 12:14:44 -05:00
Lachlan Easton
895672b3f9
Translate C: Group generated casts
...
Translate C: Put an alignCast in c style pointer casts to allow opaque types to cast properly in C macros
Translate C: add test case for aligning opaque types in pointer casts
Translate C: Fix @typeId -> @typeInfo
Add test case to run_translated_c for casting from pointer to opaque type
2020-03-07 03:26:42 -05:00
Andrew Kelley
80ff549e26
fix detectNativeCpuAndFeatures including foreign asm
2020-03-06 21:03:23 -05:00
Andrew Kelley
54799ccaf8
Merge branch 'alichay-master'
...
Closes #4627
2020-03-06 20:47:34 -05:00
Andrew Kelley
e0d5f94a70
simplify the inline assembly
2020-03-06 20:02:08 -05:00