home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 310.lha / debug_v2.10 / syntax < prev   
Text File  |  1980-12-06  |  2KB  |  110 lines

  1. <go>        ::=    g <expression>     |
  2.             g = <expression> |
  3.             g
  4.  
  5. <trace>        ::=    t <expression>     |
  6.             t = <expression> |
  7.             t
  8.  
  9. <=>        ::=    <expression>
  10.  
  11. <mod-reg>    ::=    r <register> <expression> |
  12.             r
  13.  
  14. <load>        ::=    l <filename> <parameters> |
  15.             l <filename>
  16.  
  17. <show-segs>    ::=    S
  18.  
  19. <breakp>    ::=    b{s|c|x|t} DEC-CONSTANT <expression> |
  20.             b
  21.  
  22. <dissasemble>    ::=    d <expression> <expression> |
  23.             d <expression>             |
  24.             d
  25.  
  26. <mem-dump>    ::=    m <expression> <expression> |
  27.             m <expression>            |
  28.             m
  29.  
  30. <quit>        ::=    x 
  31.  
  32. <set-args>    ::=    c <string>    |
  33.             c
  34.  
  35. <initialize>    ::=    i
  36.  
  37. <zip>        ::=    z
  38.  
  39. <window>    ::=    w
  40.  
  41. <help>        ::=    ?
  42.  
  43. <show-syms>    ::=    s {g|d|c|b|<segment>} |
  44.             s <symbol>
  45.  
  46. <expression>    ::=    <const-term1> >> <const-exp> |
  47.             <const-term1> << <const-exp> |
  48.             <const-term1>
  49.  
  50. <const-term1>    ::=    <const-term2> + <const_term1> |
  51.             <const-term2> - <const_term1> |
  52.             <const-term2>
  53.  
  54. <const-term2>    ::=    <const-element> * <const-term2> |
  55.             <const-element> / <const-term2> |
  56.             <const-element>
  57.  
  58. <const-element>    ::=    <constant>    |
  59.             <reg-exp>    |
  60.             IDENTIFIER    |
  61.             <segment>     |
  62.             'CHAR'
  63.  
  64. <segment>    ::=    s DEC-CONSTANT
  65.  
  66. <register>    ::=    <address-reg> | 
  67.             <data-reg>
  68.  
  69. <address-reg>    ::=     a0 | a1 | a2 | a3 | a4 | a5 | a6 | a7 |
  70.             sp | pc
  71.  
  72.  
  73. <data-reg>    ::=    d0 | d1 | d2 | d3 | d4 | d5 | d6 | d7 |
  74.             sr | C | O | X | Z | N 
  75.  
  76. <reg-exp>    ::=    <constant>(register,register)    |
  77.             <constant>(register)        |
  78.             (register,register)        |
  79.             (register)
  80.             
  81. <constant>    ::=    %BIN-CONSTANT    |
  82.             $HEX-CONSTANT    |
  83.             +DEC-CONSTANT    |
  84.             -DEC-CONSTANT    |
  85.             HEX-CONSTANT
  86.  
  87.  
  88.  
  89.  
  90. Notes:
  91.  
  92.     A sub-command must be followed by whitespace to avoid confusion. Thus
  93.     we type: ps 1, not ps1. Otherwise the parser would either return the
  94.     value for segment 1, or try to find the symbol 's1'.
  95.  
  96.  
  97. Example Parsing:
  98.  
  99. <go>:
  100.     if ( GetEqual() )        ; Test for equal sign
  101.         {
  102.         GetExpression()
  103.         go-at-expression-result
  104.         }
  105.     else
  106.         {
  107.         GetExpression()
  108.         go-to-expression-result
  109.         }
  110.