zig/test/behavior/usingnamespace.zig
Andrew Kelley 332eafeb7f stage2: first pass at implementing usingnamespace
Ran into a design flaw here which will need to get solved by having
AstGen annotate ZIR with which instructions are closed over.
2021-09-01 17:54:06 -07:00

14 lines
194 B
Zig

const std = @import("std");
const A = struct {
pub const B = bool;
};
const C = struct {
usingnamespace A;
};
test "basic usingnamespace" {
try std.testing.expect(C.B == bool);
}