Michael Raymond
de9933761c
std.zig.render: fix newlines before DocComments
2020-03-29 22:41:39 -04:00
Andrew Kelley
13d04f9963
Merge pull request #4741 from momumi/master
...
allow `_` separators in number literals (stage 1)
2020-03-23 00:54:54 -04:00
momumi
2d18178c27
minor fixes and more tests for _ separators
...
* Make the tokenizer spit out an Invalid token on the first invalid
character found in the number literal.
* More parsing and tokenizer tests for number literals
* fix invalid switch statement in ir.zig
2020-03-23 09:21:34 +10:00
LemonBoy
28dbc58837
Address review comments
2020-03-21 09:54:49 +01:00
LemonBoy
128e70ff3a
ir: Allow errdefer with payload
...
Closes #1265
2020-03-21 09:54:49 +01:00
LemonBoy
11a4ce42c1
zig fmt: Respect trailing commas in error set declarations
...
The logic is not perfect as it doesn't take into account the presence of
doc comments, but it's an improvement over the status quo.
2020-03-18 11:15:22 -04:00
Andrew Kelley
18f1fef142
update standard library to new I/O streams API
2020-03-10 18:44:30 -04:00
Vexu
1ad831a0ef
fix zig fmt on noasync block
2020-03-10 15:27:11 -04:00
Vexu
45da72c5b6
remove usages of @typeId, @memberCount, @memberName and @memberType
2020-02-24 23:09:01 +02:00
LemonBoy
95a71e29f8
zig fmt: Fix callconv rewriting for extern + string
...
Closes #4473
2020-02-18 18:18:15 -05:00
Andrew Kelley
cb3a818699
zig fmt: support noasync await
2020-02-16 01:44:52 -05:00
Benjamin Feng
699c50a375
Switch a bunch of FBA to use testing.allocator
2020-02-12 17:17:56 -06:00
LemonBoy
1658becb62
fmt: Fix one more edge case in container formatting
2020-02-03 16:03:48 -05:00
LemonBoy
e548195fd5
fmt: Use left brace position instead of the right one
...
Fix a typo and add a test case.
2020-02-01 15:28:23 +01:00
LemonBoy
f34abbf260
fmt: Handle declarations in line with the opening brace
2020-02-01 14:43:31 +01:00
LemonBoy
8309ee8752
fmt: Respect trailing comma for field declarations
...
Closes #4349
2020-02-01 11:28:21 +01:00
LemonBoy
dee7804a81
fmt: Fix logic to find the argument list closing )
...
Closes #4341
2020-01-31 18:25:58 -05:00
Benjamin Feng
0c137934cb
Move FailingAllocator to testing
2020-01-29 17:38:42 -06:00
Vexu
0ea96c11ef
disallow multiline strings in test and library names
2020-01-15 14:20:48 -05:00
Vexu
af2ede4d96
fix crash on multiline library name
2020-01-14 13:10:52 -05:00
xackus
f81529fab1
stage2 parser: fix segfault on extern block
2020-01-10 22:35:41 +01:00
Andrew Kelley
5951b79af4
remove stdcallcc, extern, nakedcc from stage1; zig fmt rewrites
2020-01-06 15:23:05 -05:00
Andrew Kelley
0a9daeb37e
Merge branch 'cc-work' of https://github.com/LemonBoy/zig into LemonBoy-cc-work
2020-01-06 14:07:56 -05:00
LemonBoy
e6485282d3
Better logic for last-param rendering
2020-01-03 11:49:42 +01:00
LemonBoy
7b375a1c4a
Revert "Revert "Trailing comma is respected for builtin calls""
...
This reverts commit f83411b0b1b857c7f8679e3b90d2093ba60621d4.
2020-01-03 10:17:40 +01:00
Andrew Kelley
f83411b0b1
Revert "Trailing comma is respected for builtin calls"
...
This reverts commit afd029091854358e6e88cfc4cbb524022f4ec136.
This caused test failures.
2020-01-02 21:53:25 -05:00
LemonBoy
afd0290918
Trailing comma is respected for builtin calls
2020-01-02 16:43:39 -05:00
LemonBoy
e99209baf0
Add transform test
2020-01-02 18:57:08 +01:00
LemonBoy
563d9ebfe5
Implement the callconv() annotation
2020-01-02 18:53:16 +01:00
Andrew Kelley
290dc5d95b
zig fmt support for slice sentinel syntax
2019-12-21 14:03:36 -05:00
Robin Voetter
8c096707b7
Additional replacements of @typeOf with @TypeOf
2019-12-10 11:09:41 -05:00
Robin Voetter
23b901d45a
Add typeOf/TypeOf render test
2019-12-10 11:09:29 -05:00
Andrew Kelley
8b2622cdd5
std.fmt.format: tuple parameter instead of var args
2019-12-08 22:53:51 -05:00
Andrew Kelley
64d700bfa6
zig fmt: support comptime fields
2019-12-08 12:26:20 -05:00
Vexu
10cc8cad86
fix zig fmt of c pointers
2019-12-05 14:50:46 +02:00
LemonBoy
26c8930b95
Accept comptime-known expression for asm
2019-12-02 19:53:06 -05:00
Andrew Kelley
8a4c2d3b07
zig fmt fixes for sentinel-terminated pointers
...
closes #3771
2019-11-25 13:53:06 -05:00
Andrew Kelley
7597735bad
update the stage1 implementation to the new proposal
...
See #3731
2019-11-23 04:45:35 -05:00
Andrew Kelley
fd6020c4e2
update tests, better error messages, update self-hosted tokenizer
2019-11-21 20:43:41 -05:00
Andrew Kelley
21f344b3b9
add null terminated pointers and arrays to self-hosted
...
as well as `@typeInfo` and `@Type`
2019-11-21 20:43:41 -05:00
Andrew Kelley
57b8614a5a
Merge pull request #3697 from Vexu/container-docs
...
Implement container level doc comments
2019-11-17 22:31:12 +00:00
Vexu
6cddf9d723
properly parse anon literal in array
2019-11-17 22:24:21 +00:00
Vexu
b92f42d1f4
implemented container doc comments in stage 2
2019-11-14 16:25:06 +02:00
Andrew Kelley
0237e7a701
std.io.getStdOut and related fns no longer can error
...
Thanks to the Windows Process Environment Block, it is possible to
obtain handles to the standard input, output, and error streams without
possibility of failure.
2019-11-13 04:01:40 +00:00
Andrew Kelley
d4e6a6d5e2
zig fmt: support anon struct and anon list init syntax
2019-11-11 13:12:45 -05:00
Andrew Kelley
ae0a219d1f
stop accepting deprecated use keyword
...
closes #2591
2019-11-11 13:02:39 -05:00
Andrew Kelley
e0db54e89d
update the codebase to use @as
2019-11-08 15:57:24 -05:00
Vexu
2550cb4638
remove pub syntax for container fields
2019-10-21 23:04:19 -04:00
Vexu
7495fd8cb9
fix struct align fmt
2019-10-15 17:58:02 -04:00
Andrew Kelley
ed36dbbd9c
mv std/ lib/
...
that's all this commit does. further commits will fix cli flags and
such.
see #2221
2019-09-25 23:35:41 -04:00