mirror of
https://github.com/QB64Official/qb64.git
synced 2024-07-04 22:20:24 +00:00
Add extra casts in UDT string access for clang
This commit is contained in:
parent
87510de800
commit
c165592d41
|
@ -19988,7 +19988,7 @@ FUNCTION refer$ (a2$, typ AS LONG, method AS LONG)
|
|||
r$ = "qbs_new_fixed(" + o2$ + "," + str2(udtetypesize(E)) + ",1)"
|
||||
typ = STRINGTYPE + ISFIXEDLENGTH 'ISPOINTER retained, it is still a pointer!
|
||||
ELSE
|
||||
r$ = "*((qbs**)(" + scope$ + n$ + "+(" + o$ + ")))"
|
||||
r$ = "*((qbs**)((char*)" + scope$ + n$ + "+(" + o$ + ")))"
|
||||
typ = STRINGTYPE
|
||||
END IF
|
||||
ELSE
|
||||
|
@ -21195,7 +21195,7 @@ SUB setrefer (a2$, typ2 AS LONG, e2$, method AS LONG)
|
|||
o2$ = "(((uint8*)" + scope$ + n$ + ")+(" + o$ + "))"
|
||||
r$ = "qbs_new_fixed(" + o2$ + "," + str2(udtetypesize(E)) + ",1)"
|
||||
ELSE
|
||||
r$ = "*((qbs**)((" + scope$ + n$ + ")+(" + o$ + ")))"
|
||||
r$ = "*((qbs**)((char*)(" + scope$ + n$ + ")+(" + o$ + ")))"
|
||||
END IF
|
||||
IF method = 0 THEN e$ = evaluatetotyp(e$, STRINGTYPE - ISPOINTER)
|
||||
IF Error_Happened THEN EXIT SUB
|
||||
|
|
Loading…
Reference in a new issue