ソースの推敲
authorj8takagi <j8takagi@nifty.com>
Wed, 6 Feb 2019 12:57:29 +0000 (21:57 +0900)
committerj8takagi <j8takagi@nifty.com>
Wed, 6 Feb 2019 12:57:29 +0000 (21:57 +0900)
src/dump.c
src/struct.c

index d00d274..45f6706 100644 (file)
@@ -39,7 +39,7 @@ void dspregister()
     char *sp, *pr, *fr;
     for(i = 0; i < GRSIZE; i++ ) {
         fprintf(stdout, "#%04X: GR%d: ", sys->cpu->pr, i);
-        print_dumpword(sys->cpu->gr[i], (&execmode)->logical);
+        print_dumpword(sys->cpu->gr[i], execmode.logical);
         fprintf(stdout, "\n");
     }
     fprintf(stdout, "#%04X: SP:  %6d = #%04X = %s\n",
index 22a7df3..cc4d986 100644 (file)
@@ -122,7 +122,7 @@ bool create_cmdtable(CMDTAB_HASH hash)
         if(hash == HASH_CMDTYPE) {
             hashval = hash_cmdtype(comet2cmd[i].name, comet2cmd[i].type);
         } else if(hash == HASH_CODE) {
-            hashval = hash_code((&comet2cmd[i])->code);
+            hashval = hash_code(comet2cmd[i].code);
         }
         p->next = cmdtab[hash][hashval];
         cmdtab[hash][hashval] = p;