mirror of https://github.com/sbt/sbt.git
Merge pull request #1168 from retronym/ticket/1107
Fix NPE in task macro accessing q"{...}".symbol.pos
This commit is contained in:
commit
75282195f4
|
|
@ -27,3 +27,8 @@ key1 := {
|
|||
)
|
||||
()
|
||||
}
|
||||
|
||||
// https://github.com/sbt/sbt/issues/1107
|
||||
def appcfgTask(a: String, b: String) = Def.task("")
|
||||
|
||||
TaskKey[Unit]("test") := appcfgTask(b = "", a = "").value
|
||||
|
|
|
|||
|
|
@ -167,7 +167,7 @@ object Instance
|
|||
def addType(tpe: Type, qual: Tree, selection: Tree): Tree =
|
||||
{
|
||||
qual.foreach(checkQual)
|
||||
val vd = util.freshValDef(tpe, qual.symbol.pos, functionSym)
|
||||
val vd = util.freshValDef(tpe, qual.pos, functionSym)
|
||||
inputs ::= new Input(tpe, qual, vd)
|
||||
util.refVal(selection, vd)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue