Make smt-lib2 printer not drop (as ...) on applied symbols - #270
Make smt-lib2 printer not drop (as ...) on applied symbols#270hra687261 wants to merge 3 commits into
(as ...) on applied symbols#270Conversation
|
Thanks, that's a very nice fix ! While we're at it, I was wondering whether we should use the same (or a similar system) for other places where we need to print type annotations. More specifically, when applying polymorphic maps (i.e. encodings of higher-order functions), there is some logic to add an |
|
Indeed, so I tried to do something similar for the HO case in 568ff69 |
|
I also noticed that type variables are not bound when printing polymorphic function definitions in the psmt2 format, fixed it in abf073f |
Before
(as ...)was only printed for polymorphic symbols with a 0-arity, but in some cases its needed for polymorphic symbols with arguments, notably when the type variable appears in the return type and not in the types of the arguments. Here for example:Where the type-checking does not work if we don't manually bind cast the return type of
f(t1) tot3.