//! Regression test: comparing a void union variable against a constructor //! literal must compare tag scalars directly, not load through a pointer. union Op: Copy { Add, Sub, Mul } /// Compare void union against constructor literal. fn isAdd(op: Op) -> bool { return op == Op::Add; } /// Compare with non-first variant. fn isMul(op: Op) -> bool { return op == Op::Mul; }