Skip to content
This repository was archived by the owner on Mar 8, 2020. It is now read-only.

Commit 031a1fc

Browse files
committed
sem: drop MethodDeclaration->parameters->modifiers
Instead of failing whole trasformation by assuming it's always nil, when it's not. Signed-off-by: Alexander Bezzubov <[email protected]>
1 parent f8753dc commit 031a1fc

5 files changed

+1208
-1
lines changed

Diff for: driver/normalizer/normalizer.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ var Normalizers = []Mapping{
148148
{Name: uast.KeyPos, Op: Var("apos")},
149149
{Name: "extraDimensions2", Op: Is(nil)},
150150
{Name: "initializer", Op: Var("ainit")},
151-
{Name: "modifiers", Op: Is(nil)},
151+
{Name: "modifiers", Op: Any(), Drop: true}, // FIXME: preserve this array
152152
{Name: "name", Op: Var("aname")},
153153
{Name: "type", Op: Var("atype")},
154154
{Name: "varargs", Op: Cases("varg", String("false"), String("true"))},

Diff for: fixtures/issue104_final_args.java

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
package pkg;
2+
3+
class C {
4+
public void m1(final String str1) {}
5+
public void m2(String str2) {}
6+
}

0 commit comments

Comments
 (0)