This week only. Pastebin PRO Accounts Christmas Special! Don't miss out!Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: maximinus on Apr 7th, 2012  |  syntax: None  |  size: 0.67 KB  |  views: 272  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. ;list of errors that all compilers should check
  2. ;all lines up to :start will be skipped by the test program
  3.  
  4. :start
  5.                 sit a, 3                ;instruction name incorrect
  6.                 set d, 4                ;wrong register name
  7.                 set a, 70000    ;integer too big
  8.                 set a, 0xfffff  ;hex value too large
  9.                 set a a                 ;no comma to seperate
  10.                 set a                   ;missing operand
  11.                 set                             ;no operands
  12. label   set a, 0                ;label has no colon
  13. loop:   set a, 0                ;label is at wrong end
  14.                 set a, [x               ;missing right square bracket
  15.                 set a, x]               ;missing left square bracket
  16.                 jsr a, a                ;too many operands on a jsr
  17.                 set a, aaa              ;no label exists
  18.                 set a, [aaa]    ;no indexed label exists
  19.                 div a, 0                ;catch compiler divide by zero errors
clone this paste RAW Paste Data