18 lines
262 B
V
18 lines
262 B
V
|
import v.checker.tests.amod as x
|
||
|
|
||
|
struct Struct1 {}
|
||
|
|
||
|
struct AnotherStruct {}
|
||
|
|
||
|
struct ThirdStruct {}
|
||
|
|
||
|
type Abc = AnotherStruct | Struct1 | ThirdStruct | x.Bcg | x.Xyz
|
||
|
|
||
|
fn main() {
|
||
|
a := Abc(Struct1{})
|
||
|
match a {
|
||
|
x.NonExisting { println('----') }
|
||
|
else {}
|
||
|
}
|
||
|
}
|