0

Why Java creators decided not to throw any error or exception when overflow or underflow hapens considering the fact that such scenarios are usually lethal for any software.

Praveen Kumar
  • 1,624
  • 5
  • 18
  • 21
  • what kind of overflow or underflow are you talking about? stack? buffer? There are some such exceptions, for example http://docs.oracle.com/javase/7/docs/api/java/nio/BufferOverflowException.html. Besides, stack overflow error exists.... http://docs.oracle.com/javase/7/docs/api/java/lang/StackOverflowError.html – Arnaud Potier Mar 18 '14 at 09:15
  • I am talking about arithmetic overflow or underflow , say when we add two integers and the result is out of range of integer. – Praveen Kumar Mar 18 '14 at 09:35

0 Answers0