1
1
mirror of https://github.com/github/semantic.git synced 2024-12-28 09:21:35 +03:00

Variable is no longer part of Python syntax

This commit is contained in:
Timothy Clem 2018-08-13 08:12:02 -07:00
parent eabb821eff
commit 937241320c
2 changed files with 138 additions and 146 deletions

View File

@ -56,76 +56,75 @@ message PythonSyntax {
Comprehension comprehension = 3; Comprehension comprehension = 3;
Decorator decorator = 4; Decorator decorator = 4;
Function function = 5; Function function = 5;
Variable variable = 6; Plus plus = 6;
Plus plus = 7; Minus minus = 7;
Minus minus = 8; Times times = 8;
Times times = 9; DividedBy dividedBy = 9;
DividedBy dividedBy = 10; Modulo modulo = 10;
Modulo modulo = 11; Power power = 11;
Power power = 12; Negate negate = 12;
Negate negate = 13; FloorDivision floorDivision = 13;
FloorDivision floorDivision = 14; And and = 14;
And and = 15; Not not = 15;
Not not = 16; Or or = 16;
Or or = 17; XOr xOr = 17;
XOr xOr = 18; BAnd bAnd = 18;
BAnd bAnd = 19; BOr bOr = 19;
BOr bOr = 20; BXOr bXOr = 20;
BXOr bXOr = 21; LShift lShift = 21;
LShift lShift = 22; RShift rShift = 22;
RShift rShift = 23; Complement complement = 23;
Complement complement = 24; Call call = 24;
Call call = 25; LessThan lessThan = 25;
LessThan lessThan = 26; LessThanEqual lessThanEqual = 26;
LessThanEqual lessThanEqual = 27; GreaterThan greaterThan = 27;
GreaterThan greaterThan = 28; GreaterThanEqual greaterThanEqual = 28;
GreaterThanEqual greaterThanEqual = 29; Equal equal = 29;
Equal equal = 30; StrictEqual strictEqual = 30;
StrictEqual strictEqual = 31; Comparison comparison = 31;
Comparison comparison = 32; Enumeration enumeration = 32;
Enumeration enumeration = 33; ScopeResolution scopeResolution = 33;
ScopeResolution scopeResolution = 34; MemberAccess memberAccess = 34;
MemberAccess memberAccess = 35; Subscript subscript = 35;
Subscript subscript = 36; Member member = 36;
Member member = 37; Array array = 37;
Array array = 38; Boolean boolean = 38;
Boolean boolean = 39; Float float = 39;
Float float = 40; Hash hash = 40;
Hash hash = 41; Integer integer = 41;
Integer integer = 42; KeyValue keyValue = 42;
KeyValue keyValue = 43; Null null = 43;
Null null = 44; Set set = 44;
Set set = 45; String string = 45;
String string = 46; TextElement textElement = 46;
TextElement textElement = 47; Tuple tuple = 47;
Tuple tuple = 48; Redirect redirect = 48;
Redirect redirect = 49; Assignment assignment = 49;
Assignment assignment = 50; Break break = 50;
Break break = 51; Catch catch = 51;
Catch catch = 52; Continue continue = 52;
Continue continue = 53; Else else = 53;
Else else = 54; Finally finally = 54;
Finally finally = 55; ForEach forEach = 55;
ForEach forEach = 56; If if = 56;
If if = 57; Let let = 57;
Let let = 58; NoOp noOp = 58;
NoOp noOp = 59; Return return = 59;
Return return = 60; Statements statements = 60;
Statements statements = 61; Throw throw = 61;
Throw throw = 62; Try try = 62;
Try try = 63; While while = 63;
While while = 64; Yield yield = 64;
Yield yield = 65; Ellipsis ellipsis = 65;
Ellipsis ellipsis = 66; Import import = 66;
Import import = 67; QualifiedImport qualifiedImport = 67;
QualifiedImport qualifiedImport = 68; QualifiedAliasedImport qualifiedAliasedImport = 68;
QualifiedAliasedImport qualifiedAliasedImport = 69; Context context = 69;
Context context = 70; Empty empty = 70;
Empty empty = 71; Error error = 71;
Error error = 72; Identifier identifier = 72;
Identifier identifier = 73; Annotation annotation = 73;
Annotation annotation = 74; List list = 74;
List list = 75;
} }
} }

View File

@ -38,76 +38,75 @@ message PythonSyntax {
Comprehension comprehension = 3; Comprehension comprehension = 3;
Decorator decorator = 4; Decorator decorator = 4;
Function function = 5; Function function = 5;
Variable variable = 6; Plus plus = 6;
Plus plus = 7; Minus minus = 7;
Minus minus = 8; Times times = 8;
Times times = 9; DividedBy dividedBy = 9;
DividedBy dividedBy = 10; Modulo modulo = 10;
Modulo modulo = 11; Power power = 11;
Power power = 12; Negate negate = 12;
Negate negate = 13; FloorDivision floorDivision = 13;
FloorDivision floorDivision = 14; And and = 14;
And and = 15; Not not = 15;
Not not = 16; Or or = 16;
Or or = 17; XOr xOr = 17;
XOr xOr = 18; BAnd bAnd = 18;
BAnd bAnd = 19; BOr bOr = 19;
BOr bOr = 20; BXOr bXOr = 20;
BXOr bXOr = 21; LShift lShift = 21;
LShift lShift = 22; RShift rShift = 22;
RShift rShift = 23; Complement complement = 23;
Complement complement = 24; Call call = 24;
Call call = 25; LessThan lessThan = 25;
LessThan lessThan = 26; LessThanEqual lessThanEqual = 26;
LessThanEqual lessThanEqual = 27; GreaterThan greaterThan = 27;
GreaterThan greaterThan = 28; GreaterThanEqual greaterThanEqual = 28;
GreaterThanEqual greaterThanEqual = 29; Equal equal = 29;
Equal equal = 30; StrictEqual strictEqual = 30;
StrictEqual strictEqual = 31; Comparison comparison = 31;
Comparison comparison = 32; Enumeration enumeration = 32;
Enumeration enumeration = 33; ScopeResolution scopeResolution = 33;
ScopeResolution scopeResolution = 34; MemberAccess memberAccess = 34;
MemberAccess memberAccess = 35; Subscript subscript = 35;
Subscript subscript = 36; Member member = 36;
Member member = 37; Array array = 37;
Array array = 38; Boolean boolean = 38;
Boolean boolean = 39; Float float = 39;
Float float = 40; Hash hash = 40;
Hash hash = 41; Integer integer = 41;
Integer integer = 42; KeyValue keyValue = 42;
KeyValue keyValue = 43; Null null = 43;
Null null = 44; Set set = 44;
Set set = 45; String string = 45;
String string = 46; TextElement textElement = 46;
TextElement textElement = 47; Tuple tuple = 47;
Tuple tuple = 48; Redirect redirect = 48;
Redirect redirect = 49; Assignment assignment = 49;
Assignment assignment = 50; Break break = 50;
Break break = 51; Catch catch = 51;
Catch catch = 52; Continue continue = 52;
Continue continue = 53; Else else = 53;
Else else = 54; Finally finally = 54;
Finally finally = 55; ForEach forEach = 55;
ForEach forEach = 56; If if = 56;
If if = 57; Let let = 57;
Let let = 58; NoOp noOp = 58;
NoOp noOp = 59; Return return = 59;
Return return = 60; Statements statements = 60;
Statements statements = 61; Throw throw = 61;
Throw throw = 62; Try try = 62;
Try try = 63; While while = 63;
While while = 64; Yield yield = 64;
Yield yield = 65; Ellipsis ellipsis = 65;
Ellipsis ellipsis = 66; Import import = 66;
Import import = 67; QualifiedImport qualifiedImport = 67;
QualifiedImport qualifiedImport = 68; QualifiedAliasedImport qualifiedAliasedImport = 68;
QualifiedAliasedImport qualifiedAliasedImport = 69; Context context = 69;
Context context = 70; Empty empty = 70;
Empty empty = 71; Error error = 71;
Error error = 72; Identifier identifier = 72;
Identifier identifier = 73; Annotation annotation = 73;
Annotation annotation = 74; List list = 74;
List list = 75;
} }
} }
@ -140,12 +139,6 @@ message Function {
PythonTerm functionBody = 4; PythonTerm functionBody = 4;
} }
message Variable {
PythonTerm variableName = 1;
PythonTerm variableType = 2;
PythonTerm variableValue = 3;
}
message Plus { message Plus {
PythonTerm lhs = 1; PythonTerm lhs = 1;
PythonTerm rhs = 2; PythonTerm rhs = 2;