traits/query/normalize: add some debug!
logging for the result.
This commit is contained in:
parent
5ebd300090
commit
ad1617bb49
1 changed files with 13 additions and 2 deletions
|
@ -59,11 +59,22 @@ impl<'cx, 'tcx> AtExt<'tcx> for At<'cx, 'tcx> {
|
|||
anon_depth: 0,
|
||||
};
|
||||
|
||||
let value1 = value.fold_with(&mut normalizer);
|
||||
let result = value.fold_with(&mut normalizer);
|
||||
debug!(
|
||||
"normalize::<{}>: result={:?} with {} obligations",
|
||||
::std::any::type_name::<T>(),
|
||||
result,
|
||||
normalizer.obligations.len(),
|
||||
);
|
||||
debug!(
|
||||
"normalize::<{}>: obligations={:?}",
|
||||
::std::any::type_name::<T>(),
|
||||
normalizer.obligations,
|
||||
);
|
||||
if normalizer.error {
|
||||
Err(NoSolution)
|
||||
} else {
|
||||
Ok(Normalized { value: value1, obligations: normalizer.obligations })
|
||||
Ok(Normalized { value: result, obligations: normalizer.obligations })
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue