Update to Spectre 0.9.0 (#247)

* update to Spectre 0.9.0

* fix variable spec tests

* fix flatMap warning

* updated CHANGELOG
This commit is contained in:
Ilya Puchka
2018-09-23 03:46:27 +03:00
committed by GitHub
parent d238c25eef
commit f7bda226e8
26 changed files with 2386 additions and 2214 deletions

View File

@@ -118,7 +118,7 @@ final class IfExpressionParser {
private init(components: ArraySlice<String>, tokenParser: TokenParser, token: Token) throws {
var parsedComponents = Set<Int>()
var bracketsBalance = 0
self.tokens = try zip(components.indices, components).flatMap { (index, component) in
self.tokens = try zip(components.indices, components).compactMap { (index, component) in
guard !parsedComponents.contains(index) else { return nil }
if component == "(" {