History

Change debugger options to enumeration. Alter how the debugger displays the registers. Adding a breakpoint that is already set is a no-op and simply returns the current cookie value. Fix bug in print for the Sys module - don't ignore format modifiers.

arr committed 10 years ago

Commit db76c0c1 parent f29cf0d6 files · +45 −41Browse files

Showing the changes to src/exec/main.cpp (1 of 6 files). Show all

Unified · Split

src/exec/main.cpp+5−5
@@ -195,7 +195,7 @@ struct arg_exception_t : std::runtime_error · 194 unmodified lines
195195 struct exec_options
196196 {
197197 exec_options()
198− : debugger{}
198+ : debugger{ debugger_options::none }
199199 , enabled_debugger{ false }
200200 , quiet_start{ false }
201201 , print_help{ false }
@@ -227,7 +227,7 @@ void print_banner(const exec_options &options) · 25 unmodified lines
227227 << "System thread usage: " << options.sys_thread_count << "\n";
228228
229229 if (options.enabled_debugger)
230− std::cout << options.debugger << "\n";
230+ std::cout << "\n" << options.debugger << "\n";
231231
232232 std::cout << std::endl;
233233 }
@@ -268,11 +268,11 @@ void process_arg(char* arg, std::function<char *()> next, exec_options &options) · 34 unmodified lines
268268 {
269269 switch (arg[i])
270270 {
271− case 'e': options.debugger.break_on_enter = true;
271+ case 'e': options.debugger |= debugger_options::break_on_enter;
272272 break;
273− case 'm': options.debugger.break_on_module_load = true;
273+ case 'm': options.debugger |= debugger_options::break_on_module_load;
274274 break;
275− case 'x': options.debugger.break_on_exception = true;
275+ case 'x': options.debugger |= debugger_options::break_on_exception;
276276 break;
277277 }
278278 }