Merge pull request #33 from AliSoftware/guards

Adding Guards 👮
This commit is contained in:
Kyle Fuller
2015-10-24 13:28:47 -07:00
5 changed files with 75 additions and 73 deletions

View File

@@ -69,11 +69,9 @@ public class TokenParser {
case .Block:
let tag = token.components().first
if let parse_until = parse_until {
if parse_until(parser: self, token: token) {
if let parse_until = parse_until where parse_until(parser: self, token: token) {
prependToken(token)
return nodes
}
}
if let tag = tag, let parser = self.tags[tag] {