Steward
分享是一種喜悅、更是一種幸福
程式語言 - High Level Assembly (HLA) - Win32 API (HLA v1.x) - Hello, world!
參考網站:
https://www.plantation-productions.com/Webster/
https://www.plantation-productions.com/Webster/Win32Asm/win32API.html
經典的Hello, world!程式框架總是能夠讓人細心品味一款程式語言的美好,司徒就使用一個簡單的Message對話盒來展現Hello, world!框架
main.hla
program main;
#include("w.hhf")
begin main;
w.MessageBox(0, "Hello, world!", "", w.MB_OK);
end main;
Makefile
export hlainc=c:\hla\include
TARGET = main
all:
myx86 "c:\hla\hlaparse.exe" -WIN32 -level=high -v -test ${TARGET}.hla
myx86 "c:\hla\polink.exe" @${TARGET}.link "c:\hla\hlalib\hlalib.lib" ${TARGET}.obj /OUT:${TARGET}.exe
run:
myx86 ${TARGET}.exe
clean:
rm -rf ${TARGET}.exe ${TARGET}.obj ${TARGET}.link
編譯、執行
$ make $ make run