Fix some MSVC errors and warnings.

"This commit fixes as much as required to compile the project
in a cross-platform fashion. Some MSV-specific warnings are
simply ignored for now." -max
This commit is contained in:
Maxim Poliakovski 2020-02-06 15:17:40 +01:00 committed by dingusdev
parent 4b0c607ea3
commit c25aedac4b
2 changed files with 4 additions and 4 deletions

View File

@ -2,8 +2,11 @@
@author maximumspatium
*/
#define _CRT_SECURE_NO_WARNINGS /* shut up MSVC regarding the unsafe strcpy/strcat */
#include <iostream>
#include <string>
#include <functional> /* without this, MSVC doesn't understand std::function */
#include "ppcdisasm.h"
using namespace std;

View File

@ -61,7 +61,7 @@ void disasm(uint32_t inst_num = 1UL, uint32_t address = ppc_state.ppc_pc)
void enter_debugger()
{
string inp, cmd, addr_str, expr_str, reg_expr, last_cmd, inst_num_str;
string inp, cmd, addr_str, expr_str, reg_expr, last_cmd, reg_value_str, inst_string, inst_num_str;
uint32_t addr, inst_grab;
std::stringstream ss;
@ -90,9 +90,6 @@ void enter_debugger()
else if (cmd == "quit") {
break;
}
else if (cmd == "memdump") {
dump_mem_file();
}
#ifdef PROFILER
else if (cmd == "profiler") {
cout << "Number of Supervisor Instructions Executed:" << supervisor_inst_num << endl;