aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2001-06-12 15:56:04 +0000
committerNick Clifton <nickc@redhat.com>2001-06-12 15:56:04 +0000
commitb131d4dca6cc3f69960dfcc3f847de335e14cd78 (patch)
tree3fe0ed8534b0d6127f3aead9412795953d78e433 /gas
parent1f8cc6dbc0da3d3248de330289713ab6cebb21f2 (diff)
downloadfsf-binutils-gdb-b131d4dca6cc3f69960dfcc3f847de335e14cd78.zip
fsf-binutils-gdb-b131d4dca6cc3f69960dfcc3f847de335e14cd78.tar.gz
fsf-binutils-gdb-b131d4dca6cc3f69960dfcc3f847de335e14cd78.tar.bz2
Document use of comparison operators as infix operators
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog5
-rw-r--r--gas/doc/as.texinfo37
2 files changed, 41 insertions, 1 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index 5e50df7..9f906ae 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,8 @@
+2001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * doc/as.texinfo (Infix Ops): Document that comparison and
+ combiner operators can be used as infix operators.
+
2001-06-12 Peter Jakubek <pjak@snafu.de>
* gas/config/tc-m68k.c (parse_mri_control_operand): Fix handling
diff --git a/gas/doc/as.texinfo b/gas/doc/as.texinfo
index 825fb38..95825c6 100644
--- a/gas/doc/as.texinfo
+++ b/gas/doc/as.texinfo
@@ -3311,7 +3311,7 @@ Intermediate precedence
@end table
@item
-Lowest Precedence
+Low Precedence
@table @code
@cindex addition, permitted arguments
@@ -3331,6 +3331,41 @@ result has the section of the left argument.
If both arguments are in the same section, the result is absolute.
You may not subtract arguments from different sections.
@c FIXME is there still something useful to say about undefined - undefined ?
+
+@cindex comparison expressions
+@cindex expressions, comparison
+@item ==
+@dfn{Is Equal To}
+@item <>
+@dfn{Is Not Equal To}
+@item <
+@dfn{Is Less Than}
+@itemx >
+@dfn{Is Greater Than}
+@itemx >=
+@dfn{Is Greater Than Or Equal To}
+@itemx <=
+@dfn{Is Less Than Or Equal To}
+
+The comparison operators can be used as infix operators. A true results has a
+value of -1 whereas a false result has a value of 0. Note, these operators
+perform signed comparisons.
+@end table
+
+@item Lowest Precedence
+
+@table @code
+@item &&
+@dfn{Logical And}.
+
+@item ||
+@dfn{Logical Or}.
+
+These two logical operations can be used to combine the results of sub
+expressions. Note, unlike the comparison operators a true result returns a
+value of 1 but a false results does still return 0. Also note that the logical
+or operator has a slightly lower precedence than logical and.
+
@end table
@end enumerate