Commit Graph

5207 Commits

Author SHA1 Message Date
Andrew Kelley
06435535d3
fixes for darwin 2019-05-27 14:12:50 -04:00
Andrew Kelley
f1610f6c1d
nanosleep: move windows logic to std.time 2019-05-27 12:16:32 -04:00
Andrew Kelley
abf959a0c9
fix debug builds of WASI 2019-05-27 02:16:05 -04:00
Andrew Kelley
fda7e0bb01
std lib fixes for zig build on windows 2019-05-27 02:00:39 -04:00
Andrew Kelley
129714d077
more fixes for windows and wasi 2019-05-27 01:35:58 -04:00
Andrew Kelley
6be79d79aa
fixes for Windows and WASI 2019-05-27 00:48:56 -04:00
Andrew Kelley
0c6ab61b22
tests passing on linux 2019-05-26 23:35:26 -04:00
Andrew Kelley
2b42e910bf
behavior tests passing on Linux 2019-05-26 19:56:37 -04:00
Andrew Kelley
44a049e01e
more cleanup. down to just the @hasDecl builtin 2019-05-26 18:32:45 -04:00
Andrew Kelley
2f040a23c8
clean up references to os 2019-05-26 18:32:44 -04:00
Andrew Kelley
7cb6279ac0
clean up references to posix 2019-05-26 18:32:44 -04:00
Andrew Kelley
ca6debcaf4
starting to fix the regressions 2019-05-26 18:32:44 -04:00
Andrew Kelley
3d61e42282
rename "posix" to "bits" 2019-05-26 18:32:44 -04:00
Andrew Kelley
17b0166e00
do Jay's suggestion with posix/os API naming & layout 2019-05-26 18:32:44 -04:00
Andrew Kelley
2def23063f
more progress. moving windows API layer to its own file 2019-05-26 18:32:44 -04:00
Andrew Kelley
daae7e1f5a
more progress on posix API layer
see #2380
2019-05-26 18:32:43 -04:00
Andrew Kelley
67726e36b0
extract posix functions from std/os.zig to std/os/posix.zig
See #2380
2019-05-26 18:32:40 -04:00
Andrew Kelley
df7aa9a4f0
allow implicit optional pointer to optional c_void pointer 2019-05-26 17:55:20 -04:00
Andrew Kelley
269a53b6af
introduce @hasDecl builtin function
closes #1439
2019-05-26 16:21:03 -04:00
Andrew Kelley
21ed939117
support enum literals implicit casting to tagged unions 2019-05-26 12:59:30 -04:00
Sahnvour
99ee0608f7 gen-h: do not output visibility macros when the build is static 2019-05-25 14:17:59 +02:00
Sahnvour
c89b522233 test: slightly better output for failure of tests based on text comparison 2019-05-25 13:43:52 +02:00
LemonBoy
86b3007b94
Reject slices in use expressions
Co-Authored-By: emekoi <emekankurumeh@outlook.com>
2019-05-24 13:20:44 +02:00
Shritesh Bhattarai
b618a0b866 doc: wasm: embedded->host 2019-05-22 09:37:37 -07:00
Shritesh Bhattarai
9e65a144fa docs: clarify why wasm_allocator should be used 2019-05-22 07:43:17 -07:00
LemonBoy
f67ca20655 Make use work with arbitrary structs 2019-05-21 17:07:40 +02:00
LemonBoy
7987202243 Fix signedness mismatch in comparison 2019-05-20 23:14:49 +02:00
LemonBoy
266b2de150 Remove macos-specific linking hacks 2019-05-20 23:09:25 +02:00
LemonBoy
f5657b5552 Build archives using the K_DARWIN format when targeting osx 2019-05-20 17:04:00 +02:00
Marc Tiehuis
163a8e98bc std.fmt.parse_float: Fix exponent calculation
This was incorrectly translated as a u64. binary_exponent is an
unadjusted value so can be negative. In becomes unconditionally positive
when adding the bias.
2019-05-20 17:28:17 +12:00
Shritesh Bhattarai
3b6fc3fdc7 docs: wasm 2019-05-19 19:32:28 -07:00
emekoi
1c73c08298 ran zig fmt on stdlib 2019-05-19 16:33:31 -04:00
LemonBoy
6672ee9eb3 Fix too eager comptime evaluation of error ptr 2019-05-19 15:53:32 -04:00
LemonBoy
b660134a18 Use the correct scope for use
use expressions outside the top-level scope now work as intended.
2019-05-19 00:32:49 -04:00
Andrew Kelley
860684cc2f
Merge pull request #2516 from LemonBoy/32bfix
More 32bit fixes for stdlib
2019-05-19 00:31:16 -04:00
LemonBoy
0a3aec020a Fix load/store of non-integer fields in packed struct 2019-05-18 19:59:47 -04:00
LemonBoy
232bc1bdee Remove more 64bit-centric assumptions from stdlib 2019-05-18 11:08:04 +02:00
LemonBoy
6957927194 Fix some test cases to run on 32bit systems 2019-05-18 10:59:56 +02:00
LemonBoy
51aaa02679 VDSO calls must use the C CC 2019-05-16 22:10:38 -04:00
Andrew Kelley
2eba779af5
stage1 tokenizer: add more missing break statements 2019-05-16 16:50:24 -04:00
SamTebbs33
87901baa28 Add break after digit_value check in TokenizeStateCharCode 2019-05-16 16:49:26 -04:00
Andrew Kelley
e09c05f689
Merge branch 'shawnl-builtins' 2019-05-16 16:38:06 -04:00
Andrew Kelley
80983ca1ca
fixups to the previous commit 2019-05-16 16:37:58 -04:00
Shawn Landden
1fdb24827f
breaking changes to all bit manipulation intrinsics
* `@clz`, `@ctz`, `@popCount`, `@bswap`, `@bitreverse` now
   have a type parameter
 * rename @bitreverse to @bitReverse
 * rename @bswap to @byteSwap

Closes #2119
Closes #2120
2019-05-16 16:37:58 -04:00
Shritesh Bhattarai
56a905c7d1 docgen: add lib codeblock type and use it for wasm32-freestanding 2019-05-16 14:58:10 -04:00
Andrew Kelley
8468ff0fe1
Merge pull request #2507 from ziglang/wasm-libs
improvements to build-lib use case of WebAssembly
2019-05-16 14:31:54 -04:00
Andrew Kelley
978fab817c
the wasm freestanding _start function is return value void 2019-05-16 14:19:13 -04:00
Andrew Kelley
81e960eb74
improvements to build-lib use case of WebAssembly
* build-exe does include the startup code that supplies _start for the
   wasm32-freestanding target. Previously this did not occur because
   of logic excluding "freestanding".
 * build-lib for wasm32-freestanding target gets linked by LLD. To avoid
   infinite recursion, compiler_rt and zig libc are built as objects
   rather than libraries.
   - no "lib" prefix and ".wasm" extension instead of ".a". Rather than
   build-lib foo.zig producing "libfoo.a", now it produces "foo.wasm".
 * go back to using `.o` extension for webassembly objects
 * zig libc only provides _start symbol for wasm when linking libc.
2019-05-16 13:56:56 -04:00
Andrew Kelley
07d0aee11a
clang C API wrapper: small progress 2019-05-16 12:55:45 -04:00
daurnimator
e30cd800e2 std: update linux syscalls to 5.1 2019-05-16 12:38:40 -04:00