From 9260acce31ad3fa71daa208c5ecb4c380b65e7ee Mon Sep 17 00:00:00 2001 From: modeco80 Date: Tue, 18 Jul 2023 06:01:32 -0400 Subject: [PATCH] oops --- native/projects/lucore/src/Library.cpp | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/native/projects/lucore/src/Library.cpp b/native/projects/lucore/src/Library.cpp index bf82a32..5899b2d 100644 --- a/native/projects/lucore/src/Library.cpp +++ b/native/projects/lucore/src/Library.cpp @@ -11,15 +11,13 @@ namespace lucore { #ifdef _WIN32 return std::format("{}.dll", dllName); #else - return - std::format("lib{}.so", dllName); + return std::format("lib{}.so", dllName); #endif } } // namespace Library* Library::Open(std::string_view dllname) { - return new Library( - static_cast(detail::OsOpenLibrary(FormatLibraryName(dllname).c_str()))); + return new Library(detail::OsOpenLibrary(FormatLibraryName(dllname).c_str())); } bool Library::Loaded(std::string_view dllname) { @@ -28,11 +26,11 @@ namespace lucore { Library::~Library() { if(handle) { - detail::OsFreeLibrary(static_cast(handle)); + detail::OsFreeLibrary(handle); } } void* Library::SymbolImpl(const char* symbolName) { - return detail::OsLibrarySymbol(static_cast(handle), symbolName); + return detail::OsLibrarySymbol(handle, symbolName); } } // namespace lucore