lean4-htt/tests/elab/ctorMixedRelevance.lean
Garmelon 08eb78a5b2
chore: switch to new test/bench suite (#12590)
This PR sets up the new integrated test/bench suite. It then migrates
all benchmarks and some related tests to the new suite. There's also
some documentation and some linting.

For now, a lot of the old tests are left alone so this PR doesn't become
even larger than it already is. Eventually, all tests should be migrated
to the new suite though so there isn't a confusing mix of two systems.
2026-02-25 13:51:53 +00:00

39 lines
996 B
Text
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

structure Value1 (α : Type) where
fst : α
structure Value2 (α : Type) where
snd : α
structure TwoThingies (α : Type) where
value1 : Value1 α
value2 : Value2 α
/--
trace: [Compiler.IR] [result]
def test1._closed_0 : obj :=
let x_1 : obj := ctor_0[TwoThingies.mk] ◾ ◾;
ret x_1
def test1 : obj :=
let x_1 : obj := test1._closed_0;
ret x_1
-/
#guard_msgs in
set_option trace.compiler.ir.result true in
def test1 : TwoThingies Prop := { value1.fst := True, value2.snd := False }
/--
trace: [Compiler.IR] [result]
def test2._closed_0 : obj :=
let x_1 : u8 := 0;
let x_2 : u8 := 1;
let x_3 : tobj := box x_2;
let x_4 : tobj := box x_1;
let x_5 : obj := ctor_0[TwoThingies.mk] x_3 x_4;
ret x_5
def test2 : obj :=
let x_1 : obj := test2._closed_0;
ret x_1
-/
#guard_msgs in
set_option trace.compiler.ir.result true in
def test2 : TwoThingies Bool := { value1.fst := true, value2.snd := false }