8000 link to FAQ for details on implicit search · nanarth/docs.scala-lang@a8ecdb4 · GitHub
[go: up one dir, main page]

Skip to content

Commit a8ecdb4

Browse files
link to FAQ for details on implicit search
1 parent 873db05 commit a8ecdb4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

_tour/implicit-parameters.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,9 @@ A method can have an _implicit_ parameter list, marked by the _implicit_ keyword
1818
The places Scala will look for these parameters fall into two categories:
1919

2020
* Scala will first look for implicit definitions and implicit parameters that can be accessed directly (without a prefix) at the point the method with the implicit parameter block is called.
21-
* Then, it falls back to all members that are marked implicit in the companion object of the implicit parameter.
21+
* Then it looks for members marked implicit in all the companion objects associated with the implicit candidate type.
22+
23+
A more detailed guide to where scala looks for implicits can be found in [the FAQ](//docs.scala-lang.org/tutorials/FAQ/finding-implicits.html)
2224

2325
In the following example we define a method `sum` which computes the sum of a list of elements using the monoid's `add` and `unit` operations. Please note that implicit values can not be top-level.
2426

0 commit comments

Comments
 (0)
0