Index: doc/user/user.tex
===================================================================
--- doc/user/user.tex	(revision e9a3c69dab8368bfe2e2b0b2dde654c0af9a58cd)
+++ doc/user/user.tex	(revision 59e86eb950542b83c1ba8461a42aa74c1cc65200)
@@ -11,6 +11,6 @@
 %% Created On       : Wed Apr  6 14:53:29 2016
 %% Last Modified By : Peter A. Buhr
-%% Last Modified On : Thu Jul 13 11:44:57 2017
-%% Update Count     : 2690
+%% Last Modified On : Mon Jul 17 13:06:40 2017
+%% Update Count     : 2825
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
@@ -353,8 +353,6 @@
 The 1999 C standard plus GNU extensions.
 \item
-{\lstset{deletekeywords={inline}}
-\Indexc{-fgnu89-inline}\index{compilation option!-fgnu89-inline@{©-fgnu89-inline©}}
+\Indexc[deletekeywords=inline]{-fgnu89-inline}\index{compilation option!-fgnu89-inline@{\lstinline[deletekeywords=inline]$-fgnu89-inline$}}
 Use the traditional GNU semantics for inline routines in C99 mode, which allows inline routines in header files.
-}%
 \end{description}
 The following new \CFA options are available:
@@ -479,5 +477,5 @@
 \end{cfa}
 Existing C programs with keyword clashes can be converted by enclosing keyword identifiers in backquotes, and eventually the identifier name can be changed to a non-keyword name.
-\VRef[Figure]{f:InterpositionHeaderFile} shows how clashes in C header files (see~\VRef{s:StandardHeaders}) can be handled using preprocessor \newterm{interposition}: ©#include_next© and ©-I filename©:
+\VRef[Figure]{f:HeaderFileInterposition} shows how clashes in C header files (see~\VRef{s:StandardHeaders}) can be handled using preprocessor \newterm{interposition}: ©#include_next© and ©-I filename©:
 
 \begin{figure}
@@ -487,16 +485,35 @@
 #define otype ®`®otype®`®		§\C{// make keyword an identifier}§
 #define __CFA_BFD_H__
-#endif // ! otype
-
-#®include_next® <bfd.h>			§\C{// must have internal check for multiple expansion}§
-
+#endif
+
+®#include_next <bfd.h>			§\C{// must have internal check for multiple expansion}§
+®
 #if defined( otype ) && defined( __CFA_BFD_H__ )	§\C{// reset only if set}§
 #undef otype
 #undef __CFA_BFD_H__
-#endif // otype && __CFA_BFD_H__
-\end{cfa}
-\caption{Interposition of Header File}
-\label{f:InterpositionHeaderFile}
+#endif
+\end{cfa}
+\caption{Header-File Interposition}
+\label{f:HeaderFileInterposition}
 \end{figure}
+
+
+\section{Exponentiation Operator}
+
+C, \CC, and Java (and many other programming languages) have no exponentiation operator\index{exponentiation!operator}\index{operator!exponentiation}, \ie $x^y$, and instead use a routine, like \Indexc{pow}, to perform the exponentiation operation.
+\CFA extends the basic operators with the exponentiation operator ©?\?©\index{?\\?@\lstinline$?\?$} and ©?\=?©\index{?\\=?@\lstinline$?\=?$}, as in, ©x \ y© and ©x \= y©, which means $x^y$ and $x \leftarrow x^y$.
+The priority of the exponentiation operator is between the cast and multiplicative operators, so that ©w * (int)x \ (int)y * z© is parenthesized as ©((w * (((int)x) \ ((int)y))) * z)©.
+
+As for \Index{division}, there are exponentiation operators for integral and floating-point types, including the builtin \Index{complex} types.
+Unsigned integral exponentiation\index{exponentiation!unsigned integral} is performed with repeated multiplication (or shifting if the base is 2).
+Signed integral exponentiation\index{exponentiation!signed integral} is performed with repeated multiplication (or shifting if the base is 2), but yields a floating-point result because $b^{-e}=1/b^e$.
+Hence, it is important to designate exponent integral-constants as unsigned or signed: ©3 \ 3u© return an integral result, while ©3 \ 3© returns a floating-point result.
+Floating-point exponentiation\index{exponentiation!floating point} is performed using \Index{logarithm}s\index{exponentiation!logarithm}, so the base cannot be negative.
+\begin{cfa}
+sout | 2 ®\® 8u | 4 ®\® 3u | -4 ®\® 3u | 4 ®\® -3 | -4 ®\® -3 | 4.0 ®\® 2.1 | (1.0f+2.0fi) ®\® (3.0f+2.0fi) | endl;
+256 64 -64 0.015625 -0.015625 18.3791736799526 0.264715-1.1922i
+\end{cfa}
+Parenthesis are necessary for the complex constants or the expresion is parsed as ©1.0f+(2.0fi \ 3.0f)+2.0fi©.
+The exponentiation operator is available for all the basic types, but for user-defined types, only the integral version is available, if the user type defines multiplication, ©*©, and one, ©1©.
 
 
@@ -922,5 +939,5 @@
 	int i, j;
 	int mem() {		 ®// implicit "this" parameter
-		i = 1;		®// this->i
+®		i = 1;		®// this->i
 ®		j = 3;		®// this->j
 ®	}
@@ -929,8 +946,6 @@
 Since CFA is non-object-oriented, the equivalent object-oriented program looks like:
 \begin{cfa}
-struct C {
-	int i, j;
-};
-int mem( C &this ) {	// explicit "this" parameter
+struct S { int i, j; };
+int mem( S &this ) {	// explicit "this" parameter
 	®this.®i = 1;			  // "this" is not elided
 	®this.®j = 2;
@@ -938,7 +953,9 @@
 \end{cfa}
 but it is cumbersome having to write "©this.©" many times in a member.
-\CFA provides a ©with© clause/statement to elided the "©this.©".
-\begin{cfa}
-int mem( C &this ) ®with this® {
+
+\CFA provides a ©with© clause/statement to elided the "©this.©" by opening a scope containing field identifiers and changing the qualified fields into variables, giving an opportunity for optimizing qualified references.\footnote{
+The ©with© statement comes from Pascal~\cite[\S~4.F]{Pascal}.}
+\begin{cfa}
+int mem( S &this ) ®with this® {
 	i = 1;			®// this.i
 ®	j = 2;			®// this.j
@@ -947,13 +964,10 @@
 which extends to multiple routine parameters:
 \begin{cfa}
-struct D {
-	double m, n;
-};
-int mem2( C &this1, D &this2 ) ®with this1, this2® {
+struct T { double m, n; };
+int mem2( S &this1, T &this2 ) ®with this1, this2® {
 	i = 1; j = 2;
 	m = 1.0; n = 2.0;
 }
 \end{cfa}
-The ©with© clause/statement comes from Pascal~\cite[\S~4.F]{Pascal}.
 
 The statement form is used within a block:
@@ -965,5 +979,5 @@
 		// access fields of s1 without qualification
 		®with s2® {  // nesting
-			// access fields of s2 without qualification
+			// access fields of s1 and s2 without qualification
 		}
 	}
@@ -974,42 +988,48 @@
 \end{cfa}
 
-Names clashes when opening multiple structures are ambiguous.
-\begin{cfa}
-struct A { int i; int j; } a, c;
-struct B { int i; int k; } b, c;
+When opening multiple structures, fields with the same name and type are ambiguous and must be fully qualified.
+For fields with the same name but different type, context/cast can be used to disambiguate.
+\begin{cfa}
+struct S { int i; int j; double m; } a, c;
+struct T { int i; int k; int m } b, c;
 ®with a, b® {
-	j + k;						§\C{// unambiguous}§
-	i;							§\C{// ambiguous}§
-	a.i + b.i;					§\C{// unambiguous}§
-}
-®with c® {						§\C{// ambiguous}§
-	// ...
-}
+	j + k;						§\C{// unambiguous, unique names define unique type}§
+	i;							§\C{// ambiguous, same name and type}§
+	a.i + b.i;					§\C{// unambiguous, qualification defines unique type}§
+	m;							§\C{// ambiguous, no context to define unique type}§
+	m = 5.0;					§\C{// unambiguous, context defines unique type}§
+	m = 1;						§\C{// unambiguous, context defines unique type}§
+}
+®with c® { ... }				§\C{// ambiguous, no context}§
+®with (S)c® { ... }				§\C{// unambiguous, cast defines unique type}§
 \end{cfa}
 
 
 \section{Exception Handling}
+\label{s:ExceptionHandling}
 
 Exception handling provides two mechanism: change of control flow from a raise to a handler, and communication from the raise to the handler.
-\begin{cfa}
-exception void h( int i );
-exception int h( int i, double d );
-
+Transfer of control can be local, within a routine, or non-local, among routines.
+Non-local transfer can cause stack unwinding, i.e., non-local routine termination, depending on the kind of raise.
+\begin{cfa}
+exception_t E {};				§\C{// exception type}§
 void f(...) {
-	... throw h( 3 );
-	... i = resume h( 3, 5.1 );
-}
-
+	... throw E{}; ...			§\C{// termination}§
+	... throwResume E{}; ...	§\C{// resumption}§
+}
 try {
 	f(...);
-} catch h( int w ) {
-	// reset
-} resume h( int p, double x ) {
-	return 17;  // recover
+} catch( E e : §boolean-predicate§ ) {			§\C{// termination handler}§
+	// recover and continue
+} catchResume( E e : §boolean-predicate§ ) {	§\C{// resumption handler}§
+	// repair and return
 } finally {
-}
-\end{cfa}
-So the type raised would be the mangled name of the exception prototype and that name would be matched at the handler clauses by comparing the strings.
-The arguments for the call would have to be packed in a message and unpacked at handler clause and then a call made to the handler.
+	// always executed
+}
+\end{cfa}
+The kind of raise and handler match: ©throw© with ©catch© and @throwResume@ with @catchResume@.
+Then the exception type must match along with any additonal predicate must be true.
+The ©catch© and ©catchResume© handlers may appear in any oder.
+However, the ©finally© clause must
 
 
@@ -1571,5 +1591,5 @@
 
 \item
-lvalue to reference conversion: \lstinline[deletekeywords={lvalue}]@lvalue-type cv1 T@ converts to ©cv2 T &©, which allows implicitly converting variables to references.
+lvalue to reference conversion: \lstinline[deletekeywords=lvalue]$lvalue-type cv1 T$ converts to ©cv2 T &©, which allows implicitly converting variables to references.
 \begin{cfa}
 int x, &r = ®x®, f( int & p ); // lvalue variable (int) convert to reference (int &)
@@ -2680,6 +2700,6 @@
 \begin{cfa}[belowskip=0pt]
 char store[®sepSize®];						§\C{// sepSize is the maximum separator size}§
-strcpy( store, sepGet( sout ) );
-sepSet( sout, "_" );
+strcpy( store, sepGet( sout ) );			  §\C{// copy current separator}§
+sepSet( sout, "_" );						§\C{// change separator to underscore}§
 sout | 1 | 2 | 3 | endl;
 \end{cfa}
@@ -2688,5 +2708,5 @@
 \end{cfa}
 \begin{cfa}[belowskip=0pt]
-sepSet( sout, store );
+sepSet( sout, store );						§\C{// change separator back to original}§
 sout | 1 | 2 | 3 | endl;
 \end{cfa}
@@ -5563,7 +5583,6 @@
 \Celeven prescribes the following standard header-files~\cite[\S~7.1.2]{C11} and \CFA adds to this list:
 \begin{quote2}
-\lstset{deletekeywords={float}}
-\begin{tabular}{@{}llll|l@{}}
-\multicolumn{4}{c|}{C11} & \multicolumn{1}{c}{\CFA}		\\
+\begin{tabular}{@{}lllll|l@{}}
+\multicolumn{5}{c|}{C11} & \multicolumn{1}{c}{\CFA}		\\
 \hline
 \begin{tabular}{@{}l@{}}
@@ -5573,23 +5592,26 @@
 \Indexc{errno.h}		\\
 \Indexc{fenv.h}			\\
-\Indexc{float.h}		\\
-\Indexc{inttypes.h}		\\
-\Indexc{iso646.h}		\\
+\Indexc[deletekeywords=float]{float.h} \\
 \end{tabular}
 &
 \begin{tabular}{@{}l@{}}
+\Indexc{inttypes.h}		\\
+\Indexc{iso646.h}		\\
 \Indexc{limits.h}		\\
 \Indexc{locale.h}		\\
 \Indexc{math.h}			\\
 \Indexc{setjmp.h}		\\
+\end{tabular}
+&
+\begin{tabular}{@{}l@{}}
 \Indexc{signal.h}		\\
 \Indexc{stdalign.h}		\\
 \Indexc{stdarg.h}		\\
 \Indexc{stdatomic.h}	\\
+\Indexc{stdbool.h}		\\
+\Indexc{stddef.h}		\\
 \end{tabular}
 &
 \begin{tabular}{@{}l@{}}
-\Indexc{stdbool.h}		\\
-\Indexc{stddef.h}		\\
 \Indexc{stdint.h}		\\
 \Indexc{stdio.h}		\\
@@ -5607,6 +5629,4 @@
 \Indexc{wctype.h}		\\
 						\\
-						\\
-						\\
 \end{tabular}
 &
@@ -5614,6 +5634,4 @@
 \Indexc{unistd.h}		\\
 \Indexc{gmp.h}			\\
-						\\
-						\\
 						\\
 						\\
@@ -5655,6 +5673,6 @@
 The table shows allocation routines supporting different combinations of storage-management capabilities:
 \begin{center}
-\begin{tabular}{@{}lr|l|l|l|l@{}}
-		&					& \multicolumn{1}{c|}{fill}	& resize	& alignment	& array	\\
+\begin{tabular}{@{}r|r|l|l|l|l@{}}
+\multicolumn{1}{c}{}&		& \multicolumn{1}{c|}{fill}	& resize	& alignment	& array	\\
 \hline
 C		& ©malloc©			& no			& no		& no		& no	\\
@@ -5663,5 +5681,7 @@
 		& ©memalign©		& no			& no		& yes		& no	\\
 		& ©posix_memalign©	& no			& no		& yes		& no	\\
+\hline
 C11		& ©aligned_alloc©	& no			& no		& yes		& no	\\
+\hline
 \CFA	& ©alloc©			& no/copy/yes	& no/yes	& no		& yes	\\
 		& ©align_alloc©		& no/yes		& no		& yes		& yes	\\
