Mercurial > hg > index.cgi
annotate docs/manual/x483.html @ 235:e3741cf53e00
Fix error messages related to undefined symbols in lwlink
Make lwlink not complain about seciton base and length symbols. Also silence
duplicate complaints about undefined symbols. There is no need to complain
about undefined symbols during the file/section resolution stage! If they
are truly undefined, they'll still be undefined at the reference resolution
stage.
author | William Astle <lost@l-w.ca> |
---|---|
date | Sat, 11 Aug 2012 15:18:58 -0600 |
parents | 2cc599f1bebf |
children |
rev | line source |
---|---|
231
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN""http://www.w3.org/TR/html4/loose.dtd"> |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
2 <HTML |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
3 ><HEAD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
4 ><TITLE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
5 >Macros</TITLE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
6 ><META |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
7 NAME="GENERATOR" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
8 CONTENT="Modular DocBook HTML Stylesheet Version 1.79"><LINK |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
9 REL="HOME" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
10 TITLE="LW Tool Chain" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
11 HREF="index.html"><LINK |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
12 REL="UP" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
13 TITLE="LWASM" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
14 HREF="c45.html"><LINK |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
15 REL="PREVIOUS" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
16 TITLE="Assembler Directives" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
17 HREF="x200.html"><LINK |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
18 REL="NEXT" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
19 TITLE="Structures" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
20 HREF="x506.html"></HEAD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
21 ><BODY |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
22 CLASS="SECTION" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
23 BGCOLOR="#FFFFFF" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
24 TEXT="#000000" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
25 LINK="#0000FF" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
26 VLINK="#840084" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
27 ALINK="#0000FF" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
28 ><DIV |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
29 CLASS="NAVHEADER" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
30 ><TABLE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
31 SUMMARY="Header navigation table" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
32 WIDTH="100%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
33 BORDER="0" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
34 CELLPADDING="0" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
35 CELLSPACING="0" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
36 ><TR |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
37 ><TH |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
38 COLSPAN="3" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
39 ALIGN="center" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
40 >LW Tool Chain</TH |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
41 ></TR |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
42 ><TR |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
43 ><TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
44 WIDTH="10%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
45 ALIGN="left" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
46 VALIGN="bottom" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
47 ><A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
48 HREF="x200.html" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
49 ACCESSKEY="P" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
50 >Prev</A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
51 ></TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
52 ><TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
53 WIDTH="80%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
54 ALIGN="center" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
55 VALIGN="bottom" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
56 >Chapter 3. LWASM</TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
57 ><TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
58 WIDTH="10%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
59 ALIGN="right" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
60 VALIGN="bottom" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
61 ><A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
62 HREF="x506.html" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
63 ACCESSKEY="N" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
64 >Next</A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
65 ></TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
66 ></TR |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
67 ></TABLE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
68 ><HR |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
69 ALIGN="LEFT" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
70 WIDTH="100%"></DIV |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
71 ><DIV |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
72 CLASS="SECTION" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
73 ><H1 |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
74 CLASS="SECTION" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
75 ><A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
76 NAME="AEN483" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
77 >3.7. Macros</A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
78 ></H1 |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
79 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
80 >LWASM is a macro assembler. A macro is simply a name that stands in for a |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
81 series of instructions. Once a macro is defined, it is used like any other |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
82 assembler directive. Defining a macro can be considered equivalent to adding |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
83 additional assembler directives.</P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
84 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
85 >Macros may accept parameters. These parameters are referenced within a |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
86 macro by the a backslash ("\") followed by a digit 1 through 9 for the first |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
87 through ninth parameters. They may also be referenced by enclosing the |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
88 decimal parameter number in braces ("{num}"). The special expansion "\*" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
89 translates to the exact parameter string, including all parameters, passed |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
90 to the macro. These parameter references are replaced with the verbatim text |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
91 of the parameter passed to the macro. A reference to a non-existent |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
92 parameter will be replaced by an empty string. Macro parameters are expanded |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
93 everywhere on each source line. That means the parameter to a macro could be |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
94 used as a symbol or it could even appear in a comment or could cause an |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
95 entire source line to be commented out when the macro is expanded. </P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
96 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
97 >Parameters passed to a macro are separated by commas and the parameter list |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
98 is terminated by any whitespace. This means that neither a comma nor whitespace |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
99 may be included in a macro parameter.</P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
100 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
101 >Macro expansion is done recursively. That is, within a macro, macros are |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
102 expanded. This can lead to infinite loops in macro expansion. If the assembler |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
103 hangs for a long time while assembling a file that uses macros, this may be |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
104 the reason.</P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
105 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
106 >Each macro expansion receives its own local symbol context which is not |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
107 inherited by any macros called by it nor is it inherited from the context |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
108 the macro was instantiated in. That means it is possible to use local symbols |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
109 within macros without having them collide with symbols in other macros or |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
110 outside the macro itself. However, this also means that using a local symbol |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
111 as a parameter to a macro, while legal, will not do what it would seem to do |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
112 as it will result in looking up the local symbol in the macro's symbol context |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
113 rather than the enclosing context where it came from, likely yielding either |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
114 an undefined symbol error or bizarre assembly results.</P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
115 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
116 >Note that there is no way to define a macro as local to a symbol context. All |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
117 macros are part of the global macro namespace. However, macros have a separate |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
118 namespace from symbols so it is possible to have a symbol with the same name |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
119 as a macro.</P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
120 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
121 >Macros are defined only during the first pass. Macro expansion also |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
122 only occurs during the first pass. On the second pass, the macro |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
123 definition is simply ignored. Macros must be defined before they are used.</P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
124 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
125 >The following directives are used when defining macros.</P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
126 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
127 ></P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
128 ><DIV |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
129 CLASS="VARIABLELIST" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
130 ><DL |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
131 ><DT |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
132 ><CODE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
133 CLASS="PARAMETER" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
134 >macroname</CODE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
135 > MACRO [NOEXPAND]</DT |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
136 ><DD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
137 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
138 >This directive is used to being the definition of a macro called |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
139 <CODE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
140 CLASS="PARAMETER" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
141 >macroname</CODE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
142 >. If <CODE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
143 CLASS="PARAMETER" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
144 >macroname</CODE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
145 > already |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
146 exists, it is considered an error. Attempting to define a macro within a |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
147 macro is undefined. It may work and it may not so the behaviour should not |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
148 be relied upon.</P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
149 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
150 >If NOEXPAND is specified, the macro will not be expanded in a program |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
151 listing. Instead, all bytes emitted by all instructions within the macro |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
152 will appear to be emitted on the line where the macro is invoked, starting |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
153 at the address of the line of the invokation. If the macro uses ORG or other |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
154 directives that define symbols or change the assembly address, these things |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
155 will also be hidden (except in the symbol table) and the output bytes will |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
156 appear with incorrect address attribution. Thus, NOEXPAND should only be |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
157 used for macros that do not mess with the assembly address or otherwise |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
158 define symbols that should be visible.</P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
159 ></DD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
160 ><DT |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
161 >ENDM</DT |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
162 ><DD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
163 ><P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
164 >This directive indicates the end of the macro currently being defined. It |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
165 causes the assembler to resume interpreting source lines as normal.</P |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
166 ></DD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
167 ></DL |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
168 ></DIV |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
169 ></DIV |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
170 ><DIV |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
171 CLASS="NAVFOOTER" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
172 ><HR |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
173 ALIGN="LEFT" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
174 WIDTH="100%"><TABLE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
175 SUMMARY="Footer navigation table" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
176 WIDTH="100%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
177 BORDER="0" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
178 CELLPADDING="0" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
179 CELLSPACING="0" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
180 ><TR |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
181 ><TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
182 WIDTH="33%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
183 ALIGN="left" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
184 VALIGN="top" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
185 ><A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
186 HREF="x200.html" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
187 ACCESSKEY="P" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
188 >Prev</A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
189 ></TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
190 ><TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
191 WIDTH="34%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
192 ALIGN="center" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
193 VALIGN="top" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
194 ><A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
195 HREF="index.html" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
196 ACCESSKEY="H" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
197 >Home</A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
198 ></TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
199 ><TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
200 WIDTH="33%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
201 ALIGN="right" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
202 VALIGN="top" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
203 ><A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
204 HREF="x506.html" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
205 ACCESSKEY="N" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
206 >Next</A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
207 ></TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
208 ></TR |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
209 ><TR |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
210 ><TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
211 WIDTH="33%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
212 ALIGN="left" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
213 VALIGN="top" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
214 >Assembler Directives</TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
215 ><TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
216 WIDTH="34%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
217 ALIGN="center" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
218 VALIGN="top" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
219 ><A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
220 HREF="c45.html" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
221 ACCESSKEY="U" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
222 >Up</A |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
223 ></TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
224 ><TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
225 WIDTH="33%" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
226 ALIGN="right" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
227 VALIGN="top" |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
228 >Structures</TD |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
229 ></TR |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
230 ></TABLE |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
231 ></DIV |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
232 ></BODY |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
233 ></HTML |
2cc599f1bebf
Added --define to lwasm documentation.
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
234 > |