diff --git a/doc/langref.html.in b/doc/langref.html.in index e028cb8349..074c324de7 100644 --- a/doc/langref.html.in +++ b/doc/langref.html.in @@ -624,11 +624,6 @@ void Used for type-erased pointers. - - {#syntax#}void{#endsyntax#} - (none) - Always the value {#syntax#}void{}{#endsyntax#} - {#syntax#}noreturn{#endsyntax#} (none) @@ -1806,25 +1801,6 @@ const together = array1 ++ array2; mem.eql(u32, &together, &[_]u32{1,2,3,4}){#endsyntax#} - - Array Multiplication -
{#syntax#}a ** b{#endsyntax#}
- - - - - - - -
{#syntax#}const mem = @import("std").mem;
-const pattern = "ab" ** 3;
-mem.eql(u8, pattern, "ababab"){#endsyntax#}
- - Pointer Dereference
{#syntax#}a.*{#endsyntax#}
@@ -1882,7 +1858,7 @@ const B = error{Two}; a!b x{} !x -x -%x ~x &x ?x -* / % ** *% *| || +* / % *% *| || + - ++ +% -% +| -| << >> <<| & ^ | orelse catch @@ -2371,7 +2347,7 @@ or

Like arrays, tuples have a .len field, can be indexed (provided the index is comptime-known) - and work with the ++ and ** operators. They can also be iterated over with {#link|inline for#}. + and work with the ++ operator. They can also be iterated over with {#link|inline for#}.

{#code|test_tuples.zig#} @@ -2571,7 +2547,7 @@ or {#header_close#} {#header_open|Empty Blocks#} -

An empty block is equivalent to {#syntax#}void{}{#endsyntax#}:

+

An empty block returns the single value of type {#syntax#}void{#endsyntax#}:

{#code|test_empty_block.zig#} {#header_close#} @@ -3159,10 +3135,6 @@ fn createFoo(param: i32) !Foo { the verbosity and cognitive overhead of trying to make sure every exit path is covered. The deallocation code is always directly following the allocation code.

-

- The {#syntax#}errdefer{#endsyntax#} statement can optionally capture the error: -

- {#code|test_errdefer_capture.zig#} {#header_close#}

A couple of other tidbits about error handling: @@ -3627,7 +3599,7 @@ void do_a_thing(struct Foo *foo) {

For some types, {#link|@sizeOf#} is 0: