From bc0d510ee214829772c466a486fea2de3de167db Mon Sep 17 00:00:00 2001 From: nickysn Date: Fri, 22 Jan 2021 00:03:55 +0000 Subject: [PATCH] + added DebugWriteHexWord and DebugWriteHexLongWord git-svn-id: branches/wasm@48296 - --- rtl/wasi/system.pp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/rtl/wasi/system.pp b/rtl/wasi/system.pp index cbf5c12954..7a93c577de 100644 --- a/rtl/wasi/system.pp +++ b/rtl/wasi/system.pp @@ -53,6 +53,8 @@ procedure DebugWriteLn(const P: PChar); procedure DebugWriteChar(Ch: Char); procedure DebugWriteHexDigit(d: Byte); procedure DebugWriteHexByte(b: Byte); +procedure DebugWriteHexWord(w: Word); +procedure DebugWriteHexLongWord(lw: Word); implementation @@ -168,6 +170,18 @@ begin DebugWriteHexDigit(b and 15); end; +procedure DebugWriteHexWord(w: Word); +begin + DebugWriteHexByte(w shr 8); + DebugWriteHexByte(Byte(w)); +end; + +procedure DebugWriteHexLongWord(lw: Word); +begin + DebugWriteHexWord(lw shr 16); + DebugWriteHexWord(Word(lw)); +end; + begin DebugWriteLn('System unit initialization start'); { To be set if this is a GUI or console application }