]> git.lizzy.rs Git - rust.git/commit
Guard variance inference for params bound in non-variance context.
authorFelix S. Klock II <pnkfelix@pnkfx.org>
Tue, 1 Apr 2014 16:31:04 +0000 (18:31 +0200)
committerFelix S. Klock II <pnkfelix@pnkfx.org>
Thu, 17 Apr 2014 09:25:46 +0000 (11:25 +0200)
commit0e30f07abc76587f676e91770b7630ac9727b2cb
tree6ee7303660128568f955e6217c5b6f815ac656cb
parent787f4151e3ac32ffe455c2d3fd991def36be9758
Guard variance inference for params bound in non-variance context.

Before adding a variance constrant for a given early-bound param,
check if it was meant to be inferred.

To support the above, added `fn is_to_be_inferred` to
`variance::ConstraintContext`.
src/librustc/middle/typeck/variance.rs