cuelang.org/go@v0.13.0/cue/testdata/definitions/issue493.txtar (about)

     1  -- in.cue --
     2  #Artifact: {
     3  	body: _
     4  	other: [string]: int
     5  }
     6  
     7  #App:  #Artifact
     8  #Atom: #Artifact
     9  
    10  #Both: #App | #Atom
    11  
    12  t1: #Both & {body: 3}
    13  -- out/eval/stats --
    14  Leaks:  0
    15  Freed:  24
    16  Reused: 19
    17  Allocs: 5
    18  Retain: 0
    19  
    20  Unifications: 20
    21  Conjuncts:    38
    22  Disjuncts:    24
    23  -- out/evalalpha --
    24  (struct){
    25    #Artifact: (#struct){
    26      body: (_){ _ }
    27      other: (#struct){
    28      }
    29    }
    30    #App: ~(#Artifact)
    31    #Atom: ~(#Artifact)
    32    #Both: (#struct){
    33      body: (_){ _ }
    34      other: (#struct){
    35      }
    36    }
    37    t1: (#struct){
    38      body: (int){ 3 }
    39      other: (#struct){
    40      }
    41    }
    42  }
    43  -- diff/-out/evalalpha<==>+out/eval --
    44  diff old new
    45  --- old
    46  +++ new
    47  @@ -4,16 +4,8 @@
    48       other: (#struct){
    49       }
    50     }
    51  -  #App: (#struct){
    52  -    body: (_){ _ }
    53  -    other: (#struct){
    54  -    }
    55  -  }
    56  -  #Atom: (#struct){
    57  -    body: (_){ _ }
    58  -    other: (#struct){
    59  -    }
    60  -  }
    61  +  #App: ~(#Artifact)
    62  +  #Atom: ~(#Artifact)
    63     #Both: (#struct){
    64       body: (_){ _ }
    65       other: (#struct){
    66  -- out/eval --
    67  (struct){
    68    #Artifact: (#struct){
    69      body: (_){ _ }
    70      other: (#struct){
    71      }
    72    }
    73    #App: (#struct){
    74      body: (_){ _ }
    75      other: (#struct){
    76      }
    77    }
    78    #Atom: (#struct){
    79      body: (_){ _ }
    80      other: (#struct){
    81      }
    82    }
    83    #Both: (#struct){
    84      body: (_){ _ }
    85      other: (#struct){
    86      }
    87    }
    88    t1: (#struct){
    89      body: (int){ 3 }
    90      other: (#struct){
    91      }
    92    }
    93  }
    94  -- out/compile --
    95  --- in.cue
    96  {
    97    #Artifact: {
    98      body: _
    99      other: {
   100        [string]: int
   101      }
   102    }
   103    #App: 〈0;#Artifact〉
   104    #Atom: 〈0;#Artifact〉
   105    #Both: (〈0;#App〉|〈0;#Atom〉)
   106    t1: (〈0;#Both〉 & {
   107      body: 3
   108    })
   109  }