Skip to content

Commit 0ca92d3

Browse files
committed
minor cleanups
1 parent 5110ec9 commit 0ca92d3

File tree

4 files changed

+3
-8
lines changed

4 files changed

+3
-8
lines changed

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/modules/MarshalModuleBuiltins.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,6 @@ public void marshal(Object v, int version, int depth, DataOutputStream buffer) {
290290
}
291291
}
292292
} catch (IOException e) {
293-
294293
throw raise(ValueError, ErrorMessages.WAS_NOT_POSSIBLE_TO_MARSHAL_P, v);
295294
}
296295
}

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/nodes/PRootNode.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,6 @@ public final byte[] getCode() {
213213

214214
@TruffleBoundary
215215
private byte[] extractCode() {
216-
assert code == null;
217216
if (this instanceof PClosureRootNode) {
218217
return PythonLanguage.getCore().getSerializer().serialize(this);
219218
}

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/nodes/util/BadOPCodeNode.java

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -53,12 +53,13 @@
5353

5454
public class BadOPCodeNode extends PRootNode {
5555

56-
private String name = "<invalid code>";
56+
private final String name;
5757

5858
@CompilationFinal private TruffleLanguage.ContextReference<PythonContext> context;
5959

6060
public BadOPCodeNode(TruffleLanguage<?> language) {
6161
super(language);
62+
this.name = "<invalid code>";
6263
}
6364

6465
public BadOPCodeNode(TruffleLanguage<?> language, String name) {
@@ -93,8 +94,4 @@ public boolean isPythonInternal() {
9394
public String getName() {
9495
return name;
9596
}
96-
97-
public void setName(String name) {
98-
this.name = name;
99-
}
10097
}

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/parser/sst/SerializationUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ public class SerializationUtils {
5353
// changed from string to objectsand we serialized only string frame slots. This version is able
5454
// serialized the return and free__class__ slots again. The tmp slots are not serialized, we
5555
// don't need them.
56-
// version 12 - don't put source into serialized bytecode
56+
// version 12 - changes needed for AST sharing
5757

5858
public static byte VERSION = 12;
5959

0 commit comments

Comments
 (0)