mirror of https://github.com/sbt/sbt.git
Merge branch 'parsing_changes' into 0.12
This commit is contained in:
commit
f11a053cc9
|
|
@ -17,7 +17,6 @@ object Relation
|
|||
make(forward, reverse)
|
||||
}
|
||||
|
||||
|
||||
private[sbt] def remove[X,Y](map: M[X,Y], from: X, to: Y): M[X,Y] =
|
||||
map.get(from) match {
|
||||
case Some(tos) =>
|
||||
|
|
|
|||
|
|
@ -2,4 +2,8 @@ package sbt
|
|||
|
||||
trait Show[T] {
|
||||
def apply(t: T): String
|
||||
}
|
||||
object Show
|
||||
{
|
||||
def apply[T](f: T => String): Show[T] = new Show[T] { def apply(t: T): String = f(t) }
|
||||
}
|
||||
|
|
@ -431,7 +431,8 @@ private final class ParserSeq[T](a: Seq[Parser[T]], errors: => Seq[String]) exte
|
|||
{
|
||||
val res = a.map(_.resultEmpty)
|
||||
val (failures, values) = separate(res)(_.toEither)
|
||||
if(failures.isEmpty) Value(values) else mkFailures(failures.flatMap(_()) ++ errors)
|
||||
// if(failures.isEmpty) Value(values) else mkFailures(failures.flatMap(_()) ++ errors)
|
||||
if(values.nonEmpty) Value(values) else mkFailures(failures.flatMap(_()) ++ errors)
|
||||
}
|
||||
def result = {
|
||||
val success = a.flatMap(_.result)
|
||||
|
|
|
|||
Loading…
Reference in New Issue