Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use str_number_variable to define paths #116

Merged
merged 1 commit into from
Aug 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion kin/grammar/PBXProj.g4
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,7 @@ name
;

path
: PATH '=' any_string ';'
: PATH '=' str_number_variable ';'
;

source_tree
Expand Down
2 changes: 1 addition & 1 deletion kin/grammar/PBXProj.interp

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions kin/grammar/PBXProjParser.py
Original file line number Diff line number Diff line change
Expand Up @@ -537,7 +537,7 @@ def serializedATN():
1350,5,68,0,0,1350,1351,5,3,0,0,1351,1352,3,224,112,0,1352,1353,
5,4,0,0,1353,211,1,0,0,0,1354,1355,5,69,0,0,1355,1356,5,3,0,0,1356,
1357,3,382,191,0,1357,1358,5,4,0,0,1358,213,1,0,0,0,1359,1360,5,
70,0,0,1360,1361,5,3,0,0,1361,1362,3,382,191,0,1362,1363,5,4,0,0,
70,0,0,1360,1361,5,3,0,0,1361,1362,3,384,192,0,1362,1363,5,4,0,0,
1363,215,1,0,0,0,1364,1365,5,71,0,0,1365,1366,5,3,0,0,1366,1367,
3,382,191,0,1367,1368,5,4,0,0,1368,217,1,0,0,0,1369,1370,5,72,0,
0,1370,1371,5,3,0,0,1371,1372,5,13,0,0,1372,1373,5,4,0,0,1373,219,
Expand Down Expand Up @@ -8678,8 +8678,8 @@ def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
def PATH(self):
return self.getToken(PBXProjParser.PATH, 0)

def any_string(self):
return self.getTypedRuleContext(PBXProjParser.Any_stringContext,0)
def str_number_variable(self):
return self.getTypedRuleContext(PBXProjParser.Str_number_variableContext,0)


def getRuleIndex(self):
Expand Down Expand Up @@ -8707,7 +8707,7 @@ def path(self):
self.state = 1360
self.match(PBXProjParser.T__2)
self.state = 1361
self.any_string()
self.str_number_variable()
self.state = 1362
self.match(PBXProjParser.T__3)
except RecognitionException as re:
Expand Down
15 changes: 15 additions & 0 deletions tests/ok/019.pbxproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
archiveVersion = 1;
classes = {};
objectVersion = 46;
objects = {
FE870E28DC2371E7ACA886F03F460581 = {isa = PBXFileReference; explicitFileType = text.xcconfig; name = "Something.xcconfig"; path = 0840; sourceTree = "<group>"; wrapsLines = 1; };
78452DDA02BFEF5D6BA29AEFB4B1266A = {isa = PBXGroup; children = (FE870E28DC2371E7ACA886F03F460581,); name = Configurations; sourceTree = "<group>"; };
49FBBF861C10C2A200A1A4BB = {isa = PBXProject; buildConfigurationList = 49FBBF891C10C2A200A1A4BB; compatibilityVersion = "Xcode 3.2"; hasScannedForEncodings = 0; mainGroup = 49FBBF851C10C2A200A1A4BB; productRefGroup = 49FBBF8F1C10C2A200A1A4BB; projectDirPath = ""; projectRoot = ""; targets = (49FBBF8D1C10C2A200A1A4BB, 4973659B1C19BC6E00837617,); };
49FBBF951C10C2A200A1A4BB = {isa = PBXVariantGroup; children = (49FBBF961C10C2A200A1A4BB,); name = Main.storyboard; sourceTree = "<group>"; };
49FBBF9A1C10C2A200A1A4BB = {isa = PBXVariantGroup; children = (49FBBF9B1C10C2A200A1A4BB,); name = LaunchScreen.storyboard; sourceTree = "<group>"; };
497365A41C19BC6E00837617 = {isa = XCBuildConfiguration; baseConfigurationReference = 274E42B0193BA6FEFA8FD71C; buildSettings = { FRAMEWORK_SEARCH_PATHS = ("$(inherited)", "$(PROJECT_DIR)/build/Debug-iphoneos",); }; name = Debug; };
49FBBFB61C10C2A200A1A4BB = {isa = XCConfigurationList; buildConfigurations = (49FBBFB71C10C2A200A1A4BB, 49FBBFB81C10C2A200A1A4BB,); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; };
};
rootObject = 49FBBF861C10C2A200A1A4BB;
}