blob: 213e112427d3ef62d3ed5f50238174d89df68942 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
# /* custom error:Failed to convert type: Variant<'A':Int32,'B':Int32,'X':Int32> to Variant<'A':Int32,'B':Int32,'C':Int32>*/
(
(let config (DataSource 'config))
(let res_sink (DataSink 'result))
(let origType (VariantType (StructType '('A (DataType 'Int32)) '('B (DataType 'Int32)) '('C (DataType 'Int32)))))
(let orig (Variant (Int32 '0) 'B origType))
(let testcase (AsList orig))
(let testType (VariantType (StructType '('A (DataType 'Int32)) '('B (DataType 'Int32)) '('X (DataType 'Int32)))))
(let test (Variant (Int32 '0) 'B testType))
(let testcase (Append testcase test))
(let world (Write! world res_sink (Key) testcase '('('type))))
(let world (Commit! world res_sink))
(return world)
)
|