cuelang.org/go@v0.13.0/cue/testdata/disjunctions/errors.txtar (about)

     1  -- in.cue --
     2  issue570: {
     3  	results: #DecodeOutput
     4  	results: result: "hello"
     5  
     6  	#Output: {
     7  		result: _
     8  	} | {
     9  		error: string
    10  	}
    11  
    12  	#DecodeOutput: #Output & {
    13  		result?: [... string]
    14  		...
    15  	}
    16  }
    17  
    18  issue516: {
    19  	#Def: {
    20  		match: metrics: string: {}
    21  	} | {}
    22  
    23  	x: #Def
    24  	x: match: metrics: "foo": {}
    25  }
    26  
    27  // issue #465
    28  explicitDefaultError: {
    29  	a: string | *_|_
    30  
    31  	if a != "" {
    32  	}
    33  }
    34  
    35  issue2916: {
    36  	b: _
    37  	[_]: c:      uint | *1
    38  	[string]: c: >=3 | *3
    39  }
    40  issue3157: {
    41  	foo: *42 | _
    42  	foo: *43 | bool
    43  }
    44  -- issue3581.cue --
    45  issue3581: reduced: {
    46  	list: [...] | *[]
    47  	list: ["\(c)" ]
    48  	c: _
    49  }
    50  -- issue3576.cue --
    51  issue3576: reduced: {
    52  	#A: a!: string
    53  	#B: {
    54  		if false {
    55  			dummy: {}
    56  		}
    57  	}
    58  	foo: #B | #A
    59  	foo: a: "1"
    60  }
    61  issue3576: full: {
    62  	#Run: {
    63  		run!: string
    64  		options?: #Option | [#Option, ...]
    65  		if options != _|_ {
    66  			optionsValue: options
    67  		}
    68  	}
    69  
    70  	#Copy: {
    71  		copy!: string
    72  		options?: #Option | [#Option, ...]
    73  		if options != _|_ {
    74  			optionsValue: options
    75  		}
    76  	}
    77  	
    78  	#Option: {}
    79  	
    80  	foo: #Run | #Copy
    81  	foo: run: "make"
    82  }
    83  -- issue3599.cue --
    84  // Ignore errors for irrelevant fields like let and optional fields.
    85  issue3599: full: {
    86  	#Action: {
    87  		action: {
    88  			read!:  string
    89  			write?: _|_
    90  		} | {
    91  			write!: string
    92  			read?:  _|_
    93  		}
    94  	}
    95  	
    96  	#Minio: {
    97  		container: #Action & {
    98  			action: {
    99  				read!:  string
   100  				write?: _|_
   101  			} | {
   102  				write!: string
   103  				read?:  _|_
   104  			}
   105  		}
   106  		doWrite: bool | *true
   107  		container: action: defaultAction
   108  		defaultAction: {
   109  			if doWrite { write: "somefile.txt" }
   110  			if !doWrite { read: "somefile.txt" }
   111  		}
   112  	}
   113  }
   114  issue3599: reduced: p1: {
   115  	{ a?:  1&2 } | { a:  string, b?: 1&2 }
   116  	{  } | {  }
   117  }
   118  issue3599: reduced: p2: {
   119  	{  } | {  }
   120  	{ a?:  1&2 } | { a:  string, b?: 1&2 }
   121  }
   122  issue3599: let: {
   123  	{ } | { a:  B | 1, let B = 1&2 }
   124  	{  } | {  }
   125  }
   126  -- out/eval/stats --
   127  Leaks:  6
   128  Freed:  181
   129  Reused: 171
   130  Allocs: 16
   131  Retain: 34
   132  
   133  Unifications: 119
   134  Conjuncts:    268
   135  Disjuncts:    206
   136  -- out/evalalpha --
   137  Errors:
   138  issue516.x: 2 errors in empty disjunction:
   139  issue516.x.match: field not allowed:
   140      ./in.cue:23:5
   141  issue516.x.match.metrics.foo: field not allowed:
   142      ./in.cue:23:21
   143  issue570.results.result: conflicting values "hello" and [...string] (mismatched types string and list):
   144      ./in.cue:3:19
   145      ./in.cue:12:12
   146  
   147  Result:
   148  (_|_){
   149    // [eval]
   150    issue570: (_|_){
   151      // [eval]
   152      results: (_|_){
   153        // [eval]
   154        result: (_|_){
   155          // [eval] issue570.results.result: conflicting values "hello" and [...string] (mismatched types string and list):
   156          //     ./in.cue:3:19
   157          //     ./in.cue:12:12
   158        }
   159      }
   160      #Output: (#struct){ |((#struct){
   161          result: (_){ _ }
   162        }, (#struct){
   163          error: (string){ string }
   164        }) }
   165      #DecodeOutput: (#struct){ |((#struct){
   166          result: (list){
   167          }
   168        }, (#struct){
   169          result?: (_|_){
   170            // [eval] issue570.#DecodeOutput.result: field not allowed:
   171            //     ./in.cue:12:3
   172          }
   173          error: (string){ string }
   174        }) }
   175    }
   176    issue516: (_|_){
   177      // [eval]
   178      #Def: (#struct){ |((#struct){
   179          match: (#struct){
   180            metrics: (#struct){
   181              string: (#struct){
   182              }
   183            }
   184          }
   185        }, (#struct){
   186        }) }
   187      x: (_|_){
   188        // [eval] issue516.x: 2 errors in empty disjunction:
   189        // issue516.x.match: field not allowed:
   190        //     ./in.cue:23:5
   191        // issue516.x.match.metrics.foo: field not allowed:
   192        //     ./in.cue:23:21
   193        match: (struct){
   194          metrics: (struct){
   195            foo: (struct){
   196            }
   197          }
   198        }
   199      }
   200    }
   201    explicitDefaultError: (_|_){
   202      // [incomplete] explicitDefaultError: non-concrete value string in operand to !=:
   203      //     ./in.cue:30:5
   204      //     ./in.cue:28:5
   205      a: (string){ string }
   206    }
   207    issue2916: (struct){
   208      b: (struct){
   209        c: (int){ |(*(int){ 3 }, (int){ &(>=3, int) }) }
   210      }
   211    }
   212    issue3157: (struct){
   213      foo: ((bool|int)){ |(*(int){ 43 }, (bool){ bool }) }
   214    }
   215    issue3576: (struct){
   216      reduced: (struct){
   217        #A: (#struct){
   218          a!: (string){ string }
   219        }
   220        #B: (#struct){
   221        }
   222        foo: (#struct){
   223          a: (string){ "1" }
   224        }
   225      }
   226      full: (struct){
   227        #Run: (#struct){
   228          run!: (string){ string }
   229          options?: ((list|struct)){ |((#struct){
   230            }, (list){
   231              0: (#struct){
   232              }
   233            }) }
   234        }
   235        #Copy: (#struct){
   236          copy!: (string){ string }
   237          options?: ((list|struct)){ |((#struct){
   238            }, (list){
   239              0: (#struct){
   240              }
   241            }) }
   242        }
   243        #Option: (#struct){
   244        }
   245        foo: (#struct){
   246          run: (string){ "make" }
   247          options?: ((list|struct)){ |((#struct){
   248            }, (list){
   249              0: (#struct){
   250              }
   251            }) }
   252        }
   253      }
   254    }
   255    issue3581: (struct){
   256      reduced: (struct){
   257        list: (_|_){
   258          // [incomplete] issue3581.reduced.list: 2 errors in empty disjunction:
   259          // issue3581.reduced.list: incompatible list lengths (0 and 1):
   260          //     ./issue3581.cue:2:17
   261          // issue3581.reduced.list.0: invalid interpolation: non-concrete value _ (type _):
   262          //     ./issue3581.cue:3:9
   263          0: (_){ _ }
   264        }
   265        c: (_){ _ }
   266      }
   267    }
   268    issue3599: (struct){
   269      full: (struct){
   270        #Action: (#struct){
   271          action: (#struct){ |((#struct){
   272              read!: (string){ string }
   273              write?: (_|_){
   274                // [user] explicit error (_|_ literal) in source:
   275                //     ./issue3599.cue:6:12
   276              }
   277            }, (#struct){
   278              write!: (string){ string }
   279              read?: (_|_){
   280                // [user] explicit error (_|_ literal) in source:
   281                //     ./issue3599.cue:9:12
   282              }
   283            }) }
   284        }
   285        #Minio: (#struct){
   286          container: (#struct){
   287            action: (#struct){
   288              write: (string){ "somefile.txt" }
   289              read?: (_|_){
   290                // [user] explicit error (_|_ literal) in source:
   291                //     ./issue3599.cue:9:12
   292                // explicit error (_|_ literal) in source:
   293                //     ./issue3599.cue:20:13
   294              }
   295            }
   296          }
   297          doWrite: (bool){ |(*(bool){ true }, (bool){ bool }) }
   298          defaultAction: (#struct){
   299            write: (string){ "somefile.txt" }
   300          }
   301        }
   302      }
   303      reduced: (struct){
   304        p1: (struct){ |((struct){
   305            a?: (_|_){
   306              // [eval] issue3599.reduced.p1.a: conflicting values 2 and 1:
   307              //     ./issue3599.cue:32:9
   308              //     ./issue3599.cue:32:11
   309            }
   310          }, (struct){
   311            a: (string){ string }
   312            b?: (_|_){
   313              // [eval] issue3599.reduced.p1.b: conflicting values 2 and 1:
   314              //     ./issue3599.cue:32:35
   315              //     ./issue3599.cue:32:37
   316            }
   317          }) }
   318        p2: (struct){ |((struct){
   319            a?: (_|_){
   320              // [eval] issue3599.reduced.p2.a: conflicting values 2 and 1:
   321              //     ./issue3599.cue:37:9
   322              //     ./issue3599.cue:37:11
   323            }
   324          }, (struct){
   325            a: (string){ string }
   326            b?: (_|_){
   327              // [eval] issue3599.reduced.p2.b: conflicting values 2 and 1:
   328              //     ./issue3599.cue:37:35
   329              //     ./issue3599.cue:37:37
   330            }
   331          }) }
   332      }
   333      let: (struct){ |((struct){
   334        }, (struct){
   335          a: (int){ 1 }
   336          let B#1 = (_|_){
   337            // [eval] issue3599.let.B: conflicting values 2 and 1:
   338            //     ./issue3599.cue:40:29
   339            //     ./issue3599.cue:40:31
   340          }
   341        }) }
   342    }
   343  }
   344  -- diff/-out/evalalpha<==>+out/eval --
   345  diff old new
   346  --- old
   347  +++ new
   348  @@ -1,15 +1,10 @@
   349   Errors:
   350   issue516.x: 2 errors in empty disjunction:
   351   issue516.x.match: field not allowed:
   352  -    ./in.cue:20:6
   353  -    ./in.cue:22:5
   354       ./in.cue:23:5
   355   issue516.x.match.metrics.foo: field not allowed:
   356  -    ./in.cue:19:19
   357  -    ./in.cue:22:5
   358       ./in.cue:23:21
   359   issue570.results.result: conflicting values "hello" and [...string] (mismatched types string and list):
   360  -    ./in.cue:2:11
   361       ./in.cue:3:19
   362       ./in.cue:12:12
   363   
   364  @@ -19,17 +14,12 @@
   365     issue570: (_|_){
   366       // [eval]
   367       results: (_|_){
   368  -      // [eval] issue570.results.result: conflicting values "hello" and [...string] (mismatched types string and list):
   369  -      //     ./in.cue:2:11
   370  -      //     ./in.cue:3:19
   371  -      //     ./in.cue:12:12
   372  +      // [eval]
   373         result: (_|_){
   374           // [eval] issue570.results.result: conflicting values "hello" and [...string] (mismatched types string and list):
   375  -        //     ./in.cue:2:11
   376           //     ./in.cue:3:19
   377           //     ./in.cue:12:12
   378         }
   379  -      error: (string){ string }
   380       }
   381       #Output: (#struct){ |((#struct){
   382           result: (_){ _ }
   383  @@ -40,7 +30,9 @@
   384           result: (list){
   385           }
   386         }, (#struct){
   387  -        result?: (list){
   388  +        result?: (_|_){
   389  +          // [eval] issue570.#DecodeOutput.result: field not allowed:
   390  +          //     ./in.cue:12:3
   391           }
   392           error: (string){ string }
   393         }) }
   394  @@ -59,18 +51,10 @@
   395       x: (_|_){
   396         // [eval] issue516.x: 2 errors in empty disjunction:
   397         // issue516.x.match: field not allowed:
   398  -      //     ./in.cue:20:6
   399  -      //     ./in.cue:22:5
   400         //     ./in.cue:23:5
   401         // issue516.x.match.metrics.foo: field not allowed:
   402  -      //     ./in.cue:19:19
   403  -      //     ./in.cue:22:5
   404         //     ./in.cue:23:21
   405  -      match: (_|_){
   406  -        // [eval] issue516.x.match: field not allowed:
   407  -        //     ./in.cue:20:6
   408  -        //     ./in.cue:22:5
   409  -        //     ./in.cue:23:5
   410  +      match: (struct){
   411           metrics: (struct){
   412             foo: (struct){
   413             }
   414  @@ -136,13 +120,11 @@
   415       reduced: (struct){
   416         list: (_|_){
   417           // [incomplete] issue3581.reduced.list: 2 errors in empty disjunction:
   418  -        // issue3581.reduced.list: incompatible list lengths (0 and 1)
   419  +        // issue3581.reduced.list: incompatible list lengths (0 and 1):
   420  +        //     ./issue3581.cue:2:17
   421           // issue3581.reduced.list.0: invalid interpolation: non-concrete value _ (type _):
   422           //     ./issue3581.cue:3:9
   423  -        0: (_|_){
   424  -          // [incomplete] issue3581.reduced.list.0: invalid interpolation: non-concrete value _ (type _):
   425  -          //     ./issue3581.cue:3:9
   426  -        }
   427  +        0: (_){ _ }
   428         }
   429         c: (_){ _ }
   430       }
   431  @@ -186,7 +168,6 @@
   432         p1: (struct){ |((struct){
   433             a?: (_|_){
   434               // [eval] issue3599.reduced.p1.a: conflicting values 2 and 1:
   435  -            //     ./issue3599.cue:32:2
   436               //     ./issue3599.cue:32:9
   437               //     ./issue3599.cue:32:11
   438             }
   439  @@ -194,7 +175,6 @@
   440             a: (string){ string }
   441             b?: (_|_){
   442               // [eval] issue3599.reduced.p1.b: conflicting values 2 and 1:
   443  -            //     ./issue3599.cue:32:2
   444               //     ./issue3599.cue:32:35
   445               //     ./issue3599.cue:32:37
   446             }
   447  @@ -202,7 +182,6 @@
   448         p2: (struct){ |((struct){
   449             a?: (_|_){
   450               // [eval] issue3599.reduced.p2.a: conflicting values 2 and 1:
   451  -            //     ./issue3599.cue:37:2
   452               //     ./issue3599.cue:37:9
   453               //     ./issue3599.cue:37:11
   454             }
   455  @@ -210,7 +189,6 @@
   456             a: (string){ string }
   457             b?: (_|_){
   458               // [eval] issue3599.reduced.p2.b: conflicting values 2 and 1:
   459  -            //     ./issue3599.cue:37:2
   460               //     ./issue3599.cue:37:35
   461               //     ./issue3599.cue:37:37
   462             }
   463  @@ -221,7 +199,6 @@
   464           a: (int){ 1 }
   465           let B#1 = (_|_){
   466             // [eval] issue3599.let.B: conflicting values 2 and 1:
   467  -          //     ./issue3599.cue:40:2
   468             //     ./issue3599.cue:40:29
   469             //     ./issue3599.cue:40:31
   470           }
   471  -- diff/todo/p3 --
   472  Missing error positions.
   473  -- diff/explanation --
   474  The additional "field not allowed" error is correct and a message corresponding
   475  to one of the conjuncts failing.
   476  issue516.x.match: changes are okay and arguably better.
   477  -- out/eval --
   478  Errors:
   479  issue516.x: 2 errors in empty disjunction:
   480  issue516.x.match: field not allowed:
   481      ./in.cue:20:6
   482      ./in.cue:22:5
   483      ./in.cue:23:5
   484  issue516.x.match.metrics.foo: field not allowed:
   485      ./in.cue:19:19
   486      ./in.cue:22:5
   487      ./in.cue:23:21
   488  issue570.results.result: conflicting values "hello" and [...string] (mismatched types string and list):
   489      ./in.cue:2:11
   490      ./in.cue:3:19
   491      ./in.cue:12:12
   492  
   493  Result:
   494  (_|_){
   495    // [eval]
   496    issue570: (_|_){
   497      // [eval]
   498      results: (_|_){
   499        // [eval] issue570.results.result: conflicting values "hello" and [...string] (mismatched types string and list):
   500        //     ./in.cue:2:11
   501        //     ./in.cue:3:19
   502        //     ./in.cue:12:12
   503        result: (_|_){
   504          // [eval] issue570.results.result: conflicting values "hello" and [...string] (mismatched types string and list):
   505          //     ./in.cue:2:11
   506          //     ./in.cue:3:19
   507          //     ./in.cue:12:12
   508        }
   509        error: (string){ string }
   510      }
   511      #Output: (#struct){ |((#struct){
   512          result: (_){ _ }
   513        }, (#struct){
   514          error: (string){ string }
   515        }) }
   516      #DecodeOutput: (#struct){ |((#struct){
   517          result: (list){
   518          }
   519        }, (#struct){
   520          result?: (list){
   521          }
   522          error: (string){ string }
   523        }) }
   524    }
   525    issue516: (_|_){
   526      // [eval]
   527      #Def: (#struct){ |((#struct){
   528          match: (#struct){
   529            metrics: (#struct){
   530              string: (#struct){
   531              }
   532            }
   533          }
   534        }, (#struct){
   535        }) }
   536      x: (_|_){
   537        // [eval] issue516.x: 2 errors in empty disjunction:
   538        // issue516.x.match: field not allowed:
   539        //     ./in.cue:20:6
   540        //     ./in.cue:22:5
   541        //     ./in.cue:23:5
   542        // issue516.x.match.metrics.foo: field not allowed:
   543        //     ./in.cue:19:19
   544        //     ./in.cue:22:5
   545        //     ./in.cue:23:21
   546        match: (_|_){
   547          // [eval] issue516.x.match: field not allowed:
   548          //     ./in.cue:20:6
   549          //     ./in.cue:22:5
   550          //     ./in.cue:23:5
   551          metrics: (struct){
   552            foo: (struct){
   553            }
   554          }
   555        }
   556      }
   557    }
   558    explicitDefaultError: (_|_){
   559      // [incomplete] explicitDefaultError: non-concrete value string in operand to !=:
   560      //     ./in.cue:30:5
   561      //     ./in.cue:28:5
   562      a: (string){ string }
   563    }
   564    issue2916: (struct){
   565      b: (struct){
   566        c: (int){ |(*(int){ 3 }, (int){ &(>=3, int) }) }
   567      }
   568    }
   569    issue3157: (struct){
   570      foo: ((bool|int)){ |(*(int){ 43 }, (bool){ bool }) }
   571    }
   572    issue3576: (struct){
   573      reduced: (struct){
   574        #A: (#struct){
   575          a!: (string){ string }
   576        }
   577        #B: (#struct){
   578        }
   579        foo: (#struct){
   580          a: (string){ "1" }
   581        }
   582      }
   583      full: (struct){
   584        #Run: (#struct){
   585          run!: (string){ string }
   586          options?: ((list|struct)){ |((#struct){
   587            }, (list){
   588              0: (#struct){
   589              }
   590            }) }
   591        }
   592        #Copy: (#struct){
   593          copy!: (string){ string }
   594          options?: ((list|struct)){ |((#struct){
   595            }, (list){
   596              0: (#struct){
   597              }
   598            }) }
   599        }
   600        #Option: (#struct){
   601        }
   602        foo: (#struct){
   603          run: (string){ "make" }
   604          options?: ((list|struct)){ |((#struct){
   605            }, (list){
   606              0: (#struct){
   607              }
   608            }) }
   609        }
   610      }
   611    }
   612    issue3581: (struct){
   613      reduced: (struct){
   614        list: (_|_){
   615          // [incomplete] issue3581.reduced.list: 2 errors in empty disjunction:
   616          // issue3581.reduced.list: incompatible list lengths (0 and 1)
   617          // issue3581.reduced.list.0: invalid interpolation: non-concrete value _ (type _):
   618          //     ./issue3581.cue:3:9
   619          0: (_|_){
   620            // [incomplete] issue3581.reduced.list.0: invalid interpolation: non-concrete value _ (type _):
   621            //     ./issue3581.cue:3:9
   622          }
   623        }
   624        c: (_){ _ }
   625      }
   626    }
   627    issue3599: (struct){
   628      full: (struct){
   629        #Action: (#struct){
   630          action: (#struct){ |((#struct){
   631              read!: (string){ string }
   632              write?: (_|_){
   633                // [user] explicit error (_|_ literal) in source:
   634                //     ./issue3599.cue:6:12
   635              }
   636            }, (#struct){
   637              write!: (string){ string }
   638              read?: (_|_){
   639                // [user] explicit error (_|_ literal) in source:
   640                //     ./issue3599.cue:9:12
   641              }
   642            }) }
   643        }
   644        #Minio: (#struct){
   645          container: (#struct){
   646            action: (#struct){
   647              write: (string){ "somefile.txt" }
   648              read?: (_|_){
   649                // [user] explicit error (_|_ literal) in source:
   650                //     ./issue3599.cue:9:12
   651                // explicit error (_|_ literal) in source:
   652                //     ./issue3599.cue:20:13
   653              }
   654            }
   655          }
   656          doWrite: (bool){ |(*(bool){ true }, (bool){ bool }) }
   657          defaultAction: (#struct){
   658            write: (string){ "somefile.txt" }
   659          }
   660        }
   661      }
   662      reduced: (struct){
   663        p1: (struct){ |((struct){
   664            a?: (_|_){
   665              // [eval] issue3599.reduced.p1.a: conflicting values 2 and 1:
   666              //     ./issue3599.cue:32:2
   667              //     ./issue3599.cue:32:9
   668              //     ./issue3599.cue:32:11
   669            }
   670          }, (struct){
   671            a: (string){ string }
   672            b?: (_|_){
   673              // [eval] issue3599.reduced.p1.b: conflicting values 2 and 1:
   674              //     ./issue3599.cue:32:2
   675              //     ./issue3599.cue:32:35
   676              //     ./issue3599.cue:32:37
   677            }
   678          }) }
   679        p2: (struct){ |((struct){
   680            a?: (_|_){
   681              // [eval] issue3599.reduced.p2.a: conflicting values 2 and 1:
   682              //     ./issue3599.cue:37:2
   683              //     ./issue3599.cue:37:9
   684              //     ./issue3599.cue:37:11
   685            }
   686          }, (struct){
   687            a: (string){ string }
   688            b?: (_|_){
   689              // [eval] issue3599.reduced.p2.b: conflicting values 2 and 1:
   690              //     ./issue3599.cue:37:2
   691              //     ./issue3599.cue:37:35
   692              //     ./issue3599.cue:37:37
   693            }
   694          }) }
   695      }
   696      let: (struct){ |((struct){
   697        }, (struct){
   698          a: (int){ 1 }
   699          let B#1 = (_|_){
   700            // [eval] issue3599.let.B: conflicting values 2 and 1:
   701            //     ./issue3599.cue:40:2
   702            //     ./issue3599.cue:40:29
   703            //     ./issue3599.cue:40:31
   704          }
   705        }) }
   706    }
   707  }
   708  -- out/compile --
   709  --- in.cue
   710  {
   711    issue570: {
   712      results: 〈0;#DecodeOutput〉
   713      results: {
   714        result: "hello"
   715      }
   716      #Output: ({
   717        result: _
   718      }|{
   719        error: string
   720      })
   721      #DecodeOutput: (〈0;#Output〉 & {
   722        result?: [
   723          ...string,
   724        ]
   725        ...
   726      })
   727    }
   728    issue516: {
   729      #Def: ({
   730        match: {
   731          metrics: {
   732            string: {}
   733          }
   734        }
   735      }|{})
   736      x: 〈0;#Def〉
   737      x: {
   738        match: {
   739          metrics: {
   740            foo: {}
   741          }
   742        }
   743      }
   744    }
   745    explicitDefaultError: {
   746      a: (string|*_|_(explicit error (_|_ literal) in source))
   747      if (〈0;a〉 != "") {}
   748    }
   749    issue2916: {
   750      b: _
   751      [_]: {
   752        c: (&(int, >=0)|*1)
   753      }
   754      [string]: {
   755        c: (>=3|*3)
   756      }
   757    }
   758    issue3157: {
   759      foo: (*42|_)
   760      foo: (*43|bool)
   761    }
   762  }
   763  --- issue3576.cue
   764  {
   765    issue3576: {
   766      reduced: {
   767        #A: {
   768          a!: string
   769        }
   770        #B: {
   771          if false {
   772            dummy: {}
   773          }
   774        }
   775        foo: (〈0;#B〉|〈0;#A〉)
   776        foo: {
   777          a: "1"
   778        }
   779      }
   780    }
   781    issue3576: {
   782      full: {
   783        #Run: {
   784          run!: string
   785          options?: (〈1;#Option〉|[
   786            〈2;#Option〉,
   787            ...,
   788          ])
   789          if (〈0;options〉 != _|_(explicit error (_|_ literal) in source)) {
   790            optionsValue: 〈1;options〉
   791          }
   792        }
   793        #Copy: {
   794          copy!: string
   795          options?: (〈1;#Option〉|[
   796            〈2;#Option〉,
   797            ...,
   798          ])
   799          if (〈0;options〉 != _|_(explicit error (_|_ literal) in source)) {
   800            optionsValue: 〈1;options〉
   801          }
   802        }
   803        #Option: {}
   804        foo: (〈0;#Run〉|〈0;#Copy〉)
   805        foo: {
   806          run: "make"
   807        }
   808      }
   809    }
   810  }
   811  --- issue3581.cue
   812  {
   813    issue3581: {
   814      reduced: {
   815        list: ([
   816          ...,
   817        ]|*[])
   818        list: [
   819          "\(〈1;c〉)",
   820        ]
   821        c: _
   822      }
   823    }
   824  }
   825  --- issue3599.cue
   826  {
   827    issue3599: {
   828      full: {
   829        #Action: {
   830          action: ({
   831            read!: string
   832            write?: _|_(explicit error (_|_ literal) in source)
   833          }|{
   834            write!: string
   835            read?: _|_(explicit error (_|_ literal) in source)
   836          })
   837        }
   838        #Minio: {
   839          container: (〈1;#Action〉 & {
   840            action: ({
   841              read!: string
   842              write?: _|_(explicit error (_|_ literal) in source)
   843            }|{
   844              write!: string
   845              read?: _|_(explicit error (_|_ literal) in source)
   846            })
   847          })
   848          doWrite: (bool|*true)
   849          container: {
   850            action: 〈1;defaultAction〉
   851          }
   852          defaultAction: {
   853            if 〈1;doWrite〉 {
   854              write: "somefile.txt"
   855            }
   856            if !〈1;doWrite〉 {
   857              read: "somefile.txt"
   858            }
   859          }
   860        }
   861      }
   862    }
   863    issue3599: {
   864      reduced: {
   865        p1: {
   866          ({
   867            a?: (1 & 2)
   868          }|{
   869            a: string
   870            b?: (1 & 2)
   871          })
   872          ({}|{})
   873        }
   874      }
   875    }
   876    issue3599: {
   877      reduced: {
   878        p2: {
   879          ({}|{})
   880          ({
   881            a?: (1 & 2)
   882          }|{
   883            a: string
   884            b?: (1 & 2)
   885          })
   886        }
   887      }
   888    }
   889    issue3599: {
   890      let: {
   891        ({}|{
   892          a: (〈0;let B#1〉|1)
   893          let B#1 = (1 & 2)
   894        })
   895        ({}|{})
   896      }
   897    }
   898  }