diff --git a/src/doc/rustc-dev-guide/src/traits/wf.md b/src/doc/rustc-dev-guide/src/traits/wf.md
index bd1188d87ad1..4cef9ec84ae6 100644
--- a/src/doc/rustc-dev-guide/src/traits/wf.md
+++ b/src/doc/rustc-dev-guide/src/traits/wf.md
@@ -52,7 +52,7 @@ struct Type
where WC_type {
```
we generate the following goal:
-```
+```text
forall {
if (FromEnv(WC_type)) {
WellFormed(InputTypes(WC_type)) &&
@@ -239,7 +239,7 @@ with values provided by the impl, we may omit them if we don't need them, and
we cannot add new where clauses.
Now let's see the generated goal for this general impl:
-```
+```text
forall {
if (FromEnv(WC_impl), FromEnv(InputTypes(SomeType))) {
WellFormed(SomeType: Trait) &&