translate-c: support brace-enclosed string initializers (c++20 9.4.2.1)
This commit is contained in:
committed by
Veikka Tuominen
parent
bc8e1e1de4
commit
42ee364e7b
@@ -3956,4 +3956,10 @@ pub fn addCases(cases: *tests.TranslateCContext) void {
|
||||
\\ .name = "foo",
|
||||
\\});
|
||||
});
|
||||
|
||||
cases.add("string array initializer",
|
||||
\\static const char foo[] = {"bar"};
|
||||
, &[_][]const u8{
|
||||
\\pub const foo: [3:0]u8 = "bar";
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user