diff --git a/src/runtime/metal/metal_module.mm b/src/runtime/metal/metal_module.mm index 0439ba47789a..e037717bcc57 100644 --- a/src/runtime/metal/metal_module.mm +++ b/src/runtime/metal/metal_module.mm @@ -270,7 +270,7 @@ void operator()(ffi::PackedArgs args, ffi::Any* rv, const ArgUnion64* pack_args) ICHECK_EQ(sptr_to_self.get(), this); auto it = fmap_.find(name); if (it == fmap_.end()) { - return std::nullopt; + return; } const FunctionInfo& info = it->second; MetalWrappedFunc f; @@ -285,7 +285,7 @@ void operator()(ffi::PackedArgs args, ffi::Any* rv, const ArgUnion64* pack_args) ffi::Module MetalModuleCreate(std::unordered_map smap, std::unordered_map fmap, std::string fmt, std::string source) { - ObjectPtr n; + ObjectPtr n; AUTORELEASEPOOL { n = ffi::make_object(smap, fmap, fmt, source); }; return ffi::Module(n); }