Florian Diebold
30647cd195
Some more cleanup
2019-06-15 18:36:58 +02:00
Florian Diebold
49489dc20c
Add basic infrastructure for assoc type projection
2019-06-15 18:21:23 +02:00
Alan Du
ecd420636e
Fix clippy::single_match
2019-06-04 18:05:07 -04:00
Florian Diebold
7fda874dd4
Blacklist some traits from being considered in where clauses
...
For Send/Sync/Sized, we don't handle auto traits correctly yet and because they
have a lot of impls, they can easily lead to slowdowns. In the case of
Fn/FnMut/FnOnce, we don't parse the special Fn notation correctly yet and don't
handle closures yet, so we are very unlikely to find an impl.
2019-05-12 20:23:57 +02:00
Florian Diebold
d6dc75f9f2
Handle auto traits & negative impls
...
We don't pass field types to Chalk yet though, so the auto trait inference won't
be correct.
2019-05-11 16:21:20 +02:00
Florian Diebold
7744cd41e2
Reduce Chalk max_size parameter, add test for slow case
2019-05-11 16:21:20 +02:00
Florian Diebold
d8cd0e36f5
Handle Chalk conversion for FnDef
2019-05-11 16:21:20 +02:00
Florian Diebold
58b68966bf
Handle resolution errors in where clauses
...
This is slightly hacky, but maybe more elegant than alternative solutions: We
just use a hardcoded Chalk trait ID which we special-case to have no impls.
2019-05-11 16:21:20 +02:00
Florian Diebold
50bbf9eb09
Handle where clauses in trait solving
2019-05-11 16:21:20 +02:00
Florian Diebold
a4eb1a546c
Differentiate Tuple / FnPtr type constructors by cardinality
...
This is necessary because Chalk (reasonably) expects each 'struct' to know how
many type parameters it takes.
2019-05-04 19:11:21 +02:00
Florian Diebold
f43e69a64e
Handle recursive types in canonicalization
2019-05-04 18:25:36 +02:00
Florian Diebold
5795d773db
Remove ToChalk implementation for ApplicationTy
2019-05-04 18:18:30 +02:00
Florian Diebold
0bcf47b22b
Update Chalk
2019-05-04 18:18:30 +02:00
Florian Diebold
0f34568924
Turn eprintln!s into debug!s
2019-05-04 18:18:30 +02:00
Florian Diebold
7310f3f801
Handle Ty::Unknown in Chalk conversion
...
Badly, but at least it doesn't crash.
2019-05-04 18:18:30 +02:00
Florian Diebold
0ad7317b24
Canonicalize before doing method resolution
2019-05-04 18:18:30 +02:00
Florian Diebold
c8a643f090
Move Chalk conversion code to its own module
2019-05-04 18:18:30 +02:00