diff options
| author | Michael Goulet <michael@errs.io> | 2024-05-03 23:34:25 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-05-03 23:34:25 -0400 |
| commit | a55d30f53ce88d744e38a4ad8f2c063a5b4b38d8 (patch) | |
| tree | c5fb2f999feab37089f9f4bd157a71947634c67f | |
| parent | 683197701cd926e7f3c7077abc7411ae1c462677 (diff) | |
| parent | 921e74fa57b70bb40e47bf3eb980b5a510982d6f (diff) | |
Rollup merge of #124687 - fee1-dead-contrib:private-clauses, r=compiler-errors
Make `Bounds.clauses` private Construct it through `Bounds::default()`, then consume the clauses via the method `Bounds::clauses()`. This helps with effects desugaring where `clauses()` is not only the clauses within the `clauses` field.
| -rw-r--r-- | compiler/rustc_hir_analysis/src/bounds.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_hir_analysis/src/bounds.rs b/compiler/rustc_hir_analysis/src/bounds.rs index aafb5c1c0b4..5562b81871f 100644 --- a/compiler/rustc_hir_analysis/src/bounds.rs +++ b/compiler/rustc_hir_analysis/src/bounds.rs @@ -23,7 +23,7 @@ use rustc_span::Span; /// include the self type (e.g., `trait_bounds`) but in others we do not #[derive(Default, PartialEq, Eq, Clone, Debug)] pub struct Bounds<'tcx> { - pub clauses: Vec<(ty::Clause<'tcx>, Span)>, + clauses: Vec<(ty::Clause<'tcx>, Span)>, } impl<'tcx> Bounds<'tcx> { |
