/home/1/esb/312/longadd /home/1/esb/312/longsub /home/1/esb/312/longmul /home/1/esb/312/longdiv
m4 esb.m > esb.s gcc -o esb -g esb.s ./esb < /home/1/esb/312/longadd(if you say your program doesn't work at all, we will skip the last step).
cp mycalculator.m email.m chmod og+r email.m cp email.m /home/1/esb/312/hw5 rm email.m
parsed = parsed * 10 + (new digit - "ascii zero")where parsed is the number parsed, 10 is the number 10 in the internal representation, and the new digit is the ascii value. Of course the parse must end if the "new digit" is actually one of the operators or a non-digit, non-operator character.
ret restoreRemember that the instruction in the delay slot after the call instruction is executed before the transfer of control to the subroutine. Also remember that register values may change across subroutine calls -- do not count on values you placed in registers before the call or ret to be there afterwards. If you prefer, you can use branches instead of calls, or you are welcome to look at chapter 7 of the SPARC book.