diff --git a/IntegrationTests/TestSuites/Sources/BenchmarkTests/Benchmark.swift b/IntegrationTests/TestSuites/Sources/BenchmarkTests/Benchmark.swift index 0c5712575..bd145c3ac 100644 --- a/IntegrationTests/TestSuites/Sources/BenchmarkTests/Benchmark.swift +++ b/IntegrationTests/TestSuites/Sources/BenchmarkTests/Benchmark.swift @@ -6,7 +6,7 @@ class Benchmark { } let title: String - let runner: JSFunctionRef = JSObjectRef.global.benchmarkRunner.function! + let runner = JSObject.global.benchmarkRunner.function! func testSuite(_ name: String, _ body: @escaping () -> Void) { let jsBody = JSClosure { arguments -> JSValue in diff --git a/IntegrationTests/TestSuites/Sources/BenchmarkTests/main.swift b/IntegrationTests/TestSuites/Sources/BenchmarkTests/main.swift index ded1eb5b1..df11f6f14 100644 --- a/IntegrationTests/TestSuites/Sources/BenchmarkTests/main.swift +++ b/IntegrationTests/TestSuites/Sources/BenchmarkTests/main.swift @@ -5,7 +5,7 @@ let serialization = Benchmark("Serialization") let swiftInt: Double = 42 serialization.testSuite("Swift Int to JavaScript") { let jsNumber = JSValue.number(swiftInt) - let object = JSObjectRef.global + let object = JSObject.global for i in 0 ..< 100 { object["numberValue\(i)"] = jsNumber } @@ -14,7 +14,7 @@ serialization.testSuite("Swift Int to JavaScript") { let swiftString = "Hello, world" serialization.testSuite("Swift String to JavaScript") { let jsString = JSValue.string(swiftString) - let object = JSObjectRef.global + let object = JSObject.global for i in 0 ..< 100 { object["stringValue\(i)"] = jsString } @@ -22,7 +22,7 @@ serialization.testSuite("Swift String to JavaScript") { let objectHeap = Benchmark("Object heap") -let global = JSObjectRef.global +let global = JSObject.global let Object = global.Object.function! global.objectHeapDummy = .object(Object.new()) objectHeap.testSuite("Increment and decrement RC") { diff --git a/Sources/JavaScriptKit/BasicObjects/JSTypedArray.swift b/Sources/JavaScriptKit/BasicObjects/JSTypedArray.swift index 4f7facfc0..0994708ce 100644 --- a/Sources/JavaScriptKit/BasicObjects/JSTypedArray.swift +++ b/Sources/JavaScriptKit/BasicObjects/JSTypedArray.swift @@ -118,11 +118,11 @@ extension UInt32: TypedArrayElement { // FIXME: Support passing BigInts across the bridge //extension Int64: TypedArrayElement { -// public static var typedArrayClass: JSFunctionRef { JSObjectRef.global.BigInt64Array.function! } +// public static var typedArrayClass: JSFunction { JSObject.global.BigInt64Array.function! } // public static var type: JavaScriptTypedArrayKind { .bigInt64 } //} //extension UInt64: TypedArrayElement { -// public static var typedArrayClass: JSFunctionRef { JSObjectRef.global.BigUint64Array.function! } +// public static var typedArrayClass: JSFunction { JSObject.global.BigUint64Array.function! } // public static var type: JavaScriptTypedArrayKind { .bigUint64 } //}