Skip to content

Commit b223132

Browse files
committed
Remove deprecated Ref suffix
1 parent 6ce7e77 commit b223132

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

IntegrationTests/TestSuites/Sources/BenchmarkTests/Benchmark.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ class Benchmark {
66
}
77

88
let title: String
9-
let runner: JSFunctionRef = JSObjectRef.global.benchmarkRunner.function!
9+
let runner = JSObject.global.benchmarkRunner.function!
1010

1111
func testSuite(_ name: String, _ body: @escaping () -> Void) {
1212
let jsBody = JSClosure { arguments -> JSValue in

IntegrationTests/TestSuites/Sources/BenchmarkTests/main.swift

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ let serialization = Benchmark("Serialization")
55
let swiftInt: Double = 42
66
serialization.testSuite("Swift Int to JavaScript") {
77
let jsNumber = JSValue.number(swiftInt)
8-
let object = JSObjectRef.global
8+
let object = JSObject.global
99
for i in 0 ..< 100 {
1010
object["numberValue\(i)"] = jsNumber
1111
}
@@ -14,15 +14,15 @@ serialization.testSuite("Swift Int to JavaScript") {
1414
let swiftString = "Hello, world"
1515
serialization.testSuite("Swift String to JavaScript") {
1616
let jsString = JSValue.string(swiftString)
17-
let object = JSObjectRef.global
17+
let object = JSObject.global
1818
for i in 0 ..< 100 {
1919
object["stringValue\(i)"] = jsString
2020
}
2121
}
2222

2323
let objectHeap = Benchmark("Object heap")
2424

25-
let global = JSObjectRef.global
25+
let global = JSObject.global
2626
let Object = global.Object.function!
2727
global.objectHeapDummy = .object(Object.new())
2828
objectHeap.testSuite("Increment and decrement RC") {

Sources/JavaScriptKit/BasicObjects/JSTypedArray.swift

+2-2
Original file line numberDiff line numberDiff line change
@@ -118,11 +118,11 @@ extension UInt32: TypedArrayElement {
118118

119119
// FIXME: Support passing BigInts across the bridge
120120
//extension Int64: TypedArrayElement {
121-
// public static var typedArrayClass: JSFunctionRef { JSObjectRef.global.BigInt64Array.function! }
121+
// public static var typedArrayClass: JSFunction { JSObject.global.BigInt64Array.function! }
122122
// public static var type: JavaScriptTypedArrayKind { .bigInt64 }
123123
//}
124124
//extension UInt64: TypedArrayElement {
125-
// public static var typedArrayClass: JSFunctionRef { JSObjectRef.global.BigUint64Array.function! }
125+
// public static var typedArrayClass: JSFunction { JSObject.global.BigUint64Array.function! }
126126
// public static var type: JavaScriptTypedArrayKind { .bigUint64 }
127127
//}
128128

0 commit comments

Comments
 (0)