rust/compiler/rustc_hir_analysis/src
bors 0978711950 Auto merge of #108324 - notriddle:notriddle/assoc-fn-method, r=compiler-errors,davidtwco,estebank,oli-obk
diagnostics: if AssocFn has self argument, describe as method

Discussed in https://rust-lang.zulipchat.com/#narrow/stream/147480-t-compiler.2Fwg-diagnostics/topic/.22associated.20function.22.20vs.20.22method.22/near/329265515

This commit also changes the tooltips on rustdoc intra-doc links targeting methods.

For anyone not sure why this is being done, see the Reference definitions of these terms in <https://doc.rust-lang.org/1.67.1/reference/items/associated-items.html#methods>

> Associated functions whose first parameter is named `self` are called methods and may be invoked using the [method call operator](https://doc.rust-lang.org/1.67.1/reference/expressions/method-call-expr.html), for example, `x.foo()`, as well as the usual function call notation.

In particular, while this means it's technically correct for rustc to refer to a method as an associated function (and there are a few cases where it'll still do so), rustc *must never* use the term "method" to refer to an associated function that does not have a `self` parameter.
2023-02-23 00:19:12 +00:00
..
astconv Auto merge of #108324 - notriddle:notriddle/assoc-fn-method, r=compiler-errors,davidtwco,estebank,oli-obk 2023-02-23 00:19:12 +00:00
check Auto merge of #108324 - notriddle:notriddle/assoc-fn-method, r=compiler-errors,davidtwco,estebank,oli-obk 2023-02-23 00:19:12 +00:00
coherence Auto merge of #108324 - notriddle:notriddle/assoc-fn-method, r=compiler-errors,davidtwco,estebank,oli-obk 2023-02-23 00:19:12 +00:00
collect Remove type-traversal trait aliases 2023-02-22 17:04:58 +00:00
impl_wf_check Remove type-traversal trait aliases 2023-02-22 17:04:58 +00:00
outlives Add Clause::ConstArgHasType variant 2023-02-17 09:30:33 +00:00
structured_errors Auto merge of #108324 - notriddle:notriddle/assoc-fn-method, r=compiler-errors,davidtwco,estebank,oli-obk 2023-02-23 00:19:12 +00:00
variance Remove type-traversal trait aliases 2023-02-22 17:04:58 +00:00
autoderef.rs Remove type-traversal trait aliases 2023-02-22 17:04:58 +00:00
bounds.rs Rework hir Bounds collection 2022-12-28 23:40:09 +00:00
check_unused.rs Use expect_{use,fn} in a couple of places 2023-01-30 05:50:37 +00:00
collect.rs Auto merge of #107753 - kylematsuda:type-of, r=BoxyUwU 2023-02-17 04:45:15 +00:00
constrained_generic_params.rs Remove type-traversal trait aliases 2023-02-22 17:04:58 +00:00
errors.rs errors: generate typed identifiers in each crate 2023-02-22 09:15:53 +00:00
hir_wf_check.rs Remove type-traversal trait aliases 2023-02-22 17:04:58 +00:00
impl_wf_check.rs Remove type-traversal trait aliases 2023-02-22 17:04:58 +00:00
lib.rs errors: generate typed identifiers in each crate 2023-02-22 09:15:53 +00:00
structured_errors.rs rustc_typeck to rustc_hir_analysis 2022-09-27 10:37:23 +02:00