update std lib to decls being disallowed between fields
This commit is contained in:
@@ -1,3 +1,18 @@
|
||||
test "zig fmt: decl between fields" {
|
||||
try testError(
|
||||
\\const S = struct {
|
||||
\\ const foo = 2;
|
||||
\\ const bar = 2;
|
||||
\\ const baz = 2;
|
||||
\\ a: usize,
|
||||
\\ const foo1 = 2;
|
||||
\\ const bar1 = 2;
|
||||
\\ const baz1 = 2;
|
||||
\\ b: usize,
|
||||
\\};
|
||||
);
|
||||
}
|
||||
|
||||
test "zig fmt: errdefer with payload" {
|
||||
try testCanonical(
|
||||
\\pub fn main() anyerror!void {
|
||||
@@ -2001,11 +2016,11 @@ test "zig fmt: struct declaration" {
|
||||
\\ f1: u8,
|
||||
\\ f3: u8,
|
||||
\\
|
||||
\\ f2: u8,
|
||||
\\
|
||||
\\ fn method(self: *Self) Self {
|
||||
\\ return self.*;
|
||||
\\ }
|
||||
\\
|
||||
\\ f2: u8,
|
||||
\\};
|
||||
\\
|
||||
\\const Ps = packed struct {
|
||||
|
||||
Reference in New Issue
Block a user