mirror of https://github.com/sbt/sbt.git
Quick and dirty fix for SO
This commit is contained in:
parent
9764b7f6ef
commit
4299ff76aa
|
|
@ -180,11 +180,13 @@ class ExtractAPI[GlobalType <: CallbackGlobal](val global: GlobalType,
|
||||||
private def printMember(label: String, in: Symbol, t: Type) = println(label + " in " + in + " : " + t + " (debug: " + debugString(t) + " )")
|
private def printMember(label: String, in: Symbol, t: Type) = println(label + " in " + in + " : " + t + " (debug: " + debugString(t) + " )")
|
||||||
private def defDef(in: Symbol, s: Symbol): List[xsbti.api.Def] =
|
private def defDef(in: Symbol, s: Symbol): List[xsbti.api.Def] =
|
||||||
{
|
{
|
||||||
def isMacro(sym: Symbol): Boolean =
|
def collectAll(acc: Set[Symbol], s: Symbol): Set[Symbol] =
|
||||||
sym.isMacro || (sym.info.members.sorted exists isMacro) || (sym.children exists isMacro)
|
if (acc contains s) acc
|
||||||
//sym.isMacro || (sym.children exists isMacro) || (sym.isType && sym.asType.toType.members.sorted.exists(isMacro))
|
else
|
||||||
val inspectPostErasure = !isMacro(in.enclosingTopLevelClass)
|
((s.info.members.sorted ++ s.children) foldLeft (acc + s)) {
|
||||||
|
case (acc, sym) => collectAll(acc, sym)
|
||||||
|
}
|
||||||
|
val inspectPostErasure = !collectAll(Set.empty, in.enclosingTopLevelClass).exists(_.isMacro)
|
||||||
def build(t: Type, typeParams: Array[xsbti.api.TypeParameter], valueParameters: List[xsbti.api.ParameterList]): List[xsbti.api.Def] =
|
def build(t: Type, typeParams: Array[xsbti.api.TypeParameter], valueParameters: List[xsbti.api.ParameterList]): List[xsbti.api.Def] =
|
||||||
{
|
{
|
||||||
def parameterList(syms: List[Symbol]): xsbti.api.ParameterList =
|
def parameterList(syms: List[Symbol]): xsbti.api.ParameterList =
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue