1. I haven't work with the RC1, but older betas of 1.5 , and also the prototype compilers. If the demo you are compiling is for somethin specific for java 1.5 (like generics),
To compile with Beta version use:
javac -source 1.5 aa.java
2. anyway , first try checking that the class defined inside demo.java is not Demo.java (d-D) or something (to err, as they say.....)
Hope it helps. Please keep us posted abt. the result.
-Rahul