Skip to content

Commit 1f5150b

Browse files
committed
point to docs for ambig const/ty on intravisit
1 parent 2bdeff2 commit 1f5150b

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

compiler/rustc_hir/src/intravisit.rs

+6
Original file line numberDiff line numberDiff line change
@@ -359,6 +359,9 @@ pub trait Visitor<'v>: Sized {
359359
/// All types are treated as ambiguous types for the purposes of hir visiting in
360360
/// order to ensure that visitors can handle infer vars without it being too error-prone.
361361
///
362+
/// See the doc comments on [`Ty`] for an explanation of what it means for a type to be
363+
/// ambiguous.
364+
///
362365
/// The [`Visitor::visit_infer`] method should be overriden in order to handle infer vars.
363366
fn visit_ty(&mut self, t: &'v Ty<'v, AmbigArg>) -> Self::Result {
364367
walk_ty(self, t)
@@ -367,6 +370,9 @@ pub trait Visitor<'v>: Sized {
367370
/// All consts are treated as ambiguous consts for the purposes of hir visiting in
368371
/// order to ensure that visitors can handle infer vars without it being too error-prone.
369372
///
373+
/// See the doc comments on [`ConstArg`] for an explanation of what it means for a const to be
374+
/// ambiguous.
375+
///
370376
/// The [`Visitor::visit_infer`] method should be overriden in order to handle infer vars.
371377
fn visit_const_arg(&mut self, c: &'v ConstArg<'v, AmbigArg>) -> Self::Result {
372378
walk_ambig_const_arg(self, c)

0 commit comments

Comments
 (0)