mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-06-13 07:32:23 -07:00
fix clang builds
This commit is contained in:
@@ -118,6 +118,10 @@ update(void)
|
||||
#if defined(TEXTURE_CACHE_H)
|
||||
tex_user_clock_tick();
|
||||
#endif
|
||||
#if OS_FEATURE_GRAPHICAL
|
||||
B32 result = frame();
|
||||
#else
|
||||
B32 result = 0;
|
||||
#endif
|
||||
return result;
|
||||
}
|
||||
|
||||
@@ -688,18 +688,6 @@ EV_VIEW_RULE_EXPR_EXPAND_NUM_FROM_ID_FUNCTION_DEF(globals);
|
||||
EV_VIEW_RULE_EXPR_EXPAND_NUM_FROM_ID_FUNCTION_DEF(thread_locals);
|
||||
EV_VIEW_RULE_EXPR_EXPAND_NUM_FROM_ID_FUNCTION_DEF(types);
|
||||
EV_VIEW_RULE_EXPR_EXPAND_NUM_FROM_ID_FUNCTION_DEF(procedures);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(watches);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(targets);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(breakpoints);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(watch_pins);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(threads);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(modules);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(locals);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(registers);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(globals);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(thread_locals);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(types);
|
||||
EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF(procedures);
|
||||
RD_VIEW_RULE_UI_FUNCTION_DEF(null);
|
||||
EV_VIEW_RULE_EXPR_EXPAND_INFO_FUNCTION_DEF(text);
|
||||
EV_VIEW_RULE_EXPR_EXPAND_INFO_FUNCTION_DEF(disasm);
|
||||
|
||||
@@ -841,7 +841,6 @@ RD_CollectionTable:
|
||||
@expand(RD_CollectionTable a) `EV_VIEW_RULE_EXPR_EXPAND_RANGE_INFO_FUNCTION_DEF($(a.name));`;
|
||||
@expand(RD_CollectionTable a) `$(a.id_space == x -> "EV_VIEW_RULE_EXPR_EXPAND_ID_FROM_NUM_FUNCTION_DEF("..a.name..");")`;
|
||||
@expand(RD_CollectionTable a) `$(a.id_space == x -> "EV_VIEW_RULE_EXPR_EXPAND_NUM_FROM_ID_FUNCTION_DEF("..a.name..");")`;
|
||||
@expand(RD_CollectionTable a) `EV_VIEW_RULE_BLOCK_PROD_FUNCTION_DEF($(a.name));`;
|
||||
}
|
||||
|
||||
@data(String8) rd_collection_name_table:
|
||||
|
||||
@@ -562,6 +562,7 @@ rd_rgba_from_entity(RD_Entity *entity)
|
||||
}
|
||||
else switch(entity->kind)
|
||||
{
|
||||
default:{}break;
|
||||
case RD_EntityKind_Breakpoint:
|
||||
{
|
||||
result = rd_rgba_from_theme_color(RD_ThemeColor_Breakpoint);
|
||||
|
||||
@@ -2854,6 +2854,11 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
|
||||
palette = ui_build_palette(ui_top_palette(), .text = rd_rgba_from_theme_color(RD_ThemeColor_TextNegative), .text_weak = rd_rgba_from_theme_color(RD_ThemeColor_TextNegative), .background = rd_rgba_from_theme_color(RD_ThemeColor_HighlightOverlayError));
|
||||
cell_flags |= UI_BoxFlag_DrawBackground;
|
||||
}
|
||||
else if(cell_inheritance_string.size != 0)
|
||||
{
|
||||
palette = ui_build_palette(ui_top_palette(), .background = rd_rgba_from_theme_color(RD_ThemeColor_HighlightOverlay));
|
||||
cell_flags |= UI_BoxFlag_DrawBackground;
|
||||
}
|
||||
else
|
||||
{
|
||||
palette = ui_build_palette(ui_top_palette(), .text = cell_base_color);
|
||||
@@ -2864,6 +2869,7 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
|
||||
B32 cell_is_code = !col->is_non_code;
|
||||
switch(col->kind)
|
||||
{
|
||||
default:{}break;
|
||||
case RD_WatchViewColumnKind_Expr:
|
||||
{
|
||||
cell_is_code = 1;
|
||||
@@ -2893,8 +2899,10 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
|
||||
UI_FocusHot(cell_selected ? UI_FocusKind_On : UI_FocusKind_Off)
|
||||
UI_FocusActive((cell_selected && ewv->text_editing) ? UI_FocusKind_On : UI_FocusKind_Off)
|
||||
RD_Font(cell_is_code ? RD_FontSlot_Code : RD_FontSlot_Main)
|
||||
UI_FlagsAdd(cell_flags | (row_depth > 0 ? UI_BoxFlag_DrawTextWeak : 0))
|
||||
UI_FlagsAdd(row_depth > 0 ? UI_BoxFlag_DrawTextWeak : 0)
|
||||
{
|
||||
ui_set_next_flags(ui_top_flags() | cell_flags);
|
||||
|
||||
// rjf: cell has errors? -> build error box
|
||||
if(cell_error_string.size != 0) RD_Font(RD_FontSlot_Main)
|
||||
{
|
||||
@@ -3019,7 +3027,7 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
|
||||
// rjf: hovering with inheritance string -> show tooltip
|
||||
if(ui_hovering(sig) && cell_inheritance_string.size != 0) UI_Tooltip
|
||||
{
|
||||
UI_PrefWidth(ui_children_sum(1)) UI_Row UI_PrefWidth(ui_text_dim(1, 1))
|
||||
UI_PrefWidth(ui_children_sum(1)) UI_Row UI_PrefWidth(ui_text_dim(1, 1)) UI_TextPadding(0)
|
||||
{
|
||||
ui_labelf("Inherited from ");
|
||||
RD_Font(RD_FontSlot_Code) rd_code_label(1.f, 0, rd_rgba_from_theme_color(RD_ThemeColor_CodeDefault), cell_inheritance_string);
|
||||
|
||||
@@ -1070,6 +1070,9 @@ static DWARF_FormDecodeRules
|
||||
dwarf_form_decode_rule(DWARF_AttributeForm form, U64 address_size, U64 offset_size){
|
||||
DWARF_FormDecodeRules result = {0};
|
||||
switch (form){
|
||||
case DWARF_AttributeForm_null:
|
||||
case DWARF_AttributeForm_indirect:{}break;
|
||||
|
||||
case DWARF_AttributeForm_addr: result.size = address_size; break;
|
||||
case DWARF_AttributeForm_addrx: result.uleb128 = 1; break;
|
||||
case DWARF_AttributeForm_addrx1: result.size = 1; break;
|
||||
@@ -1286,6 +1289,7 @@ static String8
|
||||
dwarf_string_from_section_code(DWARF_SectionCode sec_code){
|
||||
String8 result = str8_lit("unrecognized_section_code");
|
||||
switch (sec_code){
|
||||
case DWARF_SectionCode_COUNT:{}break;
|
||||
#define X(Nc,Vf,N0,N1,N2) case DWARF_SectionCode_##Nc: result = str8_lit(#Nc); break;
|
||||
DWARF_SectionNameXList(X,0,0)
|
||||
#undef X
|
||||
|
||||
@@ -1240,7 +1240,7 @@ typedef struct DWARF_LocListsParsed{
|
||||
////////////////////////////////
|
||||
//~ Dwarf Decode Helpers
|
||||
|
||||
#define DWARF_LEB128_ADV(p,o,s) do{ for(;; (p)+=1){\
|
||||
#define DWARF_LEB128_ADV(p,o,s) do{ (s)=1; for(;; (p)+=1){\
|
||||
if ((p) == (o)) { (s)=0; break; } \
|
||||
if (((*(p))&0x80) == 0) { (p)+=1; break; } \
|
||||
} }while(0)
|
||||
|
||||
@@ -476,6 +476,8 @@ elf_sym_array_from_data(Arena *arena, ELF_Class elf_class, String8 data){
|
||||
ELF_Sym64 *symbols = 0;
|
||||
U64 count = 0;
|
||||
switch (elf_class){
|
||||
default:{}break;
|
||||
|
||||
case ELF_Class_32:
|
||||
{
|
||||
count = data.size/sizeof(ELF_Sym32);
|
||||
|
||||
Reference in New Issue
Block a user