Closed
Description
Based on code inspection, it seems like both RenderReference
and ReferenceShower
(which should disappear in #4954) ignore precedence: you'd get A & B => C
from both (A & B) => C
and A & (B => C)
, and one would have have similar issues whenever combining operators with different precedence.
I confirmed this by compiling the following source (placed in dotty/doc-tool/src/dotty/tools/dottydoc/model/TestDoc.scala
), running dotty-doc/genDocs
, and then opening dotty/docs/_site/api/dotty/tools/dottydoc/model/TestDoc.html
(search didn't find that file, somehow, not sure how I should run doc generation).
package dotty.tools.dottydoc.model
trait TestDoc {
type A
type B
type C
val f1: (A with B) => C
val f2: A with (B => C)
}