diff options
| author | lcnr <rust@lcnr.de> | 2023-04-11 10:48:38 +0200 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2023-04-26 12:09:10 -0700 |
| commit | c83eb53b16f627443eb4147eb58d6d2ee6b2d775 (patch) | |
| tree | 2fac51f0b08ef6f3656e42b3cc7f05e421101e98 /src/doc/rustc-dev-guide | |
| parent | 62924088231a70a7fe93784ddf0e7e330eda5a34 (diff) | |
| download | rust-c83eb53b16f627443eb4147eb58d6d2ee6b2d775.tar.gz rust-c83eb53b16f627443eb4147eb58d6d2ee6b2d775.zip | |
extend the sixth requirement
Diffstat (limited to 'src/doc/rustc-dev-guide')
| -rw-r--r-- | src/doc/rustc-dev-guide/src/solve/trait-solving.md | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/doc/rustc-dev-guide/src/solve/trait-solving.md b/src/doc/rustc-dev-guide/src/solve/trait-solving.md index 71f6581c208..893066d8627 100644 --- a/src/doc/rustc-dev-guide/src/solve/trait-solving.md +++ b/src/doc/rustc-dev-guide/src/solve/trait-solving.md @@ -96,6 +96,10 @@ Trait solving during codegen should have the same result as during typeck. As we all free regions during codegen we must not rely on them during typeck. A noteworthy example is special behavior for `'static`. +We also have to be careful with relying on equality of regions in the trait solver. +This is fine for codegen, as we treat all erased regions are equal. We can however +loose equality information from HIR to MIR typeck. + ### 7. Removing ambiguity makes strictly more things compile We *should* not rely on ambiguity for things to compile. |
