Jimmi Holst Christensen
8139c5a516
New Zig formal grammar ( #1685 )
...
Reverted #1628 and changed the grammar+parser of the language to not allow certain expr where types are expected
2018-11-13 05:08:37 -08:00
Andrew Kelley
2b395d4ede
remove @minValue,@maxValue; add std.math.minInt,maxInt
...
closes #1466
closes #1476
2018-10-26 15:01:51 -04:00
Jimmi Holst Christensen
378d3e4403
Solve the return type ambiguity ( #1628 )
...
Changed container and initializer syntax
* <container> { ... } -> <container> . { ... }
* <exrp> { ... } -> <expr> . { ...}
2018-10-15 09:51:15 -04:00
Andrew Kelley
3e72411db0
C ABI and compiler rt improvements for ARM
...
* add __multi3 compiler rt function. See #1290
* compiler rt includes ARM functions for thumb and aarch64 and
other sub-arches left out. See #1526
* support C ABI for returning structs on ARM. see #1481
2018-10-13 15:18:00 -04:00
Andrew Kelley
84690ee05e
std/special/bootstrap: inline some functions to improve stack traces
2018-10-09 13:16:50 -04:00
Andrew Kelley
5a3c02137e
support building static libraries
...
closes #1493
closes #54
2018-10-09 13:15:14 -04:00
Andrew Kelley
d40c4e7c89
Merge pull request #1429 from shawnl/arm64
...
initial arm64 support
2018-10-06 00:11:39 -04:00
Andrew Kelley
9d4eaf1e07
update std lib API for I/O
...
std.io.FileInStream -> std.os.File.InStream
std.io.FileInStream.init(file) -> file.inStream()
std.io.FileOutStream -> std.os.File.OutStream
std.io.FileOutStream.init(file) -> file.outStream()
remove a lot of error code possibilities from os functions
std.event.net.socketRead -> std.event.net.read
std.event.net.socketWrite -> std.event.net.write
add std.event.net.readv
add std.event.net.writev
add std.event.net.readvPosix
add std.event.net.writevPosix
add std.event.net.OutStream
add std.event.net.InStream
add std.event.io.InStream
add std.event.io.OutStream
2018-09-30 17:28:35 -04:00
Andrew Kelley
4c6f1e614a
remove `zig build --init`. add `zig init-lib` and `zig init-exe`
...
init-lib creates a working static library with tests, and
init-exe creates a working hello world with a `run` target.
both now have test coverage with the new "cli tests" file.
closes #1035
2018-09-17 17:11:18 -04:00
Shawn Landden
17cb69cebc
fix elf auxv handling
...
Auxillery vectors are not guaranteed to be in any order, this
just happens to work on x86_64.
2018-09-08 14:47:21 +00:00
Shawn Landden
cba0d76fbc
clone() on arm64
2018-09-08 03:52:28 +00:00
Shawn Landden
342cff28f5
initial arm64 support
2018-09-08 03:52:28 +00:00
Andrew Kelley
832caefc2a
fix regressions
2018-09-02 18:35:32 -04:00
Andrew Kelley
c4b9466da7
Merge pull request #1294 from ziglang/async-fs
...
introduce std.event.fs for async file system functions
2018-08-10 15:51:17 -04:00
Andrea Orru
d2f5e57b68
Merge branch 'master' into zen_stdlib
2018-08-06 01:43:19 -04:00
Andrew Kelley
5dfcd09e49
self-hosted: watch files and trigger a rebuild
2018-08-03 17:22:17 -04:00
Andrew Kelley
4d9964a457
rename error.skip to error.SkipZigTest
...
also print stats at the end of test runner
2018-07-21 23:43:43 -04:00
kristopher tate
df574ccf86
std.special.test_runner.zig: make tests skippable;
...
tracking issue #1274 ;
tests can be skipped by returnning `error.skip` :
2018-07-22 02:20:03 +09:00
Andrew Kelley
3f4d0ecd7e
Merge remote-tracking branch 'origin/master' into m-n-threading
2018-07-09 17:14:42 -04:00
Andrew Kelley
a0c564d762
zig fmt
2018-07-09 01:23:47 -04:00
Andrew Kelley
ced3aae3b2
cleaner output from zig build when there are compile errors
2018-07-07 20:31:50 -04:00
Marc Tiehuis
1eda86e1ad
Clean up outstanding compiler_rt todos
2018-07-03 13:22:12 +12:00
Andrew Kelley
bd282d6cca
Merge pull request #1176 from bnoordhuis/f16-std
...
improve std.math f16 support
2018-07-02 16:03:25 -04:00
Marc Tiehuis
887c97742f
Alignment fix and allow rudimentary f128 float printing
2018-06-30 21:58:59 +12:00
Marc Tiehuis
9f48b2ab48
compiler_rt: Remove wrapping add/sub operators where unneeded
...
Closes #495 .
2018-06-30 21:58:59 +12:00
Marc Tiehuis
814a34f263
compiler_rt: Add floattitf/floattidf/floattisf
2018-06-30 21:58:59 +12:00
Marc Tiehuis
e19fc4a0a3
compiler_rt: Add missing exports
2018-06-30 21:58:59 +12:00
Marc Tiehuis
cb7bdc2da1
compiler_rt: Add floatuntitf
2018-06-30 21:58:59 +12:00
Marc Tiehuis
61ebfe6603
compiler_rt: Add floatunditf and floatunsitf
2018-06-30 21:58:59 +12:00
Marc Tiehuis
c32b2e45ef
compiler_rt: Add floatuntisf
2018-06-30 21:58:59 +12:00
Marc Tiehuis
379950f81d
compiler_rt: Add trunc f128 narrowing functions
2018-06-30 21:58:59 +12:00
Ben Noordhuis
27b02413dc
add std.math f16 nan support
...
refs #1122
2018-06-30 01:58:17 +02:00
Ben Noordhuis
fd75e73ee9
add f16 type
...
Add support for half-precision floating point operations.
Introduce `__extendhfsf2` and `__truncsfhf2` in std/special/compiler_rt.
Add `__gnu_h2f_ieee` and `__gnu_f2h_ieee` as aliases that are used in
Windows builds.
The logic in std/special/compiler_rt/extendXfYf2.zig has been reworked
and can now operate on 16 bits floating point types.
`extendXfYf2()` and `truncXfYf2()` are marked `inline` to work around
a not entirely understood stack alignment issue on Windows when calling
the f16 versions of the builtins.
closes #1122
2018-06-27 16:20:04 +02:00
Andrew Kelley
5f38d6e2e9
add casting docs, __extenddftf2, and __extendsftf2
2018-06-21 14:44:35 -04:00
Andrew Kelley
c7804277bf
`@floatToInt` now has safety-checked undefined behavior
...
when the integer part does not fit in the destination integer type
* Also fix incorrect safety triggered for integer casting an
`i32` to a `u7`. closes #1138
* adds compiler-rt function: `__floatuntidf`
2018-06-19 16:06:10 -04:00
Andrew Kelley
4210f1f6a0
remove bool to int syntax. add @boolToInt
...
add missing docs
See #1061
2018-06-18 03:07:16 -04:00
Andrew Kelley
7912061226
remove integer and float casting syntax
...
* add `@intCast`
* add `@floatCast`
* add `@floatToInt`
* add `@intToFloat`
See #1061
2018-06-17 02:57:07 -04:00
Marc Tiehuis
a369d69c51
Add windows x86_64 i128 abi workaround
2018-06-14 21:18:36 +12:00
Marc Tiehuis
9110140514
Add i128 compiler-rt div/mul support
2018-06-13 22:25:04 +12:00
Andrew Kelley
77678b2cbc
breaking syntax change: orelse keyword instead of ?? ( #1096 )
...
use the `zig-fmt-optional-default` branch to have zig fmt
automatically do the changes.
closes #1023
2018-06-10 01:13:51 -04:00
Andrew Kelley
ec1b6f6673
breaking syntax change: ??x to x.? ( #1095 )
...
See #1023
This also renames Nullable/Maybe to Optional
2018-06-09 23:42:14 -04:00
Andrew Kelley
bd13e757e7
disable deref syntax for unknown length pointers
...
See #770
2018-06-05 23:26:43 -04:00
Andrew Kelley
d21a1922eb
support `zig fmt: off` and `zig fmt: on` between top level decls
...
closes #1030
closes #1033
2018-06-04 12:15:02 -04:00
Andrew Kelley
96164ce613
disallow single-item pointer indexing
...
add pointer arithmetic for unknown length pointer
2018-06-04 01:39:57 -04:00
Andrew Kelley
7b386ea242
fix build file template
...
See #1035
2018-06-01 21:51:54 -04:00
Andrew Kelley
fcbb7426fa
use * for pointer type instead of &
...
See #770
To help automatically translate code, see the
zig-fmt-pointer-reform-2 branch.
This will convert all & into *. Due to the syntax
ambiguity (which is why we are making this change),
even address-of & will turn into *, so you'll have
to manually fix thes instances. You will be guaranteed
to get compile errors for them - expected 'type', found 'foo'
2018-05-31 17:28:07 -04:00
Andrew Kelley
ea58f4a5a9
run zig fmt on the codebase
2018-05-30 16:09:11 -04:00
Andrew Kelley
0c16cd2d0e
run zig fmt on the codebase
...
See #1003
2018-05-29 04:23:38 -04:00
Andrew Kelley
43085417be
update github.com/zig-lang to github.com/ziglang
2018-05-24 21:27:44 -04:00
Andrew Kelley
6928badd85
Merge branch 'master' into pointer-reform
2018-05-09 23:43:07 -04:00