Skip to content

Commit 8afa277

Browse files
committed
Migrate pegparser to mx layout and JUnit 4
1 parent e5464b2 commit 8afa277

File tree

723 files changed

+1147
-1344
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

723 files changed

+1147
-1344
lines changed

docs/contributor/DEV_TASKS.md

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -53,17 +53,3 @@ Follow these steps to update HPy.
5353
- Adding `GraalHPyContextFunction` implementations for the new APIs
5454
- Updating the `createMembers` method to assign the appropriate
5555
implementations to the context members
56-
57-
### Updating pegparser
58-
59-
The Python PEG parser is tracked as a separate repository as well and merged
60-
with git-subtree. This is irrelevant for external contributors, but just for
61-
reference, this is how we merge back and forth:
62-
63-
git subtree pull --prefix graalpython/com.oracle.graal.python.pegparser [pegparser-git-url] master
64-
git subtree push --prefix graalpython/com.oracle.graal.python.pegparser [pegparser-git-url] master
65-
66-
Generally this work, it can happen that the two repos become a bit inconsistent
67-
and git-subtree gives up, but then we can fix the trees manually with a `git
68-
subtree pull` and then `git subtree split` and pushing the split commit to the
69-
pegparser repo.
Lines changed: 23 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -41,15 +41,15 @@
4141

4242
package com.oracle.graal.python.pegparser;
4343

44-
import org.junit.jupiter.api.Test;
44+
import org.junit.Test;
4545

4646
public class AssignmentTests extends ParserTestBase {
4747

4848
@Test
4949
public void assignment01() throws Exception {
5050
checkTreeResult("a = 1");
5151
}
52-
52+
5353
@Test
5454
public void assignmentWithTypeComment01() throws Exception {
5555
checkTreeResult("a = 1 # type: int");
@@ -99,7 +99,7 @@ public void assignment09() throws Exception {
9999
public void assignment10() throws Exception {
100100
checkTreeResult("i, j, k = x = a");
101101
}
102-
102+
103103
@Test
104104
public void assignment11() throws Exception {
105105
checkScopeAndTree("def fn():\n a.b.c.d = 1222");
@@ -176,28 +176,29 @@ public void augassign14() throws Exception {
176176
"def _method(*args, **keywords):\n" +
177177
" cls_or_self, *rest = args");
178178
}
179+
179180
//
180-
// @Test
181-
// public void nonLocal01() throws Exception {
182-
// checkSyntaxErrorMessage(
183-
// "def outer():\n" +
184-
// " x = 'local in outer'\n" +
185-
// " def inner():\n" +
186-
// " x = 10\n" +
187-
// " nonlocal x\n" +
188-
// " inner()\n",
189-
// "SyntaxError: name 'x' is assigned to before nonlocal declaration");
190-
// }
181+
// @Test
182+
// public void nonLocal01() throws Exception {
183+
// checkSyntaxErrorMessage(
184+
// "def outer():\n" +
185+
// " x = 'local in outer'\n" +
186+
// " def inner():\n" +
187+
// " x = 10\n" +
188+
// " nonlocal x\n" +
189+
// " inner()\n",
190+
// "SyntaxError: name 'x' is assigned to before nonlocal declaration");
191+
// }
191192
//
192-
// @Test
193-
// public void annotationType01() throws Exception {
194-
// checkTreeResult("j: int");
195-
// }
193+
// @Test
194+
// public void annotationType01() throws Exception {
195+
// checkTreeResult("j: int");
196+
// }
196197
//
197-
// @Test
198-
// public void annotationType02() throws Exception {
199-
// checkScopeAndTree("def fn():\n" + " index : int = 0\n");
200-
// }
198+
// @Test
199+
// public void annotationType02() throws Exception {
200+
// checkScopeAndTree("def fn():\n" + " index : int = 0\n");
201+
// }
201202
//
202203
@Test
203204
public void annotationType03() throws Exception {
Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@
55
*/
66
package com.oracle.graal.python.pegparser;
77

8-
import org.junit.jupiter.api.Test;
9-
8+
import org.junit.Test;
109

1110
public class AtomsTests extends ParserTestBase {
1211

0 commit comments

Comments
 (0)