You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the case of an end-of-file or other file error condition, the & and ~ both act like r.
However, when it comes to the & (Input Decimal) command, FBBI goes into an infinite loop in the case of an end-of-file.
The problem is the loop at the start of the fi_idec function which tries to skip over any non-digits in the input stream. On end-of-file, a digit is never encountered so the loop never ends.
That loop is also responsible for FBBI failing to read negative numbers correctly, because the sign of the number is dropped before it gets to the scanf call.
The text was updated successfully, but these errors were encountered:
According to the specification:
However, when it comes to the
&
(Input Decimal) command, FBBI goes into an infinite loop in the case of an end-of-file.The problem is the loop at the start of the
fi_idec
function which tries to skip over any non-digits in the input stream. On end-of-file, a digit is never encountered so the loop never ends.That loop is also responsible for FBBI failing to read negative numbers correctly, because the sign of the number is dropped before it gets to the
scanf
call.The text was updated successfully, but these errors were encountered: