aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Pretty <jon.pretty@propensive.com>2017-06-30 22:47:04 +0200
committerJon Pretty <jon.pretty@propensive.com>2017-06-30 22:47:04 +0200
commit8cd72499b92d745ce3e3f2621a03ab61ce78ef85 (patch)
treeb89f2eba450c9133bf9a03cefaaa0b6e734de3ec
parentf257d2a616529b75b379407911d27b8021b7c751 (diff)
downloadmagnolia-8cd72499b92d745ce3e3f2621a03ab61ce78ef85.tar.gz
magnolia-8cd72499b92d745ce3e3f2621a03ab61ce78ef85.tar.bz2
magnolia-8cd72499b92d745ce3e3f2621a03ab61ce78ef85.zip
Include the prefix 'magnolia: ' before all compiler messages
-rw-r--r--core/src/main/scala/magnolia.scala8
1 files changed, 4 insertions, 4 deletions
diff --git a/core/src/main/scala/magnolia.scala b/core/src/main/scala/magnolia.scala
index 8f52be7..4e239c6 100644
--- a/core/src/main/scala/magnolia.scala
+++ b/core/src/main/scala/magnolia.scala
@@ -75,7 +75,7 @@ class Macros(val c: whitebox.Context) {
val updatedStack = currentStack.copy(errors = error :: currentStack.errors)
recursionStack = recursionStack.updated(c.enclosingPosition, updatedStack)
- c.abort(c.enclosingPosition, s"Could not find typeclass for type $genericType")
+ c.abort(c.enclosingPosition, s"magnolia: could not find typeclass for type $genericType")
}
}
@@ -146,7 +146,7 @@ class Macros(val c: whitebox.Context) {
val subtypes = classType.get.knownDirectSubclasses.to[List]
if(subtypes.isEmpty) {
- c.info(c.enclosingPosition, s"could not find any direct subtypes of $typeSymbol", true)
+ c.info(c.enclosingPosition, s"magnolia: could not find any direct subtypes of $typeSymbol", true)
c.abort(c.enclosingPosition, "")
}
@@ -250,7 +250,7 @@ class Macros(val c: whitebox.Context) {
if(!emittedErrors.contains(error)) {
emittedErrors += error
val trace = error.path.mkString("\n in ", "\n in ", "\n \n")
- val msg = s"could not derive ${typeConstructor} instance for type ${error.genericType}"
+ val msg = s"magnolia: could not derive ${typeConstructor} instance for type ${error.genericType}"
c.info(c.enclosingPosition, msg+trace, true)
}
}
@@ -271,7 +271,7 @@ class Macros(val c: whitebox.Context) {
result.map { tree =>
if(currentStack.frames.isEmpty) c.untypecheck(removeLazy.transform(tree)) else tree
}.getOrElse {
- c.abort(c.enclosingPosition, s"could not infer typeclass for type $genericType")
+ c.abort(c.enclosingPosition, s"magnolia: could not infer typeclass for type $genericType")
}
}
}