ROBOTC.net forums
http://robotc.net/forums/

[Bug] Divide by Zero Crash
http://robotc.net/forums/viewtopic.php?f=11&t=6400
Page 1 of 1

Author:  edjubuh [ Sun Jul 28, 2013 7:05 pm ]
Post subject:  [Bug] Divide by Zero Crash

I recently ran into a bug with the ROBOTC compiler where dividing by zero does not prevent compilation and downloading. As a result, ROBOTC crashes. Also, when using joystick values in trigonometry functions and they are at zero, ROBOTC crashes then as well. I thought I should make you guys aware of these bugs. I can (and should've) worked around the trig issue, but dividing by zero does not create issues. The line I tested was
Code:
int line = 10/0;
. It reports an error
Quote:
**Error**:Constant expression division by zero
, but doesn't prevent compilation.

Page 1 of 1 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/