about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorKartik Agaram <vc@akkartik.com>2018-07-25 10:38:16 -0700
committerKartik Agaram <vc@akkartik.com>2018-07-25 10:38:16 -0700
commit0a10402b7c2c8daacc88d8f402fdfe1962f6ffec (patch)
treeb62d32971e95432aa972dd212ebb10a19ab2b802
parent7412e6eef8c2449d543836c30ec94381bfaeec23 (diff)
downloadmu-0a10402b7c2c8daacc88d8f402fdfe1962f6ffec.tar.gz
4400 - fix a couple of warnings
Thanks Max Bernstein. Fixes #7.
-rw-r--r--subx/020elf.cc1
-rw-r--r--subx/023check_operand_sizes.cc4
2 files changed, 2 insertions, 3 deletions
diff --git a/subx/020elf.cc b/subx/020elf.cc
index 2c162ddf..62743a98 100644
--- a/subx/020elf.cc
+++ b/subx/020elf.cc
@@ -102,7 +102,6 @@ void load_segment_from_program_header(uint8_t* elf_contents, size_t size, uint32
 //   stack: 0x0804bfff -> 0x0804b000 (downward)
 const int CODE_START = 0x08048000;
 const int SEGMENT_SIZE = 0x1000;
-const int DATA_START = 0x08049000;
 const int AFTER_STACK = 0x0804c000;
 :(code)
 void initialize_mem() {
diff --git a/subx/023check_operand_sizes.cc b/subx/023check_operand_sizes.cc
index b6a96a1f..5d2ec456 100644
--- a/subx/023check_operand_sizes.cc
+++ b/subx/023check_operand_sizes.cc
@@ -68,11 +68,11 @@ uint32_t parse_int(const string& s) {
 }
 
 void check_metadata_present(const line& inst, const string& type, uint8_t op) {
-  if (!has_metadata(inst, type, op))
+  if (!has_metadata(inst, type))
     raise << "'" << to_string(inst) << "' (" << get(name, op) << "): missing " << type << " operand\n" << end();
 }
 
-bool has_metadata(const line& inst, const string& m, uint8_t op) {
+bool has_metadata(const line& inst, const string& m) {
   bool result = false;
   for (int i = 0;  i < SIZE(inst.words);  ++i) {
     if (!has_metadata(inst.words.at(i), m)) continue;