Pointer casting?

BlitzMax Forums/BlitzMax Programming/Pointer casting?

Is there any way to cast say a byte ptr to an int ptr?

Ah - found you can do it implicitly.

Local ip:Int Ptr
Local bp:Byte Ptr

i=256
ip=Varptr i
bp=ip
DebugLog ip[0]
DebugLog bp[0]
DebugLog bp[1]


Damn - int to byte works (as above) but byte to int throws a compiler error. Can't this be done? If not, why not?

*Edit* - never mind - case of RTFM.