X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=compiler%2Frustc_infer%2Fsrc%2Finfer%2Fat.rs;h=39f7d30e81aca096a4289ae588ac000ba002d0c1;hb=7907385999b4a83d37ed31d334f3ed9ca02983a1;hp=58c309a5c52ea7a52aa3efbe39157cc8ad225ff6;hpb=fd7a1f153d2598e59ed7014f6ee7054a1e4ac8e4;p=rust.git diff --git a/compiler/rustc_infer/src/infer/at.rs b/compiler/rustc_infer/src/infer/at.rs index 58c309a5c52..39f7d30e81a 100644 --- a/compiler/rustc_infer/src/infer/at.rs +++ b/compiler/rustc_infer/src/infer/at.rs @@ -6,7 +6,7 @@ //! is always the "expected" output from the POV of diagnostics. //! //! Examples: -//! +//! ```ignore (fragment) //! infcx.at(cause, param_env).sub(a, b) //! // requires that `a <: b`, with `a` considered the "expected" type //! @@ -15,11 +15,11 @@ //! //! infcx.at(cause, param_env).eq(a, b) //! // requires that `a == b`, with `a` considered the "expected" type -//! +//! ``` //! For finer-grained control, you can also do use `trace`: -//! +//! ```ignore (fragment) //! infcx.at(...).trace(a, b).sub(&c, &d) -//! +//! ``` //! This will set `a` and `b` as the "root" values for //! error-reporting, but actually operate on `c` and `d`. This is //! sometimes useful when the types of `c` and `d` are not traceable