Built using these Harbour defines:
go.bat
set path=c:\bcc7\bin
set HB_WITH_OPENSSL=c:\OpenSSL-Win32\include
set HB_WITH_CURL=c:\curl\include
win-make.exe
viewtopic.php?p=201592#p201592
set path=c:\bcc7\bin
set HB_WITH_OPENSSL=c:\OpenSSL-Win32\include
set HB_WITH_CURL=c:\curl\include
win-make.exe
FUNCTION MAIN()
LOCAL i
FOR i = 1 TO 10
FOR i = i TO 5
? i
NEXT
NEXT
INKEY( 0 )
RETURN NIL
Harbour 3.2.0dev (r1801051438)
Copyright (c) 1999-2016, http://harbour-project.org/
BUG.prg(6) Warning W0030 Duplicate variable 'I' in nested FOR loop
No code generated.
Antonio Linares wrote:Enrico,
I don't think that is a bug as it is reported as a warning
Antonio Linares wrote:Anyhow the right place to report it is in the Harbour developers group at:
https://groups.google.com/forum/#!forum/harbour-devel
thanks
FUNCTION MAIN()
LOCAL i,ii
FOR i = 1 TO 10
FOR ii = i TO 5
? ii
NEXT ii
NEXT i
INKEY( 0 )
RETURN NIL
Enrico Maria Giordano wrote:It was only a sample. The point is that there is no valid reason to issue a warning in this case and no compiler in any language issues it.
EMG
cnavarro wrote:Other compilers do not warn that their code produces an endless loop?
I prefer that the compiler warn me
Return to WhatsNew / Novedades
Users browsing this forum: No registered users and 18 guests