Everything contains everything!

This can't possibly be true. But right now somethings haven't been
highlighted correctly because the wrapper types have been blocking them.
Now these are explicitly marked as containing ALL, which works in the
example.swift file. I'm sure we're going to have to back this off, and
we'll do that case by case.
This commit is contained in:
Keith Smiley
2016-01-08 14:51:04 -08:00
parent d87608dcd1
commit fa61881d9c
2 changed files with 7 additions and 2 deletions

View File

@@ -309,3 +309,8 @@ public let fareEstimate: FareEstimate //= (nil, nil) // comment should be highli
key = map.optionalFrom("string") ?? [] key = map.optionalFrom("string") ?? []
key = map.optionalFrom("string") key = map.optionalFrom("string")
thing = map.optionalFrom("string") ?? .Fallback thing = map.optionalFrom("string") ?? .Fallback
guard let path = NSBundle.mainBundle().pathForResource(imageName, ofType: "png"),
let data = NSData(contentsOfFile: path) else
{
}

View File

@@ -199,9 +199,9 @@ syntax keyword swiftStructure
\ struct \ struct
\ enum \ enum
syntax region swiftTypeWrapper start="\v:\s*" skip="\s*,\s*$*\s*" end="$\|/"me=e-1 contains=swiftString,swiftBoolean,swiftNumber,swiftType,swiftGenericsWrapper transparent syntax region swiftTypeWrapper start="\v:\s*" skip="\s*,\s*$*\s*" end="$\|/"me=e-1 contains=ALL transparent
syntax region swiftGenericsWrapper start="\v\<" end="\v\>" contains=swiftType transparent oneline syntax region swiftGenericsWrapper start="\v\<" end="\v\>" contains=swiftType transparent oneline
syntax region swiftLiteralWrapper start="\v\=\s*" skip="\v[^\[\]]\(\)" end="\v(\[\]|\(\))" contains=swiftType,swiftString,swiftMethod,swiftOperator transparent oneline syntax region swiftLiteralWrapper start="\v\=\s*" skip="\v[^\[\]]\(\)" end="\v(\[\]|\(\))" contains=ALL transparent oneline
syntax region swiftReturnWrapper start="\v-\>\s*" end="\v(\{|$)" contains=swiftType transparent oneline syntax region swiftReturnWrapper start="\v-\>\s*" end="\v(\{|$)" contains=swiftType transparent oneline
syntax match swiftType "\v<\u\w*" contained containedin=swiftGenericsWrapper,swiftTypeWrapper,swiftLiteralWrapper,swiftGenericsWrapper syntax match swiftType "\v<\u\w*" contained containedin=swiftGenericsWrapper,swiftTypeWrapper,swiftLiteralWrapper,swiftGenericsWrapper