From 51b091fb88135bbb294fe83cfdac05077912f380 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20Quei=C3=9Fner?= Date: Sat, 21 May 2016 12:45:47 +0200 Subject: [PATCH] Fixes wrong filename beeing read. --- prototypes/supervm-asm/.gitignore | 1 + prototypes/supervm-asm/assembler.cs | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) create mode 100644 prototypes/supervm-asm/.gitignore diff --git a/prototypes/supervm-asm/.gitignore b/prototypes/supervm-asm/.gitignore new file mode 100644 index 0000000..a8a0dce --- /dev/null +++ b/prototypes/supervm-asm/.gitignore @@ -0,0 +1 @@ +*.bin diff --git a/prototypes/supervm-asm/assembler.cs b/prototypes/supervm-asm/assembler.cs index 6fe8b3f..0f71984 100644 --- a/prototypes/supervm-asm/assembler.cs +++ b/prototypes/supervm-asm/assembler.cs @@ -14,12 +14,12 @@ namespace supervm_asm static void Main(string[] args) { - // MnemonicParser.GenerateFromDocumentation(@"D:\felix\projects\DasOS\prototypes\supervm\instructions.md"); + // MnemonicParser.GenerateFromDocumentation(@"../supervm/instructions.md"); foreach(var file in args.Where(a => !a.StartsWith("-") && Path.GetExtension(a) == ".asm")) { var output = Path.ChangeExtension(file, ".bin"); - var code = Assembler.Assemble(File.ReadAllText("testcode.asm")); + var code = Assembler.Assemble(File.ReadAllText(file)); Console.WriteLine("{0}:", output); for (int i = 0; i < code.Length; i++)