I got different results from below program for ver 6.0 c backend and LTS. Please help to confirm.
Further checking show it is related if the PB file is save with UTF-8 BOM or UTF-8 only. In my IDE setting PB file always save in UTF-8 BOM. Manually convert the PB file to UTF-8 format will solve the issue. (both compilers give the same result). However, I was told that PB file should always saved with UTF-8 BOM. My system is win 10 pro x64.
For below code, please compile without saving to disk and see if it make a difference.
Thanks.
Allen
Code: Select all
EnableExplicit
Define.i k,Tmp,Shift
Define.s Tmp$
Define.u TmpChar
Tmp$="*가";
Tmp=0
Shift=0
For k=1 To 2
TmpChar=Asc(Mid(Tmp$,k,1))
Tmp=Tmp+TmpChar<<Shift
Shift=Shift+16
Next
Debug Hex(Tmp)
;FFFFFFFFAC00002A ver 6.0 c backend
;AC00002A Ver 6.0 LTS