mirror of
https://github.com/keith/swift.vim.git
synced 2025-12-22 12:14:13 +01:00
Improve highlighting of #available condition
Conforming to Xcode, the syntax file now highlights platforms contained within the `#available` condition. It also now removes highlighting numbers and the "*" (i.e, symbol for future platforms) that are contained within the `#available` condition since they are not literal numbers or operator (thanks to @acclissold for the idea) Additionally, add tests to example.swift to demonstrate highlighting of them. References #56
This commit is contained in:
@@ -266,3 +266,10 @@ let dict = [
|
||||
"fadsf",
|
||||
],
|
||||
]
|
||||
|
||||
if #available(OSX 10.10.3, *) {
|
||||
// Use APIs OS X 10.10.3 and onwards
|
||||
}
|
||||
if #available(watchOS 2, iOS 9.0, OSX 10.11, *) {
|
||||
// APIs available to watchOS 2.0, iOS 9.0, OSX 10.11 and onwards
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user