On Thu, 04 Sep 2008, bill robertson wrote: Hi Bill,
> In the example below: > ------------------------------------- > FUNCTION MAIN() > LOCAL cVar > ALTD() > cVar:= 5 // Just to stop on something > RETURN 0 > -------------------------------------- > If I go to the command window of the debugger and ask a few questions: > ? s // nil as expected This is a bug, should be: "Undefined" instead of "NIL" > ? (s:= 3) // 3 as expected It's OK. > ? s // nil - not expected We can implement it but it in Clipper it creates new private variable 's' inside main() function in the above example what may effect executing program. > xHarbour and Clipper show s = 3 instead of nil. Which xHarbour version? I've tested current one and it gives exactly the same results as Harbour. Some older xHarbour versions may behaves differently because all memvar variables created inside macro evaluated by TYPE() function were created as PUBLIC ones instead of PRIVATE which should be destroyed after leaving current function. A side effect of this behavior can give the results you are looking for. > It's very useful to do a few calculations and save results for tests you > didn't anticipate. What do you need exact Clipper behavior or temporary variables inside debugger only? best regards, Przemek _______________________________________________ Harbour mailing list [email protected] http://lists.harbour-project.org/mailman/listinfo/harbour
