TestUserdefExpr

This commit is contained in:
xushiwei
2024-05-02 11:38:05 +08:00
parent 3e47a977e4
commit 3cbe4aac87

View File

@@ -30,16 +30,22 @@ func TestMakeInterface(t *testing.T) {
}
*/
func TestDelayExpr(t *testing.T) {
func TestUserdefExpr(t *testing.T) {
a := delayExprTy(nil)
b := &phisExprTy{}
_ = a.String()
_ = b.String()
test := func(a types.Type) {
defer func() {
if r := recover(); r == nil {
t.Log("TestDelayExpr: no error?")
t.Log("TestUserdefExpr: no error?")
}
}()
a.Underlying()
}
test(a)
test(b)
}
func TestAny(t *testing.T) {
prog := NewProgram(nil)