aboutsummaryrefslogtreecommitdiff
path: root/dottydoc/shared/src/main/scala/dotty/tools/dottydoc/model/factories.scala
diff options
context:
space:
mode:
Diffstat (limited to 'dottydoc/shared/src/main/scala/dotty/tools/dottydoc/model/factories.scala')
-rw-r--r--dottydoc/shared/src/main/scala/dotty/tools/dottydoc/model/factories.scala8
1 files changed, 2 insertions, 6 deletions
diff --git a/dottydoc/shared/src/main/scala/dotty/tools/dottydoc/model/factories.scala b/dottydoc/shared/src/main/scala/dotty/tools/dottydoc/model/factories.scala
index e6a548b0f..e8d453842 100644
--- a/dottydoc/shared/src/main/scala/dotty/tools/dottydoc/model/factories.scala
+++ b/dottydoc/shared/src/main/scala/dotty/tools/dottydoc/model/factories.scala
@@ -107,12 +107,8 @@ object factories {
}
def paramLists(t: DefDef)(implicit ctx: Context): List[List[NamedReference]] = {
- def getParams(xs: List[ValDef]): List[NamedReference] = xs map { vd =>
- val name = vd.name.decode.toString
- //TODO: should not be a TypeReference but a Reference since the argument can be an Or/And-types
- val ref = TypeReference(name, UnsetLink(Text(vd.tpt.show), vd.tpt.show), Nil)
- NamedReference(name, ref)
- }
+ def getParams(xs: List[ValDef]): List[NamedReference] =
+ xs.map(vd => NamedReference(vd.name.decode.toString, returnType(vd.tpt)))
t.vparamss.map(getParams)
}