Skip to content

Commit f661e8b

Browse files
committed
fix: apply changes from #14 to grammar file
1 parent 2bd63e1 commit f661e8b

2 files changed

Lines changed: 2 additions & 15 deletions

File tree

lib/parser/pbxproj.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/**
1+
/*
22
Licensed to the Apache Software Foundation (ASF) under one
33
or more contributor license agreements. See the NOTICE file
44
distributed with this work for additional information
@@ -16,7 +16,6 @@
1616
specific language governing permissions and limitations
1717
under the License.
1818
*/
19-
2019
/*
2120
* Generated by PEG.js 0.10.0.
2221
*

lib/parser/pbxproj.pegjs

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -17,18 +17,6 @@
1717
under the License.
1818
*/
1919

20-
{
21-
function merge_obj(obj, secondObj) {
22-
if (!obj)
23-
return secondObj;
24-
25-
for(var i in secondObj)
26-
obj[i] = merge_obj(obj[i], secondObj[i]);
27-
28-
return obj;
29-
}
30-
}
31-
3220
/*
3321
* Project: point of entry from pbxproj file
3422
*/
@@ -62,7 +50,7 @@ AssignmentList
6250
var returnObject = list[0][0];
6351
for(var i = 1; i < list.length; i++){
6452
var another = list[i][0];
65-
returnObject = merge_obj(returnObject, another);
53+
returnObject = Object.assign(returnObject, another);
6654
}
6755
return returnObject;
6856
}

0 commit comments

Comments
 (0)