fun{a:t@ype} foo (xs: list0 (INV(a))): void
Assume that mylst is of the type list0 (T) for some T.
When typechecking foo(mylst), the typechecker will expand
the expression as follows by picking a placeholder T1:
foo<T1>(mylst)
where T <= T1 is assumed.
--
You received this message because you are subscribed to the Google Groups "ats-lang-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ats-lang-user...@googlegroups.com.
To post to this group, send email to ats-lan...@googlegroups.com.
Visit this group at http://groups.google.com/group/ats-lang-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/ats-lang-users/2acc15f3-ffba-40fd-b5c2-e99db819e94e%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "ats-lang-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ats-lang-user...@googlegroups.com.
To post to this group, send email to ats-lan...@googlegroups.com.
Visit this group at http://groups.google.com/group/ats-lang-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/ats-lang-users/CAEvX6dk7yM9sdi31VXoRZooiHxY1aAibkjtnGSn__-4XD7cjAw%40mail.gmail.com.
In conclusion, ATS's template engine can't guess correct type variable
without INV?
--
You received this message because you are subscribed to the Google Groups "ats-lang-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ats-lang-user...@googlegroups.com.
To post to this group, send email to ats-lan...@googlegroups.com.
Visit this group at http://groups.google.com/group/ats-lang-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/ats-lang-users/2972bcb5-80df-475f-ab7d-736ba4a66376%40googlegroups.com.
Without INV, the programmer has to pass types explicitly.list(intGte(10), 1)list(int(10), 1)list(int, 1)For instance, cons(10, nil) can have infinitely many types:
The reason is that there are many possibilities, all of which can be "correct".