Changeset 3f44ecfab72cfb21d66e7a3075cfec2b3f7c8773

User picture

Commiter: Charles Childers

Author: Charles Childers

Parent: 3125a52331

(2010/03/11 03:26) Almost 2 years ago

update decompiler to show <call> for implicit calls; fix bug on items with no name

Affected files

Updated image/source/debug.retro Download diff

3125a52331ae6d7a6bb77d0ce92a95ddc25805473f44ecfab72cfb21d66e7a3075cfec2b3f7c8773
44
  : resolve   ( -   ) addr @ @ xt->d dup if name ;then drop ;
44
  : resolve   ( -   ) addr @ @ xt->d dup if name ;then drop ;
45
  : .op       ( a-  ) dup getLength swap type 10 swap -
45
  : .op       ( a-  ) dup getLength swap type 10 swap -
46
                      dup 0 <if drop space ;then for space next ;
46
                      dup 0 <if drop space ;then for space next ;
47
  : .value    (  -  ) addr ++ addr @ @ . pad resolve drop ;
47
  : .word     (  -  ) addr @ @ . pad resolve drop ;
48
  : .value    (  -  ) addr ++ .word ;
48
49
49
  ( ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ )
50
  ( ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ )
50
  ( Table words                                                 )
51
  ( Table words                                                 )
...
...
104
  : .quote ( a- ) char: ' emit dup emit char: ' emit space ;
105
  : .quote ( a- ) char: ' emit dup emit char: ' emit space ;
105
  : .ascii?   ( a- )
106
  : .ascii?   ( a- )
106
    dup 32 128 within if ." Char: " .quote .paren ;then
107
    dup 32 128 within if ." Char: " .quote .paren ;then
107
    dup xt->d d->name .op .paren ;
108
    drop s" <call>" .op .word ;; dup xt->d d->name .op .paren ;
108
109
109
  : decompile ( - )
110
  : decompile ( - )
110
    addr @ @ dup 0 30 within
111
    addr @ @ dup 0 30 within