]> git.lizzy.rs Git - rust.git/commit
Detect type inference failure when auto-dereferencing a pointer
authorBarosl Lee <vcs@barosl.com>
Sat, 13 Dec 2014 14:22:04 +0000 (23:22 +0900)
committerBarosl Lee <vcs@barosl.com>
Fri, 19 Dec 2014 19:54:43 +0000 (04:54 +0900)
commitd9f306757d3e7cdffaea26ddacaea55a837c3124
tree17306ea086588ccbe287a40bf3f042a673dadd7f
parent95c2ed31aeb66b2662933200dbfd661a573b1f49
Detect type inference failure when auto-dereferencing a pointer

check::autoderef() returns a ty_err when it fails to infer the type.
probe::probe() should respect this failure and fail together to prevent
further corruption.

Call stack: check::check_method_call() -> method::lookup() ->
            probe::probe() + confirm::confirm()

Fixes #19692.
Fixes #19583.
Fixes #19297.
src/librustc_typeck/check/method/probe.rs
src/test/compile-fail/issue-19692.rs [new file with mode: 0644]