fix tests
This commit is contained in:
parent
a4453c20ca
commit
f54489978d
20 changed files with 76 additions and 135 deletions
|
@ -1261,15 +1261,14 @@ impl<'a: 'ast, 'b, 'ast, 'tcx> LateResolutionVisitor<'a, 'b, 'ast, 'tcx> {
|
|||
opt_ns: Option<Namespace>, // `None` indicates a module path in import
|
||||
finalize: Option<Finalize>,
|
||||
) -> PathResult<'a> {
|
||||
let res = self.r.resolve_path_with_ribs(
|
||||
self.r.resolve_path_with_ribs(
|
||||
path,
|
||||
opt_ns,
|
||||
&self.parent_scope,
|
||||
finalize,
|
||||
Some(&self.ribs),
|
||||
None,
|
||||
);
|
||||
res
|
||||
)
|
||||
}
|
||||
|
||||
// AST resolution
|
||||
|
@ -3486,6 +3485,10 @@ impl<'a: 'ast, 'b, 'ast, 'tcx> LateResolutionVisitor<'a, 'b, 'ast, 'tcx> {
|
|||
//
|
||||
// Similar thing, for types, happens in `report_errors` above.
|
||||
let report_errors_for_call = |this: &mut Self, parent_err: Spanned<ResolutionError<'a>>| {
|
||||
if !source.is_call() {
|
||||
return Some(parent_err);
|
||||
}
|
||||
|
||||
// Before we start looking for candidates, we have to get our hands
|
||||
// on the type user is trying to perform invocation on; basically:
|
||||
// we're transforming `HashMap::new` into just `HashMap`.
|
||||
|
@ -3726,6 +3729,7 @@ impl<'a: 'ast, 'b, 'ast, 'tcx> LateResolutionVisitor<'a, 'b, 'ast, 'tcx> {
|
|||
"resolve_qpath(qself={:?}, path={:?}, ns={:?}, finalize={:?})",
|
||||
qself, path, ns, finalize,
|
||||
);
|
||||
|
||||
if let Some(qself) = qself {
|
||||
if qself.position == 0 {
|
||||
// This is a case like `<T>::B`, where there is no
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue