proper error handling in ROMBASIC

Former-commit-id: b5bd084e6807c765cdd6d3ffff1b1628321b9c6a
Former-commit-id: 55c3bb3cd56c7867809c0819f178aeebf1e46676
This commit is contained in:
Song Minjae
2016-09-22 18:16:38 +09:00
parent 6caae90d7e
commit 433f27bef2
24 changed files with 208 additions and 137 deletions

View File

@@ -1,4 +1,4 @@
This is LuaTeX, Version beta-0.80.0 (TeX Live 2015) (rev 5238) (format=lualatex 2015.10.5) 21 SEP 2016 19:32
This is LuaTeX, Version beta-0.80.0 (TeX Live 2015) (rev 5238) (format=lualatex 2015.10.5) 22 SEP 2016 13:09
restricted \write18 enabled.
file:line:error style messages enabled.
**romapidoc.tex
@@ -552,7 +552,7 @@ luatexbase-attr: luatexbase.attributes["luaotfload@cursbase"] = 6
luatexbase-attr: luatexbase.attributes["luaotfload@curscurs"] = 7
luatexbase-attr: luatexbase.attributes["luaotfload@cursdone"] = 8
luatexbase-attr: luatexbase.attributes["luaotfload@state"] = 9
luaotfload | main : fontloader loaded in 0.089 seconds
luaotfload | main : fontloader loaded in 0.028 seconds
luatexbase-mcb: inserting 'luaotfload.node_processor'
at position 1 in 'pre_linebreak_filter'
luatexbase-mcb: inserting 'luaotfload.node_processor'
@@ -1264,52 +1264,52 @@ luaotfload | load : Lookup/name: "MyriadPro" -> "MyriadPro-Regular.otf"
luaotfload | load : Lookup/name: "MyriadPro" -> "MyriadPro-Bold.otf"
luaotfload | load : Lookup/name: "MyriadPro" -> "MyriadPro-Bold.otf"
luaotfload | load : Lookup/name: "MyriadPro" -> "MyriadPro-It.otf"
Underfull \hbox (badness 2735) in paragraph at lines 136--136
Underfull \hbox (badness 2735) in paragraph at lines 138--138
[][]|\EU2/MyriadPro(0)/m/n/10 Moves the di-rec-tory to the
[]
Underfull \hbox (badness 1655) in paragraph at lines 136--136
Underfull \hbox (badness 1655) in paragraph at lines 138--138
\EU2/MyriadPro(0)/m/n/10 des-ti-na-tion. Sub-di-rec-to-ries /
[]
Underfull \hbox (badness 2150) in paragraph at lines 136--136
Underfull \hbox (badness 2150) in paragraph at lines 138--138
[][]|\EU2/MyriadPro(0)/m/n/10 Copies the di-rec-tory to the
[]
Underfull \hbox (badness 1655) in paragraph at lines 136--136
Underfull \hbox (badness 1655) in paragraph at lines 138--138
\EU2/MyriadPro(0)/m/n/10 des-ti-na-tion. Sub-di-rec-to-ries /
[]
LaTeX Font Info: Font shape `EU2/MyriadPro(0)/m/sl' in size <10> not availabl
e
(Font) Font shape `EU2/MyriadPro(0)/m/it' tried instead on input li
ne 136.
ne 138.
luaotfload | load : Lookup/name: "MyriadPro" -> "MyriadPro-It.otf"
luaotfload | load : Lookup/name: "MyriadPro" -> "MyriadPro-It.otf" [6
] [7] [8]
Underfull \hbox (badness 4792) in paragraph at lines 186--186
Underfull \hbox (badness 4792) in paragraph at lines 188--188
[][]|\EU2/MyriadPro(0)/m/n/10 Con-verts byte ar-ray to the
[]
[9
]
Underfull \hbox (badness 3354) in paragraph at lines 210--210
Underfull \hbox (badness 3354) in paragraph at lines 212--212
[][]|\EU2/MyriadPro(0)/m/n/10 Re-turns SHA-256 hash of in-put
[]
Underfull \hbox (badness 4805) in paragraph at lines 210--210
Underfull \hbox (badness 4805) in paragraph at lines 212--212
[][]|\EU2/MyriadPro(0)/m/n/10 De-codes Base64 string and re-
[]
Underfull \hbox (badness 2707) in paragraph at lines 210--210
Underfull \hbox (badness 2707) in paragraph at lines 212--212
[][]|\EU2/MyriadPro(0)/m/n/10 En-codes in-put string as Base64
[]
@@ -1318,47 +1318,45 @@ Underfull \hbox (badness 2707) in paragraph at lines 210--210
] [11
]
Underfull \hbox (badness 1418) in paragraph at lines 280--280
[][]|\EU2/MyriadPro(0)/m/n/10 Moves cur-sor to (\EU2/MyriadPro(0)/bx/n/10 x\EU2
/MyriadPro(0)/m/n/10 , \EU2/MyriadPro(0)/bx/n/10 y\EU2/MyriadPro(0)/m/n/10 ), s
tart-ing
Underfull \hbox (badness 2165) in paragraph at lines 292--292
\EU2/MyriadPro(0)/m/n/10 nal. Graphic ter-mi-nals also can
[]
Underfull \hbox (badness 2932) in paragraph at lines 280--280
Underfull \hbox (badness 2932) in paragraph at lines 292--292
[][]|\EU2/MyriadPro(0)/m/n/10 Re-turns \EU2/MyriadPro(0)/bx/n/10 true \EU2/Myri
adPro(0)/m/n/10 if the ter-mi-nal is
[]
Underfull \hbox (badness 2772) in paragraph at lines 280--280
Underfull \hbox (badness 2772) in paragraph at lines 292--292
[][]|\EU2/MyriadPro(0)/m/n/10 Emits \EU2/MyriadPro(0)/bx/n/10 c \EU2/MyriadPro(
0)/m/n/10 into (\EU2/MyriadPro(0)/bx/n/10 x\EU2/MyriadPro(0)/m/n/10 , \EU2/Myri
adPro(0)/bx/n/10 y\EU2/MyriadPro(0)/m/n/10 ), con-trol se-
[]
Underfull \hbox (badness 3118) in paragraph at lines 280--280
Underfull \hbox (badness 3118) in paragraph at lines 292--292
\EU2/MyriadPro(0)/m/n/10 ing con-trol se-quences as sym-
[]
Underfull \hbox (badness 1365) in paragraph at lines 280--280
Underfull \hbox (badness 1365) in paragraph at lines 292--292
[][]|\EU2/MyriadPro(0)/m/n/10 Clears whole screen buffer and
[]
Underfull \hbox (badness 5022) in paragraph at lines 280--280
Underfull \hbox (badness 5022) in paragraph at lines 292--292
[][]|\EU2/MyriadPro(0)/m/n/10 Re-turns cur-rent co-or-di-nates of
[]
Underfull \hbox (badness 10000) in paragraph at lines 280--280
Underfull \hbox (badness 10000) in paragraph at lines 292--292
[][]|\EU2/MyriadPro(0)/m/n/10 Re-turns cur-rent fore-ground
[]
Underfull \hbox (badness 10000) in paragraph at lines 280--280
Underfull \hbox (badness 10000) in paragraph at lines 292--292
[][]|\EU2/MyriadPro(0)/m/n/10 Re-turns cur-rent back-ground
[]
@@ -1367,53 +1365,53 @@ Underfull \hbox (badness 10000) in paragraph at lines 280--280
] [13] <mda.pdf, id=152, 597.51233pt x 845.0471pt>
File: mda.pdf Graphic file (type pdf)
<use mda.pdf>
Package pdftex.def Info: mda.pdf used on input line 298.
Package pdftex.def Info: mda.pdf used on input line 310.
(pdftex.def) Requested size: 148.4842pt x 210.0pt.
Underfull \vbox (badness 10000) has occurred while \output is active []
[14]
Underfull \hbox (badness 6658) in paragraph at lines 319--319
Underfull \hbox (badness 6658) in paragraph at lines 331--331
[][]|\EU2/MyriadPro(0)/m/n/10 DEL. Backspace and deletes
[]
[15<./mda.pdf>] [16]
Underfull \hbox (badness 1092) in paragraph at lines 340--340
Underfull \hbox (badness 1092) in paragraph at lines 352--352
\EU2/MyriadPro(0)/m/n/10 ory in-stalled in the com-puter, in
[]
Underfull \hbox (badness 3019) in paragraph at lines 371--371
Underfull \hbox (badness 3019) in paragraph at lines 383--383
[][]|\EU2/MyriadPro(0)/m/n/10 Cur-rency sym-bol used in the world.
[]
Underfull \hbox (badness 1888) in paragraph at lines 371--371
Underfull \hbox (badness 1888) in paragraph at lines 383--383
[][]|\EU2/MyriadPro(0)/m/n/10 Ascii con-trol se-quence DC1. Used to
[]
Underfull \hbox (badness 1888) in paragraph at lines 371--371
Underfull \hbox (badness 1888) in paragraph at lines 383--383
[][]|\EU2/MyriadPro(0)/m/n/10 Ascii con-trol se-quence DC2. Used to
[]
Underfull \hbox (badness 1888) in paragraph at lines 371--371
Underfull \hbox (badness 1888) in paragraph at lines 383--383
[][]|\EU2/MyriadPro(0)/m/n/10 Ascii con-trol se-quence DC3. Used to
[]
Underfull \hbox (badness 1888) in paragraph at lines 371--371
Underfull \hbox (badness 1888) in paragraph at lines 383--383
[][]|\EU2/MyriadPro(0)/m/n/10 Ascii con-trol se-quence DC4. Used to
[]
Underfull \hbox (badness 4713) in paragraph at lines 371--371
Underfull \hbox (badness 4713) in paragraph at lines 383--383
\EU2/MyriadPro(0)/m/n/10 change fore-ground colour to bright
[]
Underfull \hbox (badness 2478) in paragraph at lines 371--371
Underfull \hbox (badness 2478) in paragraph at lines 383--383
[][]|\EU2/MyriadPro(0)/m/n/10 Ascii con-trol se-quence DLE. Used to
[]
@@ -1445,30 +1443,30 @@ luaotfload | load : Lookup/name: "MyriadPro" -> "MyriadPro-Bold.otf" [19
\tf@toc=\write5
\openout5 = romapidoc.toc
Package atveryend Info: Empty hook `BeforeClearDocument' on input line 458.
Package atveryend Info: Empty hook `AfterLastShipout' on input line 458.
Package atveryend Info: Empty hook `BeforeClearDocument' on input line 470.
Package atveryend Info: Empty hook `AfterLastShipout' on input line 470.
(./romapidoc.aux)
Package atveryend Info: Executing hook `AtVeryEndDocument' on input line 458.
Package atveryend Info: Executing hook `AtEndAfterFileList' on input line 458.
Package atveryend Info: Executing hook `AtVeryEndDocument' on input line 470.
Package atveryend Info: Executing hook `AtEndAfterFileList' on input line 470.
Package rerunfilecheck Info: File `romapidoc.out' has not changed.
(rerunfilecheck) Checksum: 3DBAF2167B6CE65D6E1362AF2C8C72DF;1706.
Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line 458.
Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line 470.
)
Here is how much of LuaTeX's memory you used:
25435 strings out of 494693
100000,552014 words of node,token memory allocated
721 words of node memory still in use:
125010,552014 words of node,token memory allocated
722 words of node memory still in use:
3 hlist, 1 vlist, 1 rule, 2 glue, 1 kern, 5 attribute, 140 glue_spec, 5 attri
bute_list, 2 write nodes
avail lists: 2:12868,3:242,4:3140,5:1168,6:5454,7:295,8:17,9:772,10:329
avail lists: 2:14425,3:270,4:3582,5:1296,6:6112,7:343,8:17,9:884,10:384
28549 multiletter control sequences out of 65536+600000
62 fonts using 5300671 bytes
55i,12n,59p,1189b,492s stack positions out of 5000i,500n,10000p,200000b,100000s
</Library/Fonts/MyriadPro-It.otf></Library/Fonts/MyriadPro-Regular.otf></Library
/Fonts/MyriadPro-Bold.otf>
Output written on romapidoc.pdf (29 pages, 200321 bytes).
Output written on romapidoc.pdf (29 pages, 200660 bytes).
PDF statistics: 267 PDF objects out of 1000 (max. 8388607)
223 compressed objects within 3 object streams

Binary file not shown.

View File

@@ -130,9 +130,11 @@ The path for the argument of functions blocks `\,.\,.\,' to be entered, preventi
\\ \\
fs.open(\textbf{path}: string, \textbf{mode}: string) & file & Opens file and returns its handle. See section \emph{File Handler} for details.
\\ \\
fs.parent(\textbf{path}: string) & string & Returs parent directory to the \textbf{path}.
\\ \\
fs.dofile(\textbf{path}: string) & nil & Loads the script on \textbf{path} and executes it.
\\ \\
fs.parent(\textbf{path}: string) & string & Returs parent directory to the \textbf{path}.
fs.fetchText(\textbf{path}: string) & string & Opens the file on \textbf{path} and returns its contents as a plain text.
\end{tabularx}
\subsection{File Handler}
@@ -226,6 +228,8 @@ The Terminal API provides functions for sending text to the terminals, and drawi
\subsection{Functions}
Note: cursor coordinates starts from one, not zero.
\begin{tabularx}{\textwidth}{l l X}
\textbf{\large Function} & \textbf{\large Return} & \textbf{\large Description}
\\ \\
@@ -236,9 +240,9 @@ The Terminal API provides functions for sending text to the terminals, and drawi
\\ \\
term.newLine() & nil & Make a new line.
\\ \\
term.moveCursor(\textbf{x}: int, \textbf{y}: int) & nil & Moves cursor to (\textbf{x}, \textbf{y}), starting from 1.
term.moveCursor(\textbf{x}: int) & nil & Moves cursor horizontally, starting from 1.
\\ \\
term.width() & int & Returns the width of the terminal. Meant to be used with teletypes.
term.width() & int & Returns the width of the terminal. Graphic terminals also can use this.
\\ \\
term.scroll(\textbf{n}: int) & nil & Make a new line \textbf{n} times.
\\ \\
@@ -258,16 +262,24 @@ The Terminal API provides functions for sending text to the terminals, and drawi
\\ \\
term.clearLine() & nil & Clears current line on the screen buffer, does not moves cursor.
\\ \\
term.setCursor(\textbf{x}: int, \textbf{y}: int) & nil & Moves cursor to (\textbf{x}, \textbf{y})
\\ \\
term.getCursor() & int, int & Returns current coordinates of the cursor.
\\ \\
term.getX() & int & Returns X coordinate of the cursor.
\\ \\
term.getY() & int & Returns Y coordinate of the cursor.
\\ \\
term.setX(int) & nil & Sets X coordinate of the cursor.
\\ \\
term.setY(int) & nil & Sets Y coordinate of the cursor.
\\ \\
term.blink(bool) & nil & Sets cursor blinking. \textbf{true} makes the cursor blink.
\\ \\
term.size() & int, int & Returns width and height of the terminal.
\\ \\
term.height() & int & Returns height of the terminal.
\\ \\
term.isCol() & bool & Returns if the terminal supports colour.
\\ \\
term.setForeCol(\textbf{col}: int) & nil & Sets foreground colour to \textbf{col}