2014-12-01 05:16:01 +00:00
|
|
|
prelude precedence `+` : 65
|
2014-06-15 05:13:25 +00:00
|
|
|
precedence `*` : 75
|
|
|
|
precedence `=` : 50
|
|
|
|
precedence `≃` : 50
|
2014-10-02 23:20:52 +00:00
|
|
|
constant N : Type.{1}
|
|
|
|
constant a : N
|
|
|
|
constant b : N
|
|
|
|
constant add : N → N → N
|
|
|
|
constant mul : N → N → N
|
2014-06-15 05:13:25 +00:00
|
|
|
namespace foo
|
2014-06-15 15:28:49 +00:00
|
|
|
infixl + := add
|
|
|
|
infixl * := mul
|
2014-06-15 05:13:25 +00:00
|
|
|
check a+b*a
|
2014-08-07 23:59:08 +00:00
|
|
|
end foo
|
2014-06-15 05:13:25 +00:00
|
|
|
-- Notation is not avaiable outside the namespace
|
|
|
|
check a+b*a
|
|
|
|
namespace foo
|
|
|
|
-- Notation is restored
|
|
|
|
check a+b*a
|
2014-08-07 23:59:08 +00:00
|
|
|
end foo
|