Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
9eb2b86
refactor: use StandardCharsets
thetric Aug 4, 2025
4c3793b
refactor: just use Collections.singletonList
thetric Aug 4, 2025
e6fb9db
refactor: use Map.entrySet
thetric Aug 4, 2025
e292893
refactor: make enum fields final
thetric Aug 4, 2025
67e7b31
refactor: remove redundant "extends Object"
thetric Aug 4, 2025
ec61a93
refactor: use StandardCharsets
thetric Aug 4, 2025
ddad6bf
refactor: remove redundant "extends Object" in type param
thetric Aug 4, 2025
9066e27
refactor: remove redundant .toString()
thetric Aug 4, 2025
d4b9bb6
refactor: remove redundant string conversions
thetric Aug 4, 2025
fbcc8c0
refactor: replace StringBuffer with StringBuilder
thetric Aug 4, 2025
b9f2a40
refactor: use String.contains
thetric Aug 4, 2025
1603f97
refactor: use try-with-resources
thetric Aug 4, 2025
3cfceb2
refactor: simplify map access
thetric Aug 4, 2025
075f30d
refactor: make inner classes static
thetric Aug 4, 2025
eb472ac
refactor: make initializer static
thetric Aug 4, 2025
3b7bec8
refactor: use file stream factory methods
thetric Aug 4, 2025
b620d92
refactor: use System.arraycopy
thetric Aug 4, 2025
3649770
refactor: remove/simplify string format
thetric Aug 4, 2025
bfdf646
refactor: directly append stringbuilder to each other
thetric Aug 4, 2025
54c2713
refactor: simplify string emptiness check
thetric Aug 4, 2025
da7577a
test: correct order of assertion args
thetric Aug 4, 2025
9550cfb
refactor: use Arrays.fill
thetric Aug 4, 2025
4fb1c2f
refactor: call size on map
thetric Aug 4, 2025
43778df
refactor: close streams
thetric Aug 4, 2025
368f90d
refactor: use string builder instead of string concat in loops
thetric Aug 4, 2025
7353b2d
refactor: replace map.containsKey+.get with just .get
thetric Aug 4, 2025
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
Prev Previous commit
Next Next commit
refactor: directly append stringbuilder to each other
  • Loading branch information
thetric committed Aug 15, 2025
commit bfdf646b5ce7be9693a5492aca7acfe669598675
6 changes: 3 additions & 3 deletions src/com/ziclix/python/sql/zxJDBC.java
Original file line number Diff line number Diff line change
Expand Up @@ -396,12 +396,12 @@ public static PyException makeException(PyObject type, Throwable t, int rowIndex
StringBuilder buffer = new StringBuilder();
do {
buffer.append(sqlException.getMessage());
buffer.append(" [SQLCode: " + sqlException.getErrorCode() + "]");
buffer.append(" [SQLCode: ").append(sqlException.getErrorCode()).append("]");
if (sqlException.getSQLState() != null) {
buffer.append(", [SQLState: " + sqlException.getSQLState() + "]");
buffer.append(", [SQLState: ").append(sqlException.getSQLState()).append("]");
}
if (rowIndex >= 0) {
buffer.append(", [Row number: " + rowIndex + "]");
buffer.append(", [Row number: ").append(rowIndex).append("]");
}
sqlException = sqlException.getNextException();
if (sqlException != null) {
Expand Down
2 changes: 1 addition & 1 deletion src/org/python/compiler/ScopeInfo.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public void dump() { // for debugging
for (int i = 0; i < level; i++) {
m.append(' ');
}
m.append(((kind != CLASSSCOPE) ? scope_name : "class " + scope_name) + ": ");
m.append((kind != CLASSSCOPE) ? scope_name : "class " + scope_name).append(": ");
for (Map.Entry<String, SymInfo> entry : tbl.entrySet()) {
String name = entry.getKey();
SymInfo info = entry.getValue();
Expand Down
2 changes: 1 addition & 1 deletion src/org/python/core/PyTraceback.java
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ public void dumpStack(StringBuilder buf) {
if (tb_next != null && tb_next != this) {
((PyTraceback)tb_next).dumpStack(buf);
} else if (tb_next == this) {
buf.append("circularity detected!"+this+tb_next);
buf.append("circularity detected!").append(this).append(tb_next);
}
}

Expand Down