From 6ca6681b2afdc062d52baa1379c67228bf437f8f Mon Sep 17 00:00:00 2001 From: Petr Tesarik Date: Mon, 15 Oct 2012 18:46:34 +0200 Subject: [PATCH] Document operator precedence in the manpage --- doc/hed.1 | 26 ++++++++++++++++++++------ 1 file changed, 20 insertions(+), 6 deletions(-) diff --git a/doc/hed.1 b/doc/hed.1 index 2faf7d8..ad64017 100644 --- a/doc/hed.1 +++ b/doc/hed.1 @@ -301,14 +301,28 @@ supported. .I atom binop atom You can produce an atom by performing a binary operation \fIbinop\fP on two subatoms. If they don't have the same length, the missing -bytes are sign-extended. Supported binary operators are -.BL | & ^ + - * / % << -and -.BR >> . +bytes are sign-extended. Supported binary operators, listed from highest +to lowest precedence: +.RS +.TP +.B * / % +.PD 0 +.TP +.B + - +.TP +.B >> << +.TP +.B & +.TP +.B ^ +.TP +.B | +.RE +.PD +.IP +All operators are left-associative. .B Hed implements all these operations on numbers of arbitrary size. -Currently no binary operation takes any special precedence, they are -evaluated in the order you write them. .TP .BI \' "ASCII_string" \' Just like that. Prefix any apostrophes and backslashes by a -- 2.11.4.GIT