Improve utilities

This commit is contained in:
gingerBill
2022-04-15 11:33:28 +01:00
parent cfeb16f917
commit 6b7c04e046
3 changed files with 23 additions and 4 deletions
+5
View File
@@ -11,4 +11,9 @@ foreign Metal {
CopyAllDevicesWithObserver :: proc(observer: ^id, handler: DeviceNotificationHandler) -> ^NS.Array ---
CreateSystemDefaultDevice :: proc() -> ^Device ---
RemoveDeviceObserver :: proc(observer: id) ---
}
new :: proc($T: typeid) -> ^T where intrinsics.type_is_subtype_of(T, NS.Object) {
return T.alloc()->init()
}