Miguel,
Sorry for the delayed response.
Now, ParamCount() is missing. Could you please post a complete,
reduced, yet self contained, sample, tested to compile and build
correctly?
Ron
On Apr 24, 2008, at 7:19 AM, Miguel Angel Marchuet wrote:
>
> //----------------------------------------//
>
> function GetLocal( nProcLevel, nLocal )
>
> return HB_DBG_VMVARLGET( nProcLevel + 1, ParamCount( nProcLevel +
> 1 ) + nLocal )
>
> //----------------------------------------//
>
> function LocalCount( nProcLevel )
>
> return HB_DBG_VMSTKLCOUNT( nProcLevel + 1 ) - ParamCount
> ( nProcLevel + 1 )
>
> //----------------------------------------//
>
> function cValToChar( uVal )
>
> local cType := ValType( uVal )
>
> do case
> case cType == "C" .or. cType == "M"
> return uVal
>
> case cType == "D"
> return DToC( uVal )
>
> case cType == "L"
> return If( uVal, ".T.", ".F." )
>
> case cType == "N"
> return AllTrim( Str( uVal ) )
>
> case cType == "B"
> return "{|| ... }"
>
> case cType == "A"
> return "{ ... }"
>
> case cType == "O"
> return "Object"
>
> otherwise
> return ""
> endcase
>
> return nil
>
> //----------------------------------------//
>
> Ron Pinkas escribió:
>> Miguel,
>> Please provide sources for:
>> LocaCount()
>> GetLocal()
>> cValToChar()
>> [Miguel, in general it's so much more frustrating trying to review
>> a NON SELF CONTAINED samples. It takes just few seconds to forward
>> a sample that anyone can compile and build, right away, using
>> standatd build files on CVS.]
>> Ron
>> Ron
>> On Apr 24, 2008, at 12:38 AM, Miguel Angel Marchuet wrote:
>>> we make this at errorsys
>>>
>>> for j = 1 to LocalCount( n )
>>> cErrorLog += " Local " + Str( j, 3 ) + ": " + ;
>>> ValType( GetLocal( n, j ) ) + ;
>>> " " + cGetInfo( GetLocal( n, j ) )
>>> + CRLF
>>> next
>>>
>>> //------------------------------------------------------------------
>>> ----------//
>>> // returns extended info for a certain variable type
>>>
>>> static function cGetInfo( uVal )
>>>
>>> local cType := ValType( uVal )
>>>
>>> do case
>>> case cType == "C"
>>> return '"' + cValToChar( uVal ) + '"'
>>>
>>> case cType == "O"
>>> return "Class: " + uVal:ClassName()
>>>
>>> case cType == "A"
>>> return "Len: " + Str( Len( uVal ), 4 )
>>>
>>> otherwise
>>> return cValToChar( uVal )
>>> endcase
>>>
>>> return nil
>>>
>>> //------------------------------------------------------------------
>>> ----------//
>>>
>>>
>>> ant it crasesh now
>>>
>>> hb_xfree *pointer*
>>>
>>> I think because locals are free yet.
>>>
>>> Best regards,
>>> Miguel Angel marchuet
>>>
>>> Andi Jahja escribió:
>>>> Hi All,
>>>>
>>>> On RTE, xHarbour generates memory leaks.
>>>> The following is a test prg:
>>>>
>>>> ---8<---
>>>> proc main()
>>>> local a
>>>> ? a + 1
>>>> ---8<---
>>>>
>>>> Commenting QUIT in line 999 of errorsys.prg cures this.
>>>>
>>>> This probably because pFunc() in hvm.c (7492) already set the
>>>> quit flag
>>>> invoked by errorsys.prg(999), so hb_vmSend() never returns to
>>>> the caller
>>>> (hb_itemDo in errLaunch) to make a clean-up.
>>>>
>>>> ... or is there other area which should be corrected?
>>>>
>>>> Thanks.
>>>> --
>>>> Andi
>>>>
>>>> -------------------------------------------------------------------
>>>> ------
>>>> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
>>>> Don't miss this year's exciting event. There's still time to
>>>> save $100.
>>>> Use priority code J8TL2D2.
>>>> http://ad.doubleclick.net/clk;198757673;13503038;p?http://
>>>> java.sun.com/javaone
>>>> _______________________________________________
>>>> xHarbour-developers mailing list
>>>> [email protected]
>>>> https://lists.sourceforge.net/lists/listinfo/xharbour-developers
>>>>
>>>
>>>
>>> --------------------------------------------------------------------
>>> -----
>>> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
>>> Don't miss this year's exciting event. There's still time to save
>>> $100.
>>> Use priority code J8TL2D2.
>>> http://ad.doubleclick.net/clk;198757673;13503038;p?http://
>>> java.sun.com/javaone
>>> _______________________________________________
>>> xHarbour-developers mailing list
>>> [email protected]
>>> https://lists.sourceforge.net/lists/listinfo/xharbour-developers
>>>
>
>
-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
xHarbour-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xharbour-developers