summaryrefslogtreecommitdiff
path: root/Source/DSPTool/DSPTool.cpp
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2019-05-28 17:45:36 -0400
committerLioncash <mathew1800@gmail.com>2019-05-29 07:06:53 -0400
commiteb475025b85686f4793bb83bac377033c17fbd2d (patch)
tree3a5c8e36cab1dae1e4e36ef243d44f540f2c55f1 /Source/DSPTool/DSPTool.cpp
parent992c8bfc4e2394ad5786f5116f5e62ae595b5c44 (diff)
Common/FileUtil: Make WriteStringToFile consistent with ReadFileToString
Makes the parameter ordering consistent and less error-prone.
Diffstat (limited to 'Source/DSPTool/DSPTool.cpp')
-rw-r--r--Source/DSPTool/DSPTool.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/Source/DSPTool/DSPTool.cpp b/Source/DSPTool/DSPTool.cpp
index 0c02a617dd..618c97e7af 100644
--- a/Source/DSPTool/DSPTool.cpp
+++ b/Source/DSPTool/DSPTool.cpp
@@ -217,7 +217,7 @@ static void PrintResults(const std::string& input_name, const std::string& outpu
if (output_name.empty())
printf("%s", results.c_str());
else
- File::WriteStringToFile(results, output_name.c_str());
+ File::WriteStringToFile(output_name, results);
}
static bool PerformDisassembly(const std::string& input_name, const std::string& output_name)
@@ -237,7 +237,7 @@ static bool PerformDisassembly(const std::string& input_name, const std::string&
if (output_name.empty())
printf("%s", text.c_str());
else
- File::WriteStringToFile(text, output_name);
+ File::WriteStringToFile(output_name, text);
printf("Disassembly completed successfully!\n");
return true;
@@ -314,7 +314,7 @@ static bool PerformAssembly(const std::string& input_name, const std::string& ou
}
const std::string header = CodesToHeader(codes, files);
- File::WriteStringToFile(header, output_header_name + ".h");
+ File::WriteStringToFile(output_header_name + ".h", header);
}
else
{
@@ -334,12 +334,12 @@ static bool PerformAssembly(const std::string& input_name, const std::string& ou
if (!output_name.empty())
{
const std::string binary_code = DSP::CodeToBinaryStringBE(code);
- File::WriteStringToFile(binary_code, output_name);
+ File::WriteStringToFile(output_name, binary_code);
}
if (!output_header_name.empty())
{
const std::string header = CodeToHeader(code, input_name);
- File::WriteStringToFile(header, output_header_name + ".h");
+ File::WriteStringToFile(output_header_name + ".h", header);
}
}
}