diff options
author | Kato Kazuyoshi <kato.kazuyoshi@gmail.com> | 2011-08-06 12:48:48 +0000 |
---|---|---|
committer | Kato Kazuyoshi <kato.kazuyoshi@gmail.com> | 2011-08-06 12:48:48 +0000 |
commit | 8709b52eef9a0c0b2600664e38e01af3423e93f6 (patch) | |
tree | c434800649fd185e421eb84079709b65d4bc9c62 /test | |
parent | 92f32deabb13c9fe530314c998f557ab8d9feed5 (diff) | |
download | scala-8709b52eef9a0c0b2600664e38e01af3423e93f6.tar.gz scala-8709b52eef9a0c0b2600664e38e01af3423e93f6.tar.bz2 scala-8709b52eef9a0c0b2600664e38e01af3423e93f6.zip |
Some "synthetic" code don't have RangePosition.
Diffstat (limited to 'test')
-rw-r--r-- | test/scaladoc/resources/SI_4287.scala | 6 | ||||
-rw-r--r-- | test/scaladoc/scala/html/HtmlFactoryTest.scala | 11 |
2 files changed, 17 insertions, 0 deletions
diff --git a/test/scaladoc/resources/SI_4287.scala b/test/scaladoc/resources/SI_4287.scala new file mode 100644 index 0000000000..9846db466d --- /dev/null +++ b/test/scaladoc/resources/SI_4287.scala @@ -0,0 +1,6 @@ +class ClassWithSugar(val x: Int = 123) { +} + +class ClassWithoutSugar { + def this(x: Int = 456) = this() +} diff --git a/test/scaladoc/scala/html/HtmlFactoryTest.scala b/test/scaladoc/scala/html/HtmlFactoryTest.scala index f3973fa7c9..45792056fc 100644 --- a/test/scaladoc/scala/html/HtmlFactoryTest.scala +++ b/test/scaladoc/scala/html/HtmlFactoryTest.scala @@ -353,4 +353,15 @@ object Test extends Properties("HtmlFactory") { case _ => false } } + + property("Default arguments of synthesized constructor") = { + val files = createTemplates("SI_4287.scala") + + files("ClassWithSugar.html") match { + case node: scala.xml.Node => { + node.toString.contains(">123<") + } + case _ => false + } + } } |