Split out overflow handling into its own module

This commit is contained in:
Michael Goulet
2024-07-08 16:23:01 -04:00
parent a2d58197a7
commit 7af825fea4
10 changed files with 208 additions and 187 deletions

View File

@@ -1,4 +1,4 @@
use crate::error_reporting::traits::TypeErrCtxtExt;
use crate::error_reporting::traits::TypeErrCtxtOverflowExt;
use crate::infer::{InferCtxt, TyOrConstInferVar};
use crate::traits::normalize::normalize_with_depth_to;
use rustc_data_structures::captures::Captures;

View File

@@ -3,7 +3,7 @@
use super::SelectionContext;
use super::{project, with_replaced_escaping_bound_vars, BoundVarReplacer, PlaceholderReplacer};
use crate::error_reporting::traits::OverflowCause;
use crate::error_reporting::traits::TypeErrCtxtExt;
use crate::error_reporting::traits::TypeErrCtxtOverflowExt;
use crate::solve::NextSolverError;
use rustc_data_structures::stack::ensure_sufficient_stack;
use rustc_infer::infer::at::At;

View File

@@ -3,7 +3,7 @@
//! `normalize_canonicalized_projection_ty` query when it encounters projections.
use crate::error_reporting::traits::OverflowCause;
use crate::error_reporting::traits::TypeErrCtxtExt;
use crate::error_reporting::traits::TypeErrCtxtOverflowExt;
use crate::infer::at::At;
use crate::infer::canonical::OriginalQueryValues;
use crate::infer::{InferCtxt, InferOk};

View File

@@ -18,7 +18,7 @@ use super::{
TraitQueryMode,
};
use crate::error_reporting::traits::TypeErrCtxtExt;
use crate::error_reporting::traits::TypeErrCtxtOverflowExt;
use crate::infer::{InferCtxt, InferCtxtExt, InferOk, TypeFreshener};
use crate::solve::InferCtxtSelectExt as _;
use crate::traits::normalize::normalize_with_depth;