aboutsummaryrefslogtreecommitdiff
path: root/std/cstr.zig
diff options
context:
space:
mode:
authorJimmi Holst Christensen <jimmiholstchristensen@gmail.com>2018-11-13 05:08:37 -0800
committerGitHub <noreply@github.com>2018-11-13 05:08:37 -0800
commit8139c5a516eaa217ed76acdf09496895451c5c5c (patch)
tree89841cec818c5650471c7f2c11141013f8640bf7 /std/cstr.zig
parent67fbb0434f7104801c66e821b5057a8323e377df (diff)
downloadzig-8139c5a516eaa217ed76acdf09496895451c5c5c.tar.gz
zig-8139c5a516eaa217ed76acdf09496895451c5c5c.zip
New Zig formal grammar (#1685)
Reverted #1628 and changed the grammar+parser of the language to not allow certain expr where types are expected
Diffstat (limited to 'std/cstr.zig')
-rw-r--r--std/cstr.zig4
1 files changed, 2 insertions, 2 deletions
diff --git a/std/cstr.zig b/std/cstr.zig
index 2ddf899b24..a8aaf21279 100644
--- a/std/cstr.zig
+++ b/std/cstr.zig
@@ -55,7 +55,7 @@ pub fn addNullByte(allocator: *mem.Allocator, slice: []const u8) ![]u8 {
return result;
}
-pub const NullTerminated2DArray = struct.{
+pub const NullTerminated2DArray = struct {
allocator: *mem.Allocator,
byte_count: usize,
ptr: ?[*]?[*]u8,
@@ -95,7 +95,7 @@ pub const NullTerminated2DArray = struct.{
}
index_buf[i] = null;
- return NullTerminated2DArray.{
+ return NullTerminated2DArray{
.allocator = allocator,
.byte_count = byte_count,
.ptr = @ptrCast(?[*]?[*]u8, buf.ptr),