File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11#if defined __cplusplus
22 #include < nanobind/nanobind.h>
33 #include < nanobind/stl/string.h>
4- #include < LIEF/errors.hpp>
4+ #include < nanobind/stl/unique_ptr.h>
5+ #include < nanobind/make_iterator.h>
6+
7+ #include < string>
58 #include < sstream>
69 #include < ostream>
710 #include < memory>
811 #include < vector>
12+ #include < algorithm>
13+ #include < cstdint>
914#else
1015 #include < stdint.h>
1116 #include < stddef.h>
Original file line number Diff line number Diff line change 2424#include " LIEF/PE/DataDirectory.hpp"
2525#include " LIEF/PE/Builder.hpp"
2626#include " LIEF/PE/ResourcesManager.hpp"
27- #include " LIEF/PE/ExceptionInfo.hpp"
2827#include " LIEF/PE/signature/Signature.hpp"
2928
3029#include " LIEF/COFF/Symbol.hpp"
Original file line number Diff line number Diff line change 1616#ifndef LIEF_ERROR_H
1717#define LIEF_ERROR_H
1818#include < cstdint>
19- #include < cstdint >
19+ #include < string >
2020#include < LIEF/compiler_attributes.hpp>
2121#include < LIEF/third-party/expected.hpp>
2222
@@ -126,5 +126,13 @@ inline bool is_err(const ok_error_t& val) {
126126
127127}
128128
129+ extern template class tl ::expected<LIEF ::ok_t , lief_errors>;
130+ extern template class LIEF ::result<LIEF ::ok_t >;
131+ extern template class tl ::expected<uint64_t , lief_errors>;
132+ extern template class LIEF ::result<uint64_t >;
133+ extern template class tl ::expected<uint32_t , lief_errors>;
134+ extern template class LIEF ::result<uint32_t >;
135+ extern template class tl ::expected<std::string, lief_errors>;
136+ extern template class LIEF ::result<std::string>;
129137
130138#endif
Original file line number Diff line number Diff line change 1313 * See the License for the specific language governing permissions and
1414 * limitations under the License.
1515 */
16+ #define LIEF_ERRORS_IMPL
1617#include " LIEF/errors.hpp"
1718
19+ template class tl ::expected<LIEF ::ok_t , lief_errors>;
20+ template class LIEF ::result<LIEF ::ok_t >;
21+ template class tl ::expected<uint64_t , lief_errors>;
22+ template class LIEF ::result<uint64_t >;
23+ template class tl ::expected<uint32_t , lief_errors>;
24+ template class LIEF ::result<uint32_t >;
25+ template class tl ::expected<std::string, lief_errors>;
26+ template class LIEF ::result<std::string>;
27+
1828const char * to_string (lief_errors err) {
1929 switch (err) {
2030 case lief_errors::read_error: return " read_error" ;
Original file line number Diff line number Diff line change 33#if defined __cplusplus
44 #include " spdlog/spdlog.h"
55 #include < spdlog/fmt/fmt.h>
6+ #include < spdlog/fmt/ranges.h>
7+
68 #include < string>
9+ #include < vector>
710 #include < set>
11+ #include < map>
12+ #include < unordered_map>
13+ #include < array>
814 #include < memory>
15+ #include < algorithm>
916 #include < cstdint>
1017 #include < cstddef>
18+ #include < ostream>
19+ #include < sstream>
20+
1121 #if LIEF_JSON_SUPPORT
1222 #ifndef LIEF_NLOHMANN_JSON_EXTERNAL
1323 #include " internal/nlohmann/json.hpp"
You can’t perform that action at this time.
0 commit comments