summaryrefslogtreecommitdiff
path: root/test/initializer.myr
blob: 7f18806952843da47e67c0c8bda4756034fb75e0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use std

pkg =
    type qid = struct
        ty  : uint8
        path    : uint64
    ;;

    type stat = struct
        dev : uint32
        qid : qid
    ;;
;;

const main = {
    var stat : stat = [.dev=0, .qid=[.ty=0, .path=0]]
    std.assert(stat.qid.path == 0, "fail\n")
}