[ty] Infer typevar specializations for `Callable` types #21551
dcreager
force pushed
from
965a9f8a
to
dbecc680
130 days ago
dcreager
changed the title [ty] Infer typevar specializations for `Callable` return types [ty] Infer typevar specializations for `Callable` types 130 days ago
dcreager
force pushed
from
7995e432
to
f89ec1a8
130 days ago
add more sequents
544dafa6
add for_each_path
998b20f0
it's a start
3b509e90
add ConstraintSetAssignability relation
20ecb561
use constraint set assignable
fc2f1750
it works!
b7fb6797
these need to be positional only to be assignable
9950c126
this gets recursively expanded now
fedc7546
clean up the diff
2c626743
dcreager
force pushed
from
38682941
to
2c626743
130 days ago
dcreager
marked this pull request as ready for review 130 days ago
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
2b949b3e
mark these as TODO
d88120b1
mdlint
957304ec
hackity hack
7bbf8393
clippity bippity
30452586
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
a303b7a8
don't create T ≤ T constraints
58c67fd4
carry over failing test from conformance suite
beb2956a
even more hack
a0f64bd0
fix tests
d3fd9883
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
2e46c8de
add failing tests
db5834df
allow multiple overloads/callables when inferring
77ce24a5
use self annotation in synthesized __init__ callable
85e6143e
doc
3bcca624
self
75e9d66d
skip non-inferable
94aca37c
generic
b90cdfc2
fix test
1e33d25d
catch self-referential typevars
b3141198
dcreager
force pushed
from
0a19c5d6
to
b3141198
122 days ago
use ConstraintSetAssignability for constraint bounds
54a4f2ec
treat each overload separately
33843927
format, really?!?!
8c7e20ab
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
c0dc6cfa
pull this out into a helper method
c74eb12d
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
db488e3c
cs assignability for paramspecs
056258c7
don't throw away return type
657685f7
oh hey that's a real bug
b84a35f2
different TODO explanation for overload example
a372e63b
callable invariance rears its head again
d47e9a60
Revert "skip non-inferable"
61381522
do this at the overloads level
c60560f3
dcreager
marked this pull request as draft 121 days ago
gotta get those return types too
ecb9c130
don't pivot on never or object
22c7fc45
not failing anymore
c56d5cc2
any here
b3e48552
update test TODOs
81fc51e1
clippy
72e0c32a
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
f29200c7
dcreager
force pushed
from
0138dc34
to
f29200c7
119 days ago
group typevars by binding context
f23ae75b
abstract over any mention of a typevar
f82b3f1e
skip current type when specializing
9a378617
dcreager
force pushed
from
1fe5ba43
to
5a5474f7
117 days ago
dcreager
force pushed
from
5a5474f7
to
e99fe240
117 days ago
dcreager
force pushed
from
56b24170
to
8a8f4bce
117 days ago
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
4f7ad7bb
dcreager
force pushed
from
8a8f4bce
to
4f7ad7bb
116 days ago
add more comments
b1ede888
dcreager
marked this pull request as ready for review 116 days ago
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
a892be31
update tests
bfde3e41
clean up the diff
f624bfdf
bump expected diagnostics for static-frame
c6a4e1c8
carljm
removed ecosystem-analyzer
carljm
added ecosystem-analyzer
carljm
commented
on 2025-12-12
add mapping for lower bound too
4bcca58c
no really
c85f102e
whelp those are backwards
73acf0a9
calculate variance from parameter type
2950af4f
limit to valid specializations
2fd7a7d9
never?
e476624e
not needed anymore
690310ce
Merge remote-tracking branch 'origin/main' into gggg
c94fbe20
fix test
99ec0be4
add materialization test
25a6690c
only when function defs are same
e9065265
add sig todo
068eb1f5
Merge remote-tracking branch 'origin/dcreager/callable-return' into d…
8069064a
bump expected sympy diagnostics in benchmark
8871fdda
dcreager
force pushed
from
b3dcc070
to
874dc7ee
113 days ago
dcreager
force pushed
from
874dc7ee
to
8871fdda
112 days ago
add canonically_ordered
ddcd76c5
canonical ordering for constraint set mappings
3c811c19
fix py-fuzzer test failure
b9ecab1f
codex attempt 1
86555989
codex 2
86271d60
restore TODOs
e583cb76
doc
bdaf8e58
simpler source_order_for
a4a3aff8
remove source_order_for
d223f64a
lots of renaming
49ca97a2
sort specialize_constrained by source_order
5a8a9500
reuse self source_order
92894d37
more comment
649c7bce
document overall approach
1f34f437
use source order in specialize_constrained too
7e2ea8bd
fix test expectation
da31e138
remove now-unused items
ccb03d3b
more comments
019db2a2
document display source_order
358185b5
only fold once
63c75d85
don't always bump
88eb5eba
place bounds/constraints first
7f4893d2
include source_order in display_graph output
d9429754
fix test expectations (again)
1dd3cf0e
clippy
cba45acd
Merge branch 'dcreager/source-order-constraints' into dcreager/callab…
f8a5d042
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
dfcdbcff
track source_order in PathAssignments
94b4dd86
Revert "canonical ordering for constraint set mappings"
42185b64
Revert "add canonically_ordered"
483f3420
return a slice!
a9140716
add note about paramspec overloads
2614be36
add a bunch of callable reveals
26c847c2
fix Class3 example
4e3dd588
add TODO
2897d498
Revert "fix py-fuzzer test failure"
06a02fc4
Merge remote-tracking branch 'origin/main' into dcreager/callable-return
44256dea
Merge branch 'main' into dcreager/callable-return
75b85163
sort those paths
e79986ab
build multiple constraints on a path into union/intersection
18ac8e6a
use vecs
5b01dbae
test non-paramspec callables individually
0cc5e03b
carljm
removed ecosystem-analyzer
carljm
added ecosystem-analyzer
carljm
approved these changes
on 2025-12-16
carljm
merged
c02bd11b
into main 110 days ago
carljm
deleted the dcreager/callable-return branch 110 days ago
Assignees
No one assigned
Labels
ty
ecosystem-analyzer
Login to write a write a comment.
Login via GitHub