about summary refs log tree commit diff
path: root/src/rustllvm/RustWrapper.cpp
diff options
context:
space:
mode:
authorAaron Hill <aa1ronham@gmail.com>2018-10-25 15:14:32 -0400
committerAaron Hill <aa1ronham@gmail.com>2018-10-25 15:14:32 -0400
commit098c659276d60fff7e0f225e1d6bc7d05591319e (patch)
tree9f4a05de3af7ab19c93955ae57154eed06dd66ae /src/rustllvm/RustWrapper.cpp
parent8ec22e7ec7ed0da2add0763d239e77c5474f3d4a (diff)
downloadrust-098c659276d60fff7e0f225e1d6bc7d05591319e.tar.gz
rust-098c659276d60fff7e0f225e1d6bc7d05591319e.zip
Check for negative impls when finding auto traits
Fixes #55321

When AutoTraitFinder begins examining a type, it checks for an explicit
negative impl. However, it wasn't checking for negative impls found when
calling 'select' on predicates found from nested obligations.

This commit makes AutoTraitFinder check for negative impls whenever it
makes a call to 'select'. If a negative impl is found, it immediately
bails out.

Normal users of SelectioContext don't need to worry about this, since
they stop as soon as an Unimplemented error is encountered. However, we
add predicates to our ParamEnv when we encounter this error, so we need
to handle negative impls specially (so that we don't try adding them to
our ParamEnv).
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions