mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-10-29 17:50:22 +00:00
Adds basic support for the Swift programming language
Text only lexer for now until Pygments catches up
This commit is contained in:
@@ -2046,6 +2046,12 @@ SuperCollider:
|
||||
extensions:
|
||||
- .scd
|
||||
|
||||
Swift:
|
||||
type: programming
|
||||
lexer: Text only
|
||||
extensions:
|
||||
- .swift
|
||||
|
||||
SystemVerilog:
|
||||
type: programming
|
||||
color: "#343761"
|
||||
|
||||
@@ -581,6 +581,9 @@
|
||||
"SuperCollider": [
|
||||
".scd"
|
||||
],
|
||||
"Swift": [
|
||||
".swift"
|
||||
],
|
||||
"SystemVerilog": [
|
||||
".sv",
|
||||
".svh",
|
||||
@@ -723,8 +726,8 @@
|
||||
".gemrc"
|
||||
]
|
||||
},
|
||||
"tokens_total": 611474,
|
||||
"languages_total": 755,
|
||||
"tokens_total": 612602,
|
||||
"languages_total": 798,
|
||||
"tokens": {
|
||||
"ABAP": {
|
||||
"*/**": 1,
|
||||
@@ -61881,6 +61884,260 @@
|
||||
"wait": 1,
|
||||
".fork": 1
|
||||
},
|
||||
"Swift": {
|
||||
"let": 43,
|
||||
"apples": 1,
|
||||
"oranges": 1,
|
||||
"appleSummary": 1,
|
||||
"fruitSummary": 1,
|
||||
"var": 42,
|
||||
"shoppingList": 3,
|
||||
"[": 18,
|
||||
"]": 18,
|
||||
"occupations": 2,
|
||||
"emptyArray": 1,
|
||||
"String": 27,
|
||||
"(": 89,
|
||||
")": 89,
|
||||
"emptyDictionary": 1,
|
||||
"Dictionary": 1,
|
||||
"<String,>": 1,
|
||||
"Float": 1,
|
||||
"//": 1,
|
||||
"Went": 1,
|
||||
"shopping": 1,
|
||||
"and": 1,
|
||||
"bought": 1,
|
||||
"everything.": 1,
|
||||
"individualScores": 2,
|
||||
"teamScore": 4,
|
||||
"for": 10,
|
||||
"score": 2,
|
||||
"in": 11,
|
||||
"{": 77,
|
||||
"if": 6,
|
||||
"+": 15,
|
||||
"}": 77,
|
||||
"else": 1,
|
||||
"optionalString": 2,
|
||||
"nil": 1,
|
||||
"optionalName": 2,
|
||||
"greeting": 2,
|
||||
"name": 21,
|
||||
"vegetable": 2,
|
||||
"switch": 4,
|
||||
"case": 21,
|
||||
"vegetableComment": 4,
|
||||
"x": 1,
|
||||
"where": 2,
|
||||
"x.hasSuffix": 1,
|
||||
"default": 2,
|
||||
"interestingNumbers": 2,
|
||||
"largest": 4,
|
||||
"kind": 1,
|
||||
"numbers": 6,
|
||||
"number": 13,
|
||||
"n": 5,
|
||||
"while": 2,
|
||||
"<": 4,
|
||||
"*": 7,
|
||||
"m": 5,
|
||||
"do": 1,
|
||||
"firstForLoop": 3,
|
||||
"i": 6,
|
||||
"secondForLoop": 3,
|
||||
";": 2,
|
||||
"println": 1,
|
||||
"func": 24,
|
||||
"greet": 2,
|
||||
"day": 1,
|
||||
"-": 21,
|
||||
"return": 30,
|
||||
"getGasPrices": 2,
|
||||
"Double": 11,
|
||||
"sumOf": 3,
|
||||
"Int...": 1,
|
||||
"Int": 19,
|
||||
"sum": 3,
|
||||
"returnFifteen": 2,
|
||||
"y": 3,
|
||||
"add": 2,
|
||||
"makeIncrementer": 2,
|
||||
"addOne": 2,
|
||||
"increment": 2,
|
||||
"hasAnyMatches": 2,
|
||||
"list": 2,
|
||||
"condition": 2,
|
||||
"Bool": 4,
|
||||
"item": 4,
|
||||
"true": 2,
|
||||
"false": 2,
|
||||
"lessThanTen": 2,
|
||||
"numbers.map": 2,
|
||||
"result": 5,
|
||||
"sort": 1,
|
||||
"class": 7,
|
||||
"Shape": 2,
|
||||
"numberOfSides": 4,
|
||||
"simpleDescription": 14,
|
||||
"myVariable": 2,
|
||||
"myConstant": 1,
|
||||
"shape": 1,
|
||||
"shape.numberOfSides": 1,
|
||||
"shapeDescription": 1,
|
||||
"shape.simpleDescription": 1,
|
||||
"NamedShape": 3,
|
||||
"init": 4,
|
||||
"self.name": 1,
|
||||
"Square": 7,
|
||||
"sideLength": 17,
|
||||
"self.sideLength": 2,
|
||||
"super.init": 2,
|
||||
"area": 1,
|
||||
"override": 2,
|
||||
"test": 1,
|
||||
"test.area": 1,
|
||||
"test.simpleDescription": 1,
|
||||
"EquilateralTriangle": 4,
|
||||
"perimeter": 1,
|
||||
"get": 2,
|
||||
"set": 1,
|
||||
"newValue": 1,
|
||||
"/": 1,
|
||||
"triangle": 3,
|
||||
"triangle.perimeter": 2,
|
||||
"triangle.sideLength": 2,
|
||||
"TriangleAndSquare": 2,
|
||||
"willSet": 2,
|
||||
"square.sideLength": 1,
|
||||
"newValue.sideLength": 2,
|
||||
"square": 2,
|
||||
"size": 4,
|
||||
"triangleAndSquare": 1,
|
||||
"triangleAndSquare.square.sideLength": 1,
|
||||
"triangleAndSquare.triangle.sideLength": 2,
|
||||
"triangleAndSquare.square": 1,
|
||||
"Counter": 2,
|
||||
"count": 2,
|
||||
"incrementBy": 1,
|
||||
"amount": 2,
|
||||
"numberOfTimes": 2,
|
||||
"times": 4,
|
||||
"counter": 1,
|
||||
"counter.incrementBy": 1,
|
||||
"optionalSquare": 2,
|
||||
".sideLength": 1,
|
||||
"enum": 4,
|
||||
"Rank": 2,
|
||||
"Ace": 1,
|
||||
"Two": 1,
|
||||
"Three": 1,
|
||||
"Four": 1,
|
||||
"Five": 1,
|
||||
"Six": 1,
|
||||
"Seven": 1,
|
||||
"Eight": 1,
|
||||
"Nine": 1,
|
||||
"Ten": 1,
|
||||
"Jack": 1,
|
||||
"Queen": 1,
|
||||
"King": 1,
|
||||
"self": 3,
|
||||
".Ace": 1,
|
||||
".Jack": 1,
|
||||
".Queen": 1,
|
||||
".King": 1,
|
||||
"self.toRaw": 1,
|
||||
"ace": 1,
|
||||
"Rank.Ace": 1,
|
||||
"aceRawValue": 1,
|
||||
"ace.toRaw": 1,
|
||||
"convertedRank": 1,
|
||||
"Rank.fromRaw": 1,
|
||||
"threeDescription": 1,
|
||||
"convertedRank.simpleDescription": 1,
|
||||
"Suit": 2,
|
||||
"Spades": 1,
|
||||
"Hearts": 1,
|
||||
"Diamonds": 1,
|
||||
"Clubs": 1,
|
||||
".Spades": 2,
|
||||
".Hearts": 1,
|
||||
".Diamonds": 1,
|
||||
".Clubs": 1,
|
||||
"hearts": 1,
|
||||
"Suit.Hearts": 1,
|
||||
"heartsDescription": 1,
|
||||
"hearts.simpleDescription": 1,
|
||||
"implicitInteger": 1,
|
||||
"implicitDouble": 1,
|
||||
"explicitDouble": 1,
|
||||
"struct": 2,
|
||||
"Card": 2,
|
||||
"rank": 2,
|
||||
"suit": 2,
|
||||
"threeOfSpades": 1,
|
||||
".Three": 1,
|
||||
"threeOfSpadesDescription": 1,
|
||||
"threeOfSpades.simpleDescription": 1,
|
||||
"ServerResponse": 1,
|
||||
"Result": 1,
|
||||
"Error": 1,
|
||||
"success": 2,
|
||||
"ServerResponse.Result": 1,
|
||||
"failure": 1,
|
||||
"ServerResponse.Error": 1,
|
||||
".Result": 1,
|
||||
"sunrise": 1,
|
||||
"sunset": 1,
|
||||
"serverResponse": 2,
|
||||
".Error": 1,
|
||||
"error": 1,
|
||||
"protocol": 1,
|
||||
"ExampleProtocol": 5,
|
||||
"mutating": 3,
|
||||
"adjust": 4,
|
||||
"SimpleClass": 2,
|
||||
"anotherProperty": 1,
|
||||
"a": 2,
|
||||
"a.adjust": 1,
|
||||
"aDescription": 1,
|
||||
"a.simpleDescription": 1,
|
||||
"SimpleStructure": 2,
|
||||
"b": 1,
|
||||
"b.adjust": 1,
|
||||
"bDescription": 1,
|
||||
"b.simpleDescription": 1,
|
||||
"extension": 1,
|
||||
"protocolValue": 1,
|
||||
"protocolValue.simpleDescription": 1,
|
||||
"repeat": 2,
|
||||
"<ItemType>": 1,
|
||||
"ItemType": 3,
|
||||
"OptionalValue": 2,
|
||||
"<T>": 1,
|
||||
"None": 1,
|
||||
"Some": 1,
|
||||
"T": 5,
|
||||
"possibleInteger": 2,
|
||||
"<Int>": 1,
|
||||
".None": 1,
|
||||
".Some": 1,
|
||||
"anyCommonElements": 2,
|
||||
"<T,>": 1,
|
||||
"U": 4,
|
||||
"Sequence": 2,
|
||||
"GeneratorType": 3,
|
||||
"Element": 3,
|
||||
"Equatable": 1,
|
||||
"lhs": 2,
|
||||
"rhs": 2,
|
||||
"lhsItem": 2,
|
||||
"rhsItem": 2,
|
||||
"label": 2,
|
||||
"width": 2,
|
||||
"widthLabel": 1
|
||||
},
|
||||
"SystemVerilog": {
|
||||
"module": 3,
|
||||
"endpoint_phy_wrapper": 2,
|
||||
@@ -66478,6 +66735,7 @@
|
||||
"Stata": 3133,
|
||||
"Stylus": 76,
|
||||
"SuperCollider": 133,
|
||||
"Swift": 1128,
|
||||
"SystemVerilog": 541,
|
||||
"Tcl": 1133,
|
||||
"Tea": 3,
|
||||
@@ -66663,6 +66921,7 @@
|
||||
"Stata": 7,
|
||||
"Stylus": 1,
|
||||
"SuperCollider": 1,
|
||||
"Swift": 43,
|
||||
"SystemVerilog": 4,
|
||||
"Tcl": 2,
|
||||
"Tea": 1,
|
||||
@@ -66686,5 +66945,5 @@
|
||||
"YAML": 2,
|
||||
"Zephir": 2
|
||||
},
|
||||
"md5": "a7d557f9fecf06444c92c22e6f32daa7"
|
||||
"md5": "e41e5530c6efe39b710ace7e1d5d318c"
|
||||
}
|
||||
Reference in New Issue
Block a user