Lolly 1.4.28
Loading...
Searching...
No Matches
shared_lib.cpp
Go to the documentation of this file.
1
2/** \file shared_lib.cpp
3 * \copyright GPLv3
4 * \details dynamic (shared) library related routines
5 * \author jingkaimori
6 * \date 2024
7 */
8
9#include "shared_lib.hpp"
10
11#ifndef OS_WASM
12namespace lolly {
13namespace system {
14
16 : dynamic_ref (tb_dynamic_init (c_string (as_system_string (path)))),
18 if (dynamic_ref == nullptr) {
19 TM_FAILED ("error occurs during loading of library")
20 }
21};
24 shared_lib::instances->reset (res_name);
25};
26
27shared_lib
29 return make (shared_lib, name, tm_new<shared_lib_rep> (name, path));
30}
31
32} // namespace system
33} // namespace lolly
34#endif
#define TM_FAILED(msg)
Macro used to throw an exception with a specified error message.
Definition basic.hpp:93
The list class represents a linked list.
Definition list.hpp:48
Definition url.hpp:37
shared_lib load_shared_library(string name, url path)
#define make(T, s, im)
Definition resource.hpp:62
shared_lib_rep(string dynamic_name, url path)
base class of resources
Definition resource.hpp:23
string as_system_string(url u)
Definition url.hpp:245