Hi, as the name of the thread indicates, i'm having a lot of troubles converting some Basic code to C. Can somebody help me doing this ?
Here's some of the code, with this bit translated i think i can do the rest by myself.
Code:
'' internals
declare sub regInitClass _
( _
byval this_ as REGCLASS ptr, _
sizeTb() as REG_SIZEMASK _
)
declare sub sregInitClass _
( _
byval this_ as REGCLASS ptr, _
sizeTb() as REG_SIZEMASK _
)
'':::::
function regNewClass _
( _
byval class_ as integer, _
byval regs as integer, _
sizeTb() as REG_SIZEMASK, _
byval isstack as integer _
) as REGCLASS ptr
dim as REGCLASS ptr this_
this_ = callocate( len( REGCLASS ) )
this_->class = class_
this_->regs = regs
this_->isstack = isstack
if( this_->isstack = FALSE ) then
regInitClass( this_, sizeTb() )
else
sregInitClass( this_, sizeTb() )
end if
function = this_
end function
'':::::
function regDelClass _
( _
byval this_ as REGCLASS ptr _
) as integer
function = FALSE
if( this_ = NULL ) then
exit function
end if
deallocate( this_ )
function = TRUE
end function
Thanks in advance to any help !
Cláudio