1
1
mirror of https://github.com/github/semantic.git synced 2024-12-25 07:55:12 +03:00

Debug print abstraction bodies correctly.

This commit is contained in:
Rob Rix 2015-09-29 17:02:57 -04:00
parent 1cf92c94d0
commit 7925347d21

View File

@ -180,7 +180,8 @@ public enum Syntax<Payload>: CustomDebugStringConvertible, CustomDocConvertible
return ".Apply(\(f), [ \(s) ])"
case let .Abstract(parameters, body):
let s = parameters.map { String(reflecting: $0) }.joinWithSeparator(", ")
return ".Abstract([ \(s) ], \(body))"
let b = body.map { String(reflecting: $0) }.joinWithSeparator("\n")
return ".Abstract([ \(s) ], \(b))"
case let .Assign(n, v):
return ".Assign(\(n), \(v))"
case let .Variable(n):