aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/core/Comments.scala
diff options
context:
space:
mode:
authorThiago Pereira <thiago@Thiagos-Mac-mini.local>2016-10-23 21:19:00 -0200
committerThiago Pereira <thiago.pereira@vivareal.com>2016-10-25 14:33:58 -0200
commit97b0af746ac3f2eb2fe7078b5aa5d596439fbfb5 (patch)
treedfda2c26c4088e27fdd7e61f216e854894f7d2a9 /src/dotty/tools/dotc/core/Comments.scala
parentf1284b48d48ec16840e3e018e060edc50d4d1bb7 (diff)
downloaddotty-97b0af746ac3f2eb2fe7078b5aa5d596439fbfb5.tar.gz
dotty-97b0af746ac3f2eb2fe7078b5aa5d596439fbfb5.tar.bz2
dotty-97b0af746ac3f2eb2fe7078b5aa5d596439fbfb5.zip
Add error message - Comments.scala:128
This commit adds the semantic object for the ```definition not found``` error. It is part of the (https://github.com/lampepfl/dotty/issues/1589)[https://github.com/lampepfl/dotty/issues/1589]
Diffstat (limited to 'src/dotty/tools/dotc/core/Comments.scala')
-rw-r--r--src/dotty/tools/dotc/core/Comments.scala3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/core/Comments.scala b/src/dotty/tools/dotc/core/Comments.scala
index 1cf5aec38..1e623db4d 100644
--- a/src/dotty/tools/dotc/core/Comments.scala
+++ b/src/dotty/tools/dotc/core/Comments.scala
@@ -9,6 +9,7 @@ import util.Positions._
import util.CommentParsing._
import util.Property.Key
import parsing.Parsers.Parser
+import reporting.diagnostic.messages.ProperDefinitionNotFound
object Comments {
val ContextDoc = new Key[ContextDocstrings]
@@ -125,7 +126,7 @@ object Comments {
val newName = (tree.name.show + "$" + codePos + "$doc").toTermName
untpd.DefDef(newName, tree.tparams, tree.vparamss, tree.tpt, tree.rhs)
case _ =>
- ctx.error("proper definition was not found in `@usecase`", codePos)
+ ctx.error(ProperDefinitionNotFound(), codePos)
tree
}
}