code_junkie

How does a Java compiler parse typecasts?

Nov 13th, 2011
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.20 KB | None | 0 0
  1. (x) - y
  2.  
  3. CastExpression:
  4. ( PrimitiveType Dimsopt ) UnaryExpression
  5. ( ReferenceType ) UnaryExpressionNotPlusMinus
  6.  
  7. Double y = new Double(0.1);
  8. System.out.println((Double)-y);
Add Comment
Please, Sign In to add comment