Bug? For variable not found

mc73

Well-Known Member
Licensed User
Longtime User
After updating from 5.00 to 5.51, I got an error reproduced as follows:
B4X:
Dim tempQuantStep As Int
   For tempQuantStep=1 To 10
     Log(tempQuantStep)
   Next

Log:

B4J version: 5.51
Parsing code. (0.00s)
Compiling code. (0.03s)
Compiling layouts code. (0.00s)
Organizing libraries. (0.00s)
Compiling generated Java code. Error
B4J line: 16
For tempQuantStep=1 To 10
javac 1.8.0_66
src\b4j\example\main.java:95: error: cannot find symbol
for (;(step4 > 0 && _tempquantstep4 <= limit4) || (step4 < 0 && _tempquantstep4 >= limit4) ;_tempquantstep4 = ((int)(0 + _tempquantstep + step4)) ) {
^
symbol: variable _tempquantstep4
location: class main
1 error


Changing the name of variable to something else, compiled.
 

jmon

Well-Known Member
Licensed User
Longtime User
Cookies are required to use this site. You must accept them to continue using the site. Learn more…