Skip to content

Commit a6c2fb9

Browse files
committed
small cleanups
1 parent 615c671 commit a6c2fb9

File tree

3 files changed

+0
-27
lines changed

3 files changed

+0
-27
lines changed

Samples/JExtractJNISampleApp/Sources/MySwiftLibrary/MySwiftClass.swift

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -90,12 +90,4 @@ public class MySwiftClass {
9090
public func addXWithJavaLong(_ other: JavaLong) -> Int64 {
9191
return self.x + other.longValue()
9292
}
93-
94-
// public func optionalMethodClass(input: MySwiftClass?) -> <Optional<MySwiftClass>> {
95-
// if let input {
96-
// return MySwiftClass(x: input.x * 10, y: input.y * 10)
97-
// } else {
98-
// return nil
99-
// }
100-
// }
10193
}

Samples/JExtractJNISampleApp/src/test/java/com/example/swift/MySwiftClassTest.java

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -152,14 +152,4 @@ void addXWithJavaLong() {
152152
assertEquals(70, c1.addXWithJavaLong(javaLong));
153153
}
154154
}
155-
156-
// @Test
157-
// void optionalMethodClass() {
158-
// try (var arena = new ConfinedSwiftMemorySession()) {
159-
// MySwiftClass c1 = MySwiftClass.init(20, 10, arena);
160-
// MySwiftClass c2 = MySwiftClass.init(50, 10, arena);
161-
// assertFalse(c1.optionalMethodClass(Optional.empty()));
162-
// assertTrue(c1.optionalMethodClass(Optional.of(c2)));
163-
// }
164-
// }
165155
}

Sources/JExtractSwiftLib/JNI/JNISwift2JavaGenerator+JavaBindingsPrinting.swift

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -372,13 +372,4 @@ extension JNISwift2JavaGenerator {
372372
)
373373
}
374374
}
375-
376-
private func renderIndirectReturnAllocation(for javaType: JavaType) -> String {
377-
switch javaType {
378-
case .array(let nested):
379-
"new byte[]"
380-
default:
381-
fatalError("renderIndirectReturnAllocation not supported for \(javaType)")
382-
}
383-
}
384375
}

0 commit comments

Comments
 (0)