Merge pull request #163 from lioncash/dsp-func-typo

Fix a typo in DSPSymbols. (DisasssembleRange -> DisassembleRange)
This commit is contained in:
Pierre Bourdon 2014-03-13 01:54:14 +01:00
commit 107d4ca224

View File

@ -2,6 +2,7 @@
// Licensed under GPLv2 // Licensed under GPLv2
// Refer to the license.txt file included. // Refer to the license.txt file included.
#include <cctype>
#include <list> #include <list>
#include <map> #include <map>
#include <string> #include <string>
@ -14,7 +15,8 @@
#include "Core/DSP/DSPDisassembler.h" #include "Core/DSP/DSPDisassembler.h"
#include "Core/HW/DSPLLE/DSPSymbols.h" #include "Core/HW/DSPLLE/DSPSymbols.h"
namespace DSPSymbols { namespace DSPSymbols
{
DSPSymbolDB g_dsp_symbol_db; DSPSymbolDB g_dsp_symbol_db;
@ -73,42 +75,9 @@ Symbol *DSPSymbolDB::GetSymbolFromAddr(u32 addr)
return nullptr; return nullptr;
} }
// lower case only void DisassembleRange(u16 start, u16 end)
bool IsHexDigit(char c)
{ {
switch (c) // TODO: ?
{
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
case 'a':
case 'b':
case 'c':
case 'd':
case 'e':
case 'f':
return true;
default:
return false;
}
}
bool IsAlpha(char c)
{
return (c >= 'A' && c <= 'Z') ||
(c >= 'a' && c <= 'z');
}
void DisasssembleRange(u16 start, u16 end)
{
} }
bool ReadAnnotatedAssembly(const char *filename) bool ReadAnnotatedAssembly(const char *filename)
@ -141,7 +110,7 @@ bool ReadAnnotatedAssembly(const char *filename)
for (unsigned int i = 0; i < strlen(line); i++) for (unsigned int i = 0; i < strlen(line); i++)
{ {
const char c = line[i]; const char c = line[i];
if (IsHexDigit(c)) if (isxdigit(c))
{ {
if (first_hex == -1) if (first_hex == -1)
{ {
@ -165,7 +134,7 @@ bool ReadAnnotatedAssembly(const char *filename)
{ {
first_hex = -1; first_hex = -1;
} }
if (IsAlpha(c)) if (isalpha(c))
break; break;
} }
} }