To demonstrate how to how to handle the different string types in Assembler:
32bit Christmas
Declare Function MessageBox Lib "user32.dll" Alias "MessageBoxA" (ByVal hwnd As Long, ByVal lpText As String, ByVal lpCaption As String, ByVal wType As Long) As Long
zstring cap[]= "The 32Bit world of OxygenBasic..."
zstring msg[]= "Hello Christmas"
push 0
lea eax,cap
push eax
lea eax,msg
push eax
push 0
call MessageBox
bstring cap= "The 32Bit world of OxygenBasic..."
bstring msg= "Hello Christmas"
push 0
push cap
push msg
push 0
call MessageBox
string cap= "The 32Bit world of OxygenBasic..."
string msg= "Hello Christmas"
push 0
mov eax,cap
push [eax]
mov eax,msg
push [eax]
push 0
call MessageBox
64bit Christmas
$FileName "t.exe"
#include "..\..\inc\RTL64.inc"
Declare Function MessageBox Lib "user32.dll" Alias "MessageBoxA" (ByVal hwnd As Long, ByVal lpText As String, ByVal lpCaption As String, ByVal wType As Long) As Long
sub rsp,32
zstring cap[]= "The 64Bit world of OxygenBasic..."
zstring msg[]= "Happy Christmas"
mov rcx, 0
lea rdx, msg
lea r8, cap
mov r9, 0
call MessageBox
bstring cap= "The 64Bit world of OxygenBasic..."
bstring msg= "Happy Christmas"
mov rcx, 0
mov rdx, msg
mov r8, cap
mov r9, 0
call MessageBox
string cap= "The 64Bit world of OxygenBasic..."
string msg= "Happy Christmas"
mov rcx, 0
mov rdx, msg
mov rdx,[rdx]
mov r8, cap
mov r8,[r8]
mov r9, 0
call MessageBox
add rsp,32
Charles