]> granicus.if.org Git - postgresql/commitdiff
Document the exponentiation operator as associating left to right.
authorTom Lane <tgl@sss.pgh.pa.us>
Mon, 28 Dec 2015 17:09:00 +0000 (12:09 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Mon, 28 Dec 2015 17:09:00 +0000 (12:09 -0500)
Common mathematical convention is that exponentiation associates right to
left.  We aren't going to change the parser for this, but we could note
it in the operator's description.  (It's already noted in the operator
precedence/associativity table, but users might not look there.)
Per bug #13829 from Henrik Pauli.

doc/src/sgml/func.sgml

index e08bf60b9e9a0aef055983b01db6dd8bd2045bea..d230c6073d20471d0dcb636fc35268be13b595b1 100644 (file)
 
       <row>
        <entry> <literal>^</literal> </entry>
-       <entry>exponentiation</entry>
+       <entry>exponentiation (associates left to right)</entry>
        <entry><literal>2.0 ^ 3.0</literal></entry>
        <entry><literal>8</literal></entry>
       </row>