Skip to content

Commit

Permalink
✨ print errors to stderr
Browse files Browse the repository at this point in the history
  • Loading branch information
GalaxyShad committed May 12, 2024
1 parent 6bc0843 commit b810ce5
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions SomeAsmTranslator/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace I8080Translator;

partial class Program
{
static private readonly ListingGenerator _listingGenerator = new();
private static readonly ListingGenerator _listingGenerator = new();

static void Main(string[] args)
{
Expand Down Expand Up @@ -59,7 +59,7 @@ static void RunOptions(ArgumentsOptions opts)
}
catch (Exception ex)
{
Console.WriteLine(ex.Message);
Console.Error.WriteLine(ex.Message);
}
#endif
}
Expand Down
4 changes: 2 additions & 2 deletions SomeAsmTranslator/Source/Assembler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -298,9 +298,9 @@ private AssembledAssemblyStatement CompileInstruction(AssemblyStatement statemen
}

var instructionArgs = new List<object>();
foreach (var (CompilerFunction, Operand) in instructionParamInfo.Zip(statement.OperandList.Operands))
foreach (var (compilerFunction, operand) in instructionParamInfo.Zip(statement.OperandList.Operands))
{
ConvertOperandsToInstructionData(assembled, instructionArgs, CompilerFunction, Operand);
ConvertOperandsToInstructionData(assembled, instructionArgs, compilerFunction, operand);
}

uint code = (uint)instruction.Invoke(_instructionTranslator, instructionArgs.ToArray())!;
Expand Down
2 changes: 1 addition & 1 deletion SomeAsmTranslator/TestData/1.asm
Original file line number Diff line number Diff line change
@@ -1 +1 @@
DW 1234H
DW 1234Hs

0 comments on commit b810ce5

Please sign in to comment.