[Harbour] -z switch seems to be overly anti-lazy
smu johnson
smujohnson at gmail.com
Wed Feb 3 14:16:22 EST 2010
Hi again,
I have the code here that I have tested on both Clipper 5.2e and Harbour.
This is the first time I have seen with my own eyes what I was being told
earlier, so I can verify that I have witnessed a difference with my own two
eyes. If you cannot replicate it, perhaps I will need to send you my
Blinker .LNK file, in case something is being switched on in there.
Anyways, Clipper will write "hello" at the top of the screen after "test",
and Harbour will not.
FUNC MAIN()
do while lastkey()#27
clear
x:= "test"
@ 2,0 get x ;
valid eval( {||devout("hello"), .f.} ) .or. .t.
read
? "test complete...press enter to do it again"
wait
enddo
RETURN
// Thanks Przemek
2010/2/3 Przemysław Czerpak <druzus at acn.waw.pl>
> On Wed, 03 Feb 2010, smu johnson wrote:
>
> Hi,
>
> > I will try to take a video of the behaviour and figure it out. I swear
> to
> > you, that I am not making this up. If it helps, we are using Clipper
> 5.2e
> > and Blinker. I will take screenshots of the behavioru to prove what I am
> > saying is the case, and hopefully, with your Clipper knowledge :) we can
> > figure it out. Thanks for replying !
>
> I also have CL5.2e and BLINKER and before I replayed I had verified
> the results. I do not need any video, screen shots or antyhing like
> that. I need only code example. The one you sent works in the same
> way in CL5.2e and Harbour (after fixing typo which breaks compilation
> so I guess it was not real code but you typed it by hand for that
> message only). If you try to create real .prg code example and compile
> it using Clipper and Harbour (linker is unimportant here, you can use
> also RTLINK, i.e. with cl.bat) then you should find the exact reason
> of problem. If it will not be enough for you to resolve it then please
> send the code example here with descrption about the difference and
> I'll try to help you. Such example should be as small as possible,
> i.e. this code illustrates in 1-st line the the at compile time
> Clipper and Harbour gives _EXACTLY_ the same results when used with
> and without -z switch and the 2-nd line shows that Clipper does
> not optimize expressions in macrocompiler so code generated by
> macrocompiler is different then code generated by compiler. In
> Harbour it's the same.
>
> ? eval({||qout("hello"),.f.}) .or. .t.
> ? &('eval({||qout("WORLD"),.f.}) .or. .t.')
>
> best regards,
> Przemek
> _______________________________________________
> Harbour mailing list (attachment size limit: 40KB)
> Harbour at harbour-project.org
> http://lists.harbour-project.org/mailman/listinfo/harbour
>
--
smu johnson <smujohnson at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.harbour-project.org/pipermail/harbour/attachments/20100203/a929f089/attachment.html
More information about the Harbour
mailing list