cuelang.org/go@v0.10.1/cue/testdata/compile/json.txtar (about)

     1  #noformat
     2  Issue #721
     3  
     4  -- in.cue --
     5  // allow front-style commas
     6  a
     7  : { "key": "value"
     8  , "key2"
     9  : "value2"
    10  }
    11  
    12  , b: [
    13      0
    14  ,   1
    15  ,       2
    16          ,3,
    17      4
    18  
    19      , 5
    20  ]
    21  -- out/compile --
    22  --- in.cue
    23  {
    24    a: {
    25      key: "value"
    26      key2: "value2"
    27    }
    28    b: [
    29      0,
    30      1,
    31      2,
    32      3,
    33      4,
    34      5,
    35    ]
    36  }
    37  -- out/eval/stats --
    38  Leaks:  0
    39  Freed:  11
    40  Reused: 8
    41  Allocs: 3
    42  Retain: 0
    43  
    44  Unifications: 11
    45  Conjuncts:    11
    46  Disjuncts:    11
    47  -- out/eval --
    48  (struct){
    49    a: (struct){
    50      key: (string){ "value" }
    51      key2: (string){ "value2" }
    52    }
    53    b: (#list){
    54      0: (int){ 0 }
    55      1: (int){ 1 }
    56      2: (int){ 2 }
    57      3: (int){ 3 }
    58      4: (int){ 4 }
    59      5: (int){ 5 }
    60    }
    61  }