2023-03-10 10:32:50 +00:00
|
|
|
// This file is part of noxos and licensed under the MIT open source license
|
2023-02-28 20:13:51 +00:00
|
|
|
|
|
|
|
#ifndef NOX_SYMBOLS_H
|
|
|
|
#define NOX_SYMBOLS_H
|
|
|
|
|
|
|
|
#include "utils/string.h"
|
|
|
|
|
|
|
|
typedef enum {
|
|
|
|
SYMBOL_FUNCTION,
|
|
|
|
SYMBOL_VARIABLE,
|
|
|
|
SYMBOL_UNKNOWN
|
|
|
|
} symbol_type_E;
|
|
|
|
|
|
|
|
typedef struct {
|
|
|
|
string_t name;
|
|
|
|
symbol_type_E type;
|
|
|
|
uint64_t address;
|
|
|
|
} symbol_T;
|
|
|
|
|
2023-03-02 12:34:05 +00:00
|
|
|
symbol_T* symbol_resolve_from_name (symbol_T* symbols, uint64_t num_symbols, string_t name);
|
2023-03-08 23:43:15 +00:00
|
|
|
symbol_T* symbol_resolve_from_rip (symbol_T* symbols, uint64_t num_symbols, uint64_t rip);
|
2023-03-01 20:58:14 +00:00
|
|
|
|
2023-02-28 20:13:51 +00:00
|
|
|
#endif //NOX_SYMBOLS_H
|