mirror of
https://github.com/QB64-Phoenix-Edition/QB64pe.git
synced 2024-07-02 03:50:36 +00:00
Disallow GET/PUT for variable UDTs
This commit is contained in:
parent
4c94b54f10
commit
b912bf09ee
|
@ -1940,6 +1940,7 @@ DO
|
||||||
udtxcname(i) = getelement(ca$, 2)
|
udtxcname(i) = getelement(ca$, 2)
|
||||||
udtxnext(i) = 0
|
udtxnext(i) = 0
|
||||||
udtxsize(i) = 0
|
udtxsize(i) = 0
|
||||||
|
udtxvariable(i) = 0
|
||||||
|
|
||||||
hashname$ = secondelement$
|
hashname$ = secondelement$
|
||||||
hashflags = HASHFLAG_UDT
|
hashflags = HASHFLAG_UDT
|
||||||
|
@ -16985,6 +16986,7 @@ FUNCTION evaluatetotyp$ (a2$, targettyp AS LONG)
|
||||||
' print "-4: evaluated as ["+e$+"]":sleep 1
|
' print "-4: evaluated as ["+e$+"]":sleep 1
|
||||||
|
|
||||||
IF (sourcetyp AND ISUDT) THEN 'User Defined Type -> byte_element(offset,bytes)
|
IF (sourcetyp AND ISUDT) THEN 'User Defined Type -> byte_element(offset,bytes)
|
||||||
|
If udtxvariable(sourcetyp AND 511) Then Give_Error "Cannot GET/PUT variable-length TYPE": Exit Function
|
||||||
idnumber = VAL(e$)
|
idnumber = VAL(e$)
|
||||||
i = INSTR(e$, sp3): e$ = RIGHT$(e$, LEN(e$) - i)
|
i = INSTR(e$, sp3): e$ = RIGHT$(e$, LEN(e$) - i)
|
||||||
u = VAL(e$) 'closest parent
|
u = VAL(e$) 'closest parent
|
||||||
|
|
Loading…
Reference in a new issue