blob: cc7bf6949aa7fa8352aa8a8b03966e720942cb74 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
package dotty.tools
package dottydoc
package model
import dotc.core.Symbols.Symbol
import dotc.core.Contexts.Context
object CommentParsers {
import comment._
import BodyParsers._
sealed class WikiParser
extends CommentCleaner with CommentParser with CommentExpander {
def parseHtml(sym: Symbol)(implicit ctx: Context): Option[Comment]= {
println("Original ---------------------")
println(ctx.base.docstring(sym).map(_.chrs).getOrElse(""))
val expanded = expand(sym)
println("Expanded ---------------------")
println(expanded)
parse(clean(expanded), expanded).toHtml match {
case "" => None
case x => Some(Comment(x))
}
}
}
val wikiParser = new WikiParser
}
|