confusing destructor

BlitzMax Forums/BlitzMax Beginners Area/confusing destructor

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

That wouldnt work, since "tmp" is within the scope of the method.

Youd have to use a Var parameter instead:
Global test:Object = "test"
killReference(test)
If Not test Print "killed"

Function killReference:Ttest(tmp:Object Var)
  tmp = Null
EndFunction