clean up dynlib and path/filepath with sys/posix
This commit is contained in:
1 parent
afed3ce6b5
commit
0b4a4212bb
5 files changed
+40
-53
No files matched your search
@@ -37,8 +37,8 @@ Example:
|
||||
fmt.println("The library %q was successfully loaded", LIBRARY_PATH)
|
||||
}
|
||||
*/
|
||||
load_library :: proc(path: string, global_symbols := false) -> (library: Library, did_load: bool) {
|
||||
return _load_library(path, global_symbols)
|
||||
load_library :: proc(path: string, global_symbols := false, allocator := context.temp_allocator) -> (library: Library, did_load: bool) {
|
||||
return _load_library(path, global_symbols, allocator)
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -98,8 +98,8 @@ Example:
|
||||
}
|
||||
}
|
||||
*/
|
||||
symbol_address :: proc(library: Library, symbol: string) -> (ptr: rawptr, found: bool) #optional_ok {
|
||||
return _symbol_address(library, symbol)
|
||||
symbol_address :: proc(library: Library, symbol: string, allocator := context.temp_allocator) -> (ptr: rawptr, found: bool) #optional_ok {
|
||||
return _symbol_address(library, symbol, allocator)
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -174,4 +174,4 @@ initialize_symbols :: proc(
|
||||
// Returns an error message for the last failed procedure call.
|
||||
last_error :: proc() -> string {
|
||||
return _last_error()
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user