Index: INSTALL
===================================================================
--- INSTALL	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ INSTALL	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -2,8 +2,7 @@
 ======================================
 
-Cforall is built using GNU Make and the GNU Autoconf system.  It also
-requires g++ version 3, bison and flex.  On systems where GNU Make is
-the default make it may suffice to build the system by entering the
-commands
+Cforall is built using GNU Make and the GNU Autoconf system.  It also requires
+g++ version 3, bison and flex.  On systems where GNU Make is the default make
+it may suffice to build the system by entering the commands
 
 	./configure
@@ -13,18 +12,16 @@
 Options for 'configure'
 -----------------------
-The script 'configure' accepts many command line arguments.  Run
-'./configure --help' to see a list of all of them.  This document
-attempts to summarize the most useful arguments.
+The script 'configure' accepts many command line arguments.  Run './configure
+--help' to see a list of all of them.  This document attempts to summarize the
+most useful arguments.
 
---prefix=/some/directory controls the path prefix common to all
-installed cfa-cc components.  Some components will be installed in
-/some/directory/bin, others in /some/directory/lib.  If unspecified,
-this defaults to /usr/local.
+--prefix=/some/directory controls the path prefix common to all installed
+cfa-cc components.  Some components will be installed in /some/directory/bin,
+others in /some/directory/lib.  If unspecified, this defaults to /usr/local.
 
---with-backend-compiler=PROGRAM specifies the installed path of gcc
-3.2.  It defaults to the first command named 'gcc' in the current
-PATH.
+--with-backend-compiler=PROGRAM specifies the installed path of gcc 3.2.  It
+defaults to the first command named 'gcc' in the current PATH.
 
-cfa-cc itself is built with the version of g++ specified by the
-environment variable CXX.  If CXX is unset, cfa-cc is built using the
-first command named 'g++' in the current PATH.
+cfa-cc itself is built with the version of g++ specified by the environment
+variable CXX.  If CXX is unset, cfa-cc is built using the first command named
+'g++' in the current PATH.
Index: Makefile.in
===================================================================
--- Makefile.in	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ Makefile.in	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -38,6 +38,6 @@
 	$(top_srcdir)/libcfa/Makefile.in \
 	$(top_srcdir)/translator/Makefile.in \
-	$(top_srcdir)/translator/examples/Makefile.in AUTHORS COPYING \
-	ChangeLog INSTALL NEWS install-sh missing mkinstalldirs
+	$(top_srcdir)/translator/examples/Makefile.in AUTHORS INSTALL \
+	TODO install-sh missing mkinstalldirs
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/configure.in
@@ -225,13 +225,13 @@
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
-	      echo ' cd $(srcdir) && $(AUTOMAKE) --gnu'; \
-	      $(am__cd) $(srcdir) && $(AUTOMAKE) --gnu \
+	      echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \
+	      $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \
 		&& exit 0; \
 	      exit 1;; \
 	  esac; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \
 	$(am__cd) $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu Makefile
+	  $(AUTOMAKE) --foreign Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
Index: configure
===================================================================
--- configure	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ configure	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -2593,6 +2593,6 @@
 
 # Define the identity of the package.
- PACKAGE=cfa
- VERSION=1.0
+ PACKAGE='cfa-cc'
+ VERSION='1.0'
 
 
@@ -2633,5 +2633,5 @@
 
 
-
+		# do not follow GNU standard
 ac_config_headers="$ac_config_headers config.h"
 
@@ -6472,4 +6472,4 @@
 
 
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: The Cforall translator is now configured for your system" >&5
-$as_echo "The Cforall translator is now configured for your system" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: Cforall configuraton completed. Type \"make install\"." >&5
+$as_echo "Cforall configuraton completed. Type \"make install\"." >&6; }
Index: configure.in
===================================================================
--- configure.in	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ configure.in	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -2,5 +2,5 @@
 AC_CONFIG_SRCDIR([translator/main.cc])
 
-AM_INIT_AUTOMAKE(cfa, 1.0)
+AM_INIT_AUTOMAKE([foreign])		# do not follow GNU standard
 AM_CONFIG_HEADER(config.h)
 
@@ -105,5 +105,3 @@
 dnl Final text
 
-AC_MSG_RESULT(The Cforall translator is now configured for your system)
-dnl AC_MSG_RESULT()
-dnl AC_MSG_RESULT(Perhaps you'd like to inspect the created Makefiles)
+AC_MSG_RESULT(Cforall configuraton completed. Type "make install".)
Index: driver/Makefile.in
===================================================================
--- driver/Makefile.in	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ driver/Makefile.in	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,7 +1,17 @@
-###
-### This file is part of the Cforall project
-###
-### $Id: Makefile.in,v 1.5 2005/08/26 19:16:54 rcbilson Exp $
-###
+######################### -*- Mode: Makefile-Gmake -*- ########################$
+##
+## Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+##
+## The contents of this file are covered under the licence agreement in the
+## file "LICENCE" distributed with Cforall.
+##
+## Makefile.in -- 
+##
+## Author           : Peter A. Buhr
+## Created On       : Sat May 16 07:50:15 2015
+## Last Modified By : Peter A. Buhr
+## Last Modified On : Sat May 16 08:34:55 2015
+## Update Count     : 4
+###############################################################################
 
 CXX=@CXX@
@@ -11,21 +21,21 @@
 
 SRCS:=cfa.cc cc1.cc
-OBJECTS:=$(SRCS:.cc=.o)
-DEPS:=$(SRCS:.cc=.d)
+OBJECTS:=${SRCS:.cc=.o}
+DEPS:=${SRCS:.cc=.d}
 
 all: cfa cc1
 
 cfa: cfa.o
-	$(CXX) $< -o $@
+	${CXX} $< -o $@
 
 cc1 : cc1.o
-	$(CXX) $< -o $@
+	${CXX} $< -o $@
 
 install: cfa cc1
-	$(INSTALL) -d @CFA_BINDIR@
-	$(INSTALL) -d @CFA_LIBDIR@
-	$(INSTALL) cc1 @CFA_LIBDIR@
-	$(INSTALL) cfa @CFA_BINDIR@
+	${INSTALL} -d @CFA_BINDIR@
+	${INSTALL} -d @CFA_LIBDIR@
+	${INSTALL} cc1 @CFA_LIBDIR@
+	${INSTALL} cfa @CFA_BINDIR@
 
 clean:
-	rm -f cfa cc1 $(OBJECTS) $(DEPS) core
+	rm -f cfa cc1 ${OBJECTS} ${DEPS} core
Index: driver/cc1.cc
===================================================================
--- driver/cc1.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ driver/cc1.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,15 +1,16 @@
-//                              -*- Mode: C++ -*-
-// 
-// CForall Version 1.0, Copyright (C) Peter A. Buhr 2005
-// 
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
 // cc1.cc -- 
-// 
-// Author           : Richard C. Bilson
+//
+// Author           : Peter A. Buhr
 // Created On       : Fri Aug 26 14:23:51 2005
 // Last Modified By : Peter A. Buhr
-// Last Modified On : Thu May 14 13:24:45 2015
-// Update Count     : 43
+// Last Modified On : Sat May 16 07:42:14 2015
+// Update Count     : 49
 //
-
 
 #include <iostream>
@@ -18,10 +19,10 @@
 #include <string>
 using std::string;
-#include <cstdio>					// stderr, stdout, perror, fprintf
-#include <cstdlib>					// getenv, exit, mkstemp
-#include <unistd.h>					// execvp, fork, unlink
-#include <sys/wait.h>					// wait
-
-#include "config.h"					// configure info
+#include <cstdio>										// stderr, stdout, perror, fprintf
+#include <cstdlib>										// getenv, exit, mkstemp
+#include <unistd.h>										// execvp, fork, unlink
+#include <sys/wait.h>									// wait
+
+#include "config.h"										// configure info
 
 
@@ -29,5 +30,5 @@
 
 
-string compiler_name( GCC_PATH );                       // path/name of C compiler
+string compiler_name( GCC_PATH );						// path/name of C compiler
 
 string D__GCC_BPREFIX__( "-D__GCC_BPREFIX__=" );
@@ -39,451 +40,452 @@
 
 bool prefix( string arg, string pre ) {
-    return arg.substr( 0, pre.size() ) == pre;
+	return arg.substr( 0, pre.size() ) == pre;
 } // prefix
 
 
 void checkEnv( const char *args[], int &nargs ) {
-    char *value;
-
-    value = getenv( "__COMPILER__" );
-    if ( value != NULL ) {
-	compiler_name = value;
-#ifdef __DEBUG_H__
-	cerr << "env arg:\"" << compiler_name << "\"" << endl;
-#endif // __DEBUG_H__
-    } // if
-
-    value = getenv( "__GCC_MACHINE__" );
-    if ( value != NULL ) {
-	args[nargs] = ( *new string( value ) ).c_str(); // pass the argument along
-#ifdef __DEBUG_H__
-	cerr << "env arg:\"" << args[nargs] << "\"" << endl;
-#endif // __DEBUG_H__
+	char *value;
+
+	value = getenv( "__COMPILER__" );
+	if ( value != NULL ) {
+		compiler_name = value;
+#ifdef __DEBUG_H__
+		cerr << "env arg:\"" << compiler_name << "\"" << endl;
+#endif // __DEBUG_H__
+	} // if
+
+	value = getenv( "__GCC_MACHINE__" );
+	if ( value != NULL ) {
+		args[nargs] = ( *new string( value ) ).c_str(); // pass the argument along
+#ifdef __DEBUG_H__
+		cerr << "env arg:\"" << args[nargs] << "\"" << endl;
+#endif // __DEBUG_H__
+		nargs += 1;
+	} // if
+
+	value = getenv( "__GCC_VERSION__" );
+	if ( value != NULL ) {
+		args[nargs] = ( *new string( value ) ).c_str(); // pass the argument along
+#ifdef __DEBUG_H__
+		cerr << "env arg:\"" << args[nargs] << "\"" << endl;
+#endif // __DEBUG_H__
+		nargs += 1;
+	} // if
+} // checkEnv
+
+
+void rmtmpfile() {
+	if ( unlink( tmpname ) == -1 ) {					// remove tmpname
+		perror ( "CFA Translator error: cpp failed" );
+		exit( EXIT_FAILURE );
+	} // if
+	tmpfilefd = -1;										// mark closed
+} // rmtmpfile
+
+
+void sigTermHandler( int signal ) {
+	if ( tmpfilefd != -1 ) {							// RACE, file created ?
+		rmtmpfile();									// remove
+		exit( EXIT_FAILURE );							// terminate 
+	} // if
+} // sigTermHandler
+
+
+void Stage1( const int argc, const char * const argv[] ) {
+	int code;
+	int i;
+
+	string arg;
+	string bprefix;
+
+	const char *cpp_in = NULL;
+	const char *cpp_out = NULL;
+
+	bool CFA_flag = false;
+	bool cpp_flag = false;
+	const char *o_name = NULL;
+
+	const char *args[argc + 100];						// leave space for 100 additional cpp command line values
+	int nargs = 1;										// number of arguments in args list; 0 => command name
+	const char *uargs[20];								// leave space for 20 additional cfa-cpp command line values
+	int nuargs = 1;										// 0 => command name
+
+	signal( SIGINT,  sigTermHandler );
+	signal( SIGTERM, sigTermHandler );
+
+	// process all the arguments
+
+	checkEnv( args, nargs );							// arguments passed via environment variables
+
+	for ( i = 1; i < argc; i += 1 ) {
+#ifdef __DEBUG_H__
+		cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
+#endif // __DEBUG_H__
+		arg = argv[i];
+#ifdef __DEBUG_H__
+		cerr << "arg:\"" << arg << "\"" << endl;
+#endif // __DEBUG_H__
+		if ( prefix( arg, "-" ) ) {
+			// strip g++ flags that are inappropriate or cause duplicates in subsequent passes
+
+			if ( arg == "-quiet" ) {
+			} else if ( arg == "-imultilib" || arg == "-imultiarch" ) {
+				i += 1;									// and the argument
+			} else if ( prefix( arg, "-A" ) ) {
+			} else if ( prefix( arg, "-D__GNU" ) ) {
+				//********
+				// GCC 5.6.0 SEPARATED THE -D FROM THE ARGUMENT!
+				//********
+			} else if ( arg == "-D" && prefix( argv[i + 1], "__GNU" ) ) {
+				i += 1;									// and the argument
+
+				// strip flags controlling cpp step
+
+			} else if ( arg == "-D__CPP__" ) {
+				cpp_flag = true;
+			} else if ( arg == "-D" && string( argv[i + 1] ) == "__CPP__" ) {
+				i += 1;									// and the argument
+				cpp_flag = true;
+			} else if ( arg == "-D__CFA__" ) {
+				CFA_flag = true;
+			} else if ( arg == "-D" && string( argv[i + 1] ) == "__CFA__" ) {
+				i += 1;									// and the argument
+				CFA_flag = true;
+			} else if ( prefix( arg, D__CFA_FLAGPREFIX__ ) ) {
+				uargs[nuargs] = ( *new string( arg.substr( D__CFA_FLAGPREFIX__.size() ) ) ).c_str();
+				nuargs += 1;
+			} else if ( arg == "-D" && prefix( argv[i + 1], D__CFA_FLAGPREFIX__.substr(2) ) ) {
+				uargs[nuargs] = ( *new string( string( argv[i + 1] ).substr( D__CFA_FLAGPREFIX__.size() - 2 ) ) ).c_str();
+				nuargs += 1;
+				i += 1;									// and the argument
+			} else if ( prefix( arg, D__GCC_BPREFIX__ ) ) {
+				bprefix = arg.substr( D__GCC_BPREFIX__.size() );
+			} else if ( arg == "-D" && prefix( argv[i + 1], D__GCC_BPREFIX__.substr(2) ) ) {
+				bprefix = string( argv[i + 1] ).substr( D__GCC_BPREFIX__.size() - 2 );
+				i += 1;									// and the argument
+
+				// all other flags
+
+			} else if ( arg == "-o" ) {
+				i += 1;
+				o_name = argv[i];
+			} else {
+				args[nargs] = argv[i];					// pass the flag along
+				nargs += 1;
+				// CPP flags with an argument
+				if ( arg == "-D" || arg == "-I" || arg == "-MF" || arg == "-MT" || arg == "-MQ" ||
+					 arg == "-include" || arg == "-imacros" || arg == "-idirafter" || arg == "-iprefix" ||
+					 arg == "-iwithprefix" || arg == "-iwithprefixbefore" || arg == "-isystem" || arg == "-isysroot" ) {
+					i += 1;
+					args[nargs] = argv[i];				// pass the argument along
+					nargs += 1;
+#ifdef __DEBUG_H__
+					cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
+#endif // __DEBUG_H__
+				} else if ( arg == "-MD" || arg == "-MMD" ) {
+					args[nargs] = "-MF";				// insert before file
+					nargs += 1;
+					i += 1;
+					args[nargs] = argv[i];				// pass the argument along
+					nargs += 1;
+#ifdef __DEBUG_H__
+					cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
+#endif // __DEBUG_H__
+				} // if
+			} // if
+		} else {										// obtain input and possibly output files
+			if ( cpp_in == NULL ) {
+				cpp_in = argv[i];
+#ifdef __DEBUG_H__
+				cerr << "cpp_in:\"" << cpp_in << "\"" << endl;
+#endif // __DEBUG_H__
+			} else if ( cpp_out == NULL ) {
+				cpp_out = argv[i];
+#ifdef __DEBUG_H__
+				cerr << "cpp_out:\"" << cpp_out << "\""<< endl;
+#endif // __DEBUG_H__
+			} else {
+				cerr << "Usage: " << argv[0] << " input-file [output-file] [options]" << endl;
+				exit( EXIT_FAILURE );
+			} // if
+		} // if
+	} // for
+
+#ifdef __DEBUG_H__
+	cerr << "args:";
+	for ( i = 1; i < nargs; i += 1 ) {
+		cerr << " " << args[i];
+	} // for
+	if ( cpp_in != NULL ) cerr << " " << cpp_in;
+	if ( cpp_out != NULL ) cerr << " " << cpp_out;
+	cerr << endl;
+#endif // __DEBUG_H__
+
+	if ( cpp_in == NULL ) {
+		cerr << "Usage: " << argv[0] << " input-file [output-file] [options]" << endl;
+		exit( EXIT_FAILURE );
+	} // if
+
+	if ( cpp_flag ) {
+		// The -E flag is specified on the cfa command so only run the preprocessor and output is written to standard
+		// output or -o. The call to cfa has a -E so it does not have to be added to the argument list.
+
+		args[0] = compiler_name.c_str();
+		args[nargs] = cpp_in;
+		nargs += 1;
+		if ( o_name != NULL ) {							// location for output
+			args[nargs] = "-o";
+			nargs += 1;
+			args[nargs] = o_name;
+			nargs += 1;
+		} // if
+		args[nargs] = NULL;								// terminate argument list
+
+#ifdef __DEBUG_H__
+		cerr << "nargs: " << nargs << endl;
+		for ( i = 0; args[i] != NULL; i += 1 ) {
+			cerr << args[i] << " ";
+		} // for
+		cerr << endl;
+#endif // __DEBUG_H__
+
+		execvp( args[0], (char *const *)args );			// should not return
+		perror( "CFA Translator error: cpp level, execvp" );
+		exit( EXIT_FAILURE );
+	} // if
+
+	// Create a temporary file to store output of the C preprocessor.
+
+	tmpfilefd = mkstemp( tmpname );
+	if ( tmpfilefd == -1 ) {
+		perror( "CFA Translator error: cpp level, mkstemp" );
+		exit( EXIT_FAILURE );
+	} // if
+
+#ifdef __DEBUG_H__
+	cerr << "tmpname:" << tmpname << " tmpfilefd:" << tmpfilefd << endl;
+#endif // __DEBUG_H__
+
+	// Run the C preprocessor and save the output in tmpfile.
+
+	if ( fork() == 0 ) {								 // child process ?
+		// -o xxx.ii cannot be used to write the output file from cpp because no output file is created if cpp detects
+		// an error (e.g., cannot find include file). Whereas, output is always generated, even when there is an error,
+		// when cpp writes to stdout. Hence, stdout is redirected into the temporary file.
+		if ( freopen( tmpname, "w", stdout ) == NULL ) { // redirect stdout to tmpname
+			perror( "CFA Translator error: cpp level, freopen" );
+			exit( EXIT_FAILURE );
+		} // if
+
+		args[0] = compiler_name.c_str();
+		args[nargs] = cpp_in;							// input to cpp
+		nargs += 1;
+		args[nargs] = NULL;								// terminate argument list
+
+#ifdef __DEBUG_H__
+		cerr << "cpp nargs: " << nargs << endl;
+		for ( i = 0; args[i] != NULL; i += 1 ) {
+			cerr << args[i] << " ";
+		} // for
+		cerr << endl;
+#endif // __DEBUG_H__
+
+		execvp( args[0], (char *const *)args );			// should not return
+		perror( "CFA Translator error: cpp level, execvp" );
+		exit( EXIT_FAILURE );
+	} // if
+
+	wait( &code );										// wait for child to finish
+
+#ifdef __DEBUG_H__
+	cerr << "return code from cpp:" << WEXITSTATUS(code) << endl;
+#endif // __DEBUG_H__
+
+	if ( WIFSIGNALED(code) != 0 ) {						// child failed ?
+		rmtmpfile();									// remove tmpname
+		cerr << "CFA Translator error: cpp failed with signal " << WTERMSIG(code) << endl;
+		exit( EXIT_FAILURE );
+	} // if
+
+	if ( WEXITSTATUS(code) != 0 ) {						// child error ?
+		rmtmpfile();									// remove tmpname
+		exit( WEXITSTATUS( code ) );					// do not continue
+	} // if
+
+	// If -CFA flag specified, run the cfa-cpp preprocessor on the temporary file, and output is written to standard
+	// output.  Otherwise, run the cfa-cpp preprocessor on the temporary file and save the result into the output file.
+
+	if ( fork() == 0 ) {								// child runs CFA
+		uargs[0] = ( *new string( bprefix + "/cfa-cpp" ) ).c_str();
+
+		uargs[nuargs] = "-p";
+		nuargs += 1;
+
+		uargs[nuargs] = tmpname;
+		nuargs += 1;
+		if ( o_name != NULL ) {
+			uargs[nuargs] = o_name;
+			nuargs += 1;
+		} else if ( ! CFA_flag ) {						// run cfa-cpp ?
+			uargs[nuargs] = cpp_out;
+			nuargs += 1;
+		} // if
+		uargs[nuargs] = NULL;							// terminate argument list
+
+#ifdef __DEBUG_H__
+		cerr << "cfa-cpp nuargs: " << o_name << " " << CFA_flag << " " << nuargs << endl;
+		for ( i = 0; uargs[i] != NULL; i += 1 ) {
+			cerr << uargs[i] << " ";
+		} // for
+		cerr << endl;
+#endif // __DEBUG_H__
+
+		execvp( uargs[0], (char * const *)uargs );		// should not return
+		perror( "CFA Translator error: cpp level, execvp" );
+		exit( EXIT_FAILURE );
+	} // if
+
+	wait( &code );										// wait for child to finish
+
+#ifdef __DEBUG_H__
+	cerr << "return code from cfa-cpp:" << WEXITSTATUS(code) << endl;
+#endif // __DEBUG_H__
+
+	// Must unlink here because file must exist across execvp.
+	rmtmpfile();										// remove tmpname
+
+	if ( WIFSIGNALED(code) ) {							// child failed ?
+		cerr << "CFA Translator error: cfa-cpp failed with signal " << WTERMSIG(code) << endl;
+		exit( EXIT_FAILURE );
+	} // if
+
+	exit( WEXITSTATUS(code) );
+} // Stage1
+
+
+void Stage2( const int argc, const char * const * argv ) {
+	int i;
+
+	string arg;
+
+	const char *cpp_in = NULL;
+
+	const char *args[argc + 100];						// leave space for 100 additional cfa command line values
+	int nargs = 1;										// number of arguments in args list; 0 => command name
+
+	// process all the arguments
+
+	checkEnv( args, nargs );							// arguments passed via environment variables
+
+	for ( i = 1; i < argc; i += 1 ) {
+#ifdef __DEBUG_H__
+		cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
+#endif // __DEBUG_H__
+		arg = argv[i];
+#ifdef __DEBUG_H__
+		cerr << "arg:\"" << arg << "\"" << endl;
+#endif // __DEBUG_H__
+		if ( prefix( arg, "-" ) ) {
+			// strip inappropriate flags
+
+			if ( arg == "-quiet" || arg == "-version" || arg == "-fpreprocessed" ||
+				 // Currently CFA does not suppose precompiled .h files.
+				 prefix( arg, "--output-pch" ) ) {
+
+				// strip inappropriate flags with an argument
+
+			} else if ( arg == "-auxbase" || arg == "-auxbase-strip" || arg == "-dumpbase" ) {
+				i += 1;
+#ifdef __DEBUG_H__
+				cerr << "arg:\"" << argv[i] << "\"" << endl;
+#endif // __DEBUG_H__
+
+				// all other flags
+
+			} else {
+				args[nargs] = argv[i];					// pass the flag along
+				nargs += 1;
+				if ( arg == "-o" ) {
+					i += 1;
+					args[nargs] = argv[i];				// pass the argument along
+					nargs += 1;
+#ifdef __DEBUG_H__
+					cerr << "arg:\"" << argv[i] << "\"" << endl;
+#endif // __DEBUG_H__
+				} // if
+			} // if
+		} else {										// obtain input and possibly output files
+			if ( cpp_in == NULL ) {
+				cpp_in = argv[i];
+#ifdef __DEBUG_H__
+				cerr << "cpp_in:\"" << cpp_in << "\"" << endl;
+#endif // __DEBUG_H__
+			} else {
+				cerr << "Usage: " << argv[0] << " input-file [output-file] [options]" << endl;
+				exit( EXIT_FAILURE );
+			} // if
+		} // if
+	} // for
+
+#ifdef __DEBUG_H__
+	cerr << "args:";
+	for ( i = 1; i < nargs; i += 1 ) {
+		cerr << " " << args[i];
+	} // for
+	cerr << endl;
+	if ( cpp_in != NULL ) cerr << " " << cpp_in;
+#endif // __DEBUG_H__
+
+	args[0] = compiler_name.c_str();
+	args[nargs] = "-S";									// only compile and put assembler output in specified file
 	nargs += 1;
-    } // if
-
-    value = getenv( "__GCC_VERSION__" );
-    if ( value != NULL ) {
-	args[nargs] = ( *new string( value ) ).c_str(); // pass the argument along
-#ifdef __DEBUG_H__
-	cerr << "env arg:\"" << args[nargs] << "\"" << endl;
-#endif // __DEBUG_H__
-	nargs += 1;
-    } // if
-} // checkEnv
-
-
-void rmtmpfile() {
-    if ( unlink( tmpname ) == -1 ) {			// remove tmpname
-	perror ( "CFA Translator error: cpp failed" );
-	exit( EXIT_FAILURE );
-    } // if
-    tmpfilefd = -1;					// mark closed
-} // rmtmpfile
-
-
-void sigTermHandler( int signal ) {
-    if ( tmpfilefd != -1 ) {				// RACE, file created ?
-	rmtmpfile();					// remove
-	exit( EXIT_FAILURE );				// terminate 
-    } // if
-} // sigTermHandler
-
-
-void Stage1( const int argc, const char * const argv[] ) {
-    int code;
-    int i;
-
-    string arg;
-    string bprefix;
-
-    const char *cpp_in = NULL;
-    const char *cpp_out = NULL;
-
-    bool CFA_flag = false;
-    bool cpp_flag = false;
-    const char *o_name = NULL;
-
-    const char *args[argc + 100];			// leave space for 100 additional cpp command line values
-    int nargs = 1;					// number of arguments in args list; 0 => command name
-    const char *uargs[20];				// leave space for 20 additional cfa-cpp command line values
-    int nuargs = 1;					// 0 => command name
-
-    signal( SIGINT,  sigTermHandler );
-    signal( SIGTERM, sigTermHandler );
-
-    // process all the arguments
-
-    checkEnv( args, nargs );				// arguments passed via environment variables
-
-    for ( i = 1; i < argc; i += 1 ) {
-#ifdef __DEBUG_H__
-	cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	arg = argv[i];
-#ifdef __DEBUG_H__
-	cerr << "arg:\"" << arg << "\"" << endl;
-#endif // __DEBUG_H__
-	if ( prefix( arg, "-" ) ) {
-	    // strip g++ flags that are inappropriate or cause duplicates in subsequent passes
-
-	    if ( arg == "-quiet" ) {
-	    } else if ( arg == "-imultilib" || arg == "-imultiarch" ) {
-		i += 1;					// and the argument
-	    } else if ( prefix( arg, "-A" ) ) {
-	    } else if ( prefix( arg, "-D__GNU" ) ) {
-	    //********
-	    // GCC 5.6.0 SEPARATED THE -D FROM THE ARGUMENT!
-	    //********
-	    } else if ( arg == "-D" && prefix( argv[i + 1], "__GNU" ) ) {
-		i += 1;					// and the argument
-
-	    // strip flags controlling cpp step
-
-	    } else if ( arg == "-D__CPP__" ) {
-		cpp_flag = true;
-	    } else if ( arg == "-D" && string( argv[i + 1] ) == "__CPP__" ) {
-		i += 1;					// and the argument
-		cpp_flag = true;
-	    } else if ( arg == "-D__CFA__" ) {
-		CFA_flag = true;
-	    } else if ( arg == "-D" && string( argv[i + 1] ) == "__CFA__" ) {
-		i += 1;					// and the argument
-		CFA_flag = true;
-	    } else if ( prefix( arg, D__CFA_FLAGPREFIX__ ) ) {
-		uargs[nuargs] = ( *new string( arg.substr( D__CFA_FLAGPREFIX__.size() ) ) ).c_str();
-		nuargs += 1;
-	    } else if ( arg == "-D" && prefix( argv[i + 1], D__CFA_FLAGPREFIX__.substr(2) ) ) {
-		uargs[nuargs] = ( *new string( string( argv[i + 1] ).substr( D__CFA_FLAGPREFIX__.size() - 2 ) ) ).c_str();
-		nuargs += 1;
-		i += 1;					// and the argument
-	    } else if ( prefix( arg, D__GCC_BPREFIX__ ) ) {
-		bprefix = arg.substr( D__GCC_BPREFIX__.size() );
-	    } else if ( arg == "-D" && prefix( argv[i + 1], D__GCC_BPREFIX__.substr(2) ) ) {
-		bprefix = string( argv[i + 1] ).substr( D__GCC_BPREFIX__.size() - 2 );
-		i += 1;					// and the argument
-
-	    // all other flags
-
-	    } else if ( arg == "-o" ) {
-	        i += 1;
-	        o_name = argv[i];
-	    } else {
-		args[nargs] = argv[i];			// pass the flag along
-		nargs += 1;
-		// CPP flags with an argument
-		if ( arg == "-D" || arg == "-I" || arg == "-MF" || arg == "-MT" || arg == "-MQ" ||
-		     arg == "-include" || arg == "-imacros" || arg == "-idirafter" || arg == "-iprefix" ||
-		     arg == "-iwithprefix" || arg == "-iwithprefixbefore" || arg == "-isystem" || arg == "-isysroot" ) {
-		    i += 1;
-		    args[nargs] = argv[i];		// pass the argument along
-		    nargs += 1;
-#ifdef __DEBUG_H__
-		    cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-		} else if ( arg == "-MD" || arg == "-MMD" ) {
-		    args[nargs] = "-MF";		// insert before file
-		    nargs += 1;
-		    i += 1;
-		    args[nargs] = argv[i];		// pass the argument along
-		    nargs += 1;
-#ifdef __DEBUG_H__
-		    cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-		} // if
-	    } // if
-	} else {					// obtain input and possibly output files
-	    if ( cpp_in == NULL ) {
-		cpp_in = argv[i];
-#ifdef __DEBUG_H__
-		cerr << "cpp_in:\"" << cpp_in << "\"" << endl;
-#endif // __DEBUG_H__
-	    } else if ( cpp_out == NULL ) {
-		cpp_out = argv[i];
-#ifdef __DEBUG_H__
-		cerr << "cpp_out:\"" << cpp_out << "\""<< endl;
-#endif // __DEBUG_H__
-	    } else {
-		cerr << "Usage: " << argv[0] << " input-file [output-file] [options]" << endl;
-		exit( EXIT_FAILURE );
-	    } // if
-	} // if
-    } // for
-
-#ifdef __DEBUG_H__
-    cerr << "args:";
-    for ( i = 1; i < nargs; i += 1 ) {
-	cerr << " " << args[i];
-    } // for
-    if ( cpp_in != NULL ) cerr << " " << cpp_in;
-    if ( cpp_out != NULL ) cerr << " " << cpp_out;
-    cerr << endl;
-#endif // __DEBUG_H__
-
-    if ( cpp_in == NULL ) {
-	cerr << "Usage: " << argv[0] << " input-file [output-file] [options]" << endl;
-	exit( EXIT_FAILURE );
-    } // if
-
-    if ( cpp_flag ) {
-	// The -E flag is specified on the cfa command so only run the preprocessor and output is written to standard
-	// output or -o. The call to cfa has a -E so it does not have to be added to the argument list.
-
-	args[0] = compiler_name.c_str();
 	args[nargs] = cpp_in;
 	nargs += 1;
-	if ( o_name != NULL ) {				// location for output
-	    args[nargs] = "-o";
-	    nargs += 1;
-	    args[nargs] = o_name;
-	    nargs += 1;
-	} // if
-	args[nargs] = NULL;				// terminate argument list
-
-#ifdef __DEBUG_H__
-	cerr << "nargs: " << nargs << endl;
+	args[nargs] = NULL;									// terminate argument list
+
+#ifdef __DEBUG_H__
+	cerr << "stage2 nargs: " << nargs << endl;
 	for ( i = 0; args[i] != NULL; i += 1 ) {
-	    cerr << args[i] << " ";
+		cerr << args[i] << " ";
 	} // for
 	cerr << endl;
 #endif // __DEBUG_H__
 
-	execvp( args[0], (char *const *)args );		// should not return
+	execvp( args[0], (char * const *)args );			// should not return
 	perror( "CFA Translator error: cpp level, execvp" );
-	exit( EXIT_FAILURE );
-    } // if
-
-    // Create a temporary file to store output of the C preprocessor.
-
-    tmpfilefd = mkstemp( tmpname );
-    if ( tmpfilefd == -1 ) {
-	perror( "CFA Translator error: cpp level, mkstemp" );
-	exit( EXIT_FAILURE );
-    } // if
-
-#ifdef __DEBUG_H__
-    cerr << "tmpname:" << tmpname << " tmpfilefd:" << tmpfilefd << endl;
-#endif // __DEBUG_H__
-
-    // Run the C preprocessor and save the output in tmpfile.
-
-    if ( fork() == 0 ) {				// child process ?
-	// -o xxx.ii cannot be used to write the output file from cpp because no output file is created if cpp detects
-	// an error (e.g., cannot find include file). Whereas, output is always generated, even when there is an error,
-	// when cpp writes to stdout. Hence, stdout is redirected into the temporary file.
-	if ( freopen( tmpname, "w", stdout ) == NULL ) { // redirect stdout to tmpname
-	    perror( "CFA Translator error: cpp level, freopen" );
-	    exit( EXIT_FAILURE );
-	} // if
-
-	args[0] = compiler_name.c_str();
-	args[nargs] = cpp_in;				// input to cpp
-	nargs += 1;
-	args[nargs] = NULL;				// terminate argument list
-
-#ifdef __DEBUG_H__
-	cerr << "cpp nargs: " << nargs << endl;
-	for ( i = 0; args[i] != NULL; i += 1 ) {
-	    cerr << args[i] << " ";
-	} // for
-	cerr << endl;
-#endif // __DEBUG_H__
-
-	execvp( args[0], (char *const *)args );		// should not return
-	perror( "CFA Translator error: cpp level, execvp" );
-	exit( EXIT_FAILURE );
-    } // if
-
-    wait( &code );					// wait for child to finish
-
-#ifdef __DEBUG_H__
-    cerr << "return code from cpp:" << WEXITSTATUS(code) << endl;
-#endif // __DEBUG_H__
-
-    if ( WIFSIGNALED(code) != 0 ) {			// child failed ?
-	rmtmpfile();					// remove tmpname
-	cerr << "CFA Translator error: cpp failed with signal " << WTERMSIG(code) << endl;
-	exit( EXIT_FAILURE );
-    } // if
-
-    if ( WEXITSTATUS(code) != 0 ) {			// child error ?
-	rmtmpfile();					// remove tmpname
-	exit( WEXITSTATUS( code ) );			// do not continue
-    } // if
-
-    // If -CFA flag specified, run the cfa-cpp preprocessor on the temporary file, and output is written to standard
-    // output.  Otherwise, run the cfa-cpp preprocessor on the temporary file and save the result into the output file.
-
-    if ( fork() == 0 ) {				// child runs CFA
-	uargs[0] = ( *new string( bprefix + "/cfa-cpp" ) ).c_str();
-
-	uargs[nuargs] = "-p";
-	nuargs += 1;
-
-	uargs[nuargs] = tmpname;
-	nuargs += 1;
-	if ( o_name != NULL ) {
-	    uargs[nuargs] = o_name;
-	    nuargs += 1;
-	} else if ( ! CFA_flag ) {			// run cfa-cpp ?
-	    uargs[nuargs] = cpp_out;
-	    nuargs += 1;
-	} // if
-	uargs[nuargs] = NULL;				// terminate argument list
-
-#ifdef __DEBUG_H__
-	cerr << "cfa-cpp nuargs: " << o_name << " " << CFA_flag << " " << nuargs << endl;
-	for ( i = 0; uargs[i] != NULL; i += 1 ) {
-	    cerr << uargs[i] << " ";
-	} // for
-	cerr << endl;
-#endif // __DEBUG_H__
-
-	execvp( uargs[0], (char * const *)uargs );	// should not return
-	perror( "CFA Translator error: cpp level, execvp" );
-	exit( EXIT_FAILURE );
-    } // if
-
-    wait( &code );					// wait for child to finish
-
-#ifdef __DEBUG_H__
-    cerr << "return code from cfa-cpp:" << WEXITSTATUS(code) << endl;
-#endif // __DEBUG_H__
-
-    // Must unlink here because file must exist across execvp.
-    rmtmpfile();					// remove tmpname
-
-    if ( WIFSIGNALED(code) ) {				// child failed ?
-	cerr << "CFA Translator error: cfa-cpp failed with signal " << WTERMSIG(code) << endl;
-	exit( EXIT_FAILURE );
-    } // if
-
-    exit( WEXITSTATUS(code) );
-} // Stage1
-
-
-void Stage2( const int argc, const char * const * argv ) {
-    int i;
-
-    string arg;
-
-    const char *cpp_in = NULL;
-
-    const char *args[argc + 100];			// leave space for 100 additional cfa command line values
-    int nargs = 1;					// number of arguments in args list; 0 => command name
-
-    // process all the arguments
-
-    checkEnv( args, nargs );				// arguments passed via environment variables
-
-    for ( i = 1; i < argc; i += 1 ) {
-#ifdef __DEBUG_H__
-	cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	arg = argv[i];
-#ifdef __DEBUG_H__
-	cerr << "arg:\"" << arg << "\"" << endl;
-#endif // __DEBUG_H__
-	if ( prefix( arg, "-" ) ) {
-	    // strip inappropriate flags
-
-	    if ( arg == "-quiet" || arg == "-version" || arg == "-fpreprocessed" ||
-		 // Currently CFA does not suppose precompiled .h files.
-		 prefix( arg, "--output-pch" ) ) {
-
-	    // strip inappropriate flags with an argument
-
-	    } else if ( arg == "-auxbase" || arg == "-auxbase-strip" || arg == "-dumpbase" ) {
-		i += 1;
-#ifdef __DEBUG_H__
-		cerr << "arg:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-
-	    // all other flags
-
-	    } else {
-		args[nargs] = argv[i];			// pass the flag along
-		nargs += 1;
-		if ( arg == "-o" ) {
-		    i += 1;
-		    args[nargs] = argv[i];		// pass the argument along
-		    nargs += 1;
-#ifdef __DEBUG_H__
-		    cerr << "arg:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-		} // if
-	    } // if
-	} else {					// obtain input and possibly output files
-	    if ( cpp_in == NULL ) {
-		cpp_in = argv[i];
-#ifdef __DEBUG_H__
-		cerr << "cpp_in:\"" << cpp_in << "\"" << endl;
-#endif // __DEBUG_H__
-	    } else {
+	exit( EXIT_FAILURE );								// tell gcc not to go any further
+} // Stage2
+
+
+int main( const int argc, const char * const argv[], const char * const env[] ) {
+#ifdef __DEBUG_H__
+	for ( int i = 0; env[i] != NULL; i += 1 ) {
+		cerr << env[i] << endl;
+	} // for
+#endif // __DEBUG_H__
+
+	string arg = argv[1];
+
+	// Currently, stage 1 starts with flag -E and stage 2 with flag -fpreprocessed.
+
+	if ( arg == "-E" ) {
+#ifdef __DEBUG_H__
+		cerr << "Stage1" << endl;
+#endif // __DEBUG_H__
+		Stage1( argc, argv );
+	} else if ( arg == "-fpreprocessed" ) {
+#ifdef __DEBUG_H__
+		cerr << "Stage2" << endl;
+#endif // __DEBUG_H__
+		Stage2( argc, argv );
+	} else {
 		cerr << "Usage: " << argv[0] << " input-file [output-file] [options]" << endl;
 		exit( EXIT_FAILURE );
-	    } // if
-	} // if
-    } // for
-
-#ifdef __DEBUG_H__
-    cerr << "args:";
-    for ( i = 1; i < nargs; i += 1 ) {
-	cerr << " " << args[i];
-    } // for
-    cerr << endl;
-    if ( cpp_in != NULL ) cerr << " " << cpp_in;
-#endif // __DEBUG_H__
-
-    args[0] = compiler_name.c_str();
-    args[nargs] = "-S";					// only compile and put assembler output in specified file
-    nargs += 1;
-    args[nargs] = cpp_in;
-    nargs += 1;
-    args[nargs] = NULL;					// terminate argument list
-
-#ifdef __DEBUG_H__
-    cerr << "stage2 nargs: " << nargs << endl;
-    for ( i = 0; args[i] != NULL; i += 1 ) {
-	cerr << args[i] << " ";
-    } // for
-    cerr << endl;
-#endif // __DEBUG_H__
-
-    execvp( args[0], (char * const *)args );		// should not return
-    perror( "CFA Translator error: cpp level, execvp" );
-    exit( EXIT_FAILURE );				// tell gcc not to go any further
-} // Stage2
-
-
-int main( const int argc, const char * const argv[], const char * const env[] ) {
-#ifdef __DEBUG_H__
-    for ( int i = 0; env[i] != NULL; i += 1 ) {
-	cerr << env[i] << endl;
-    } // for
-#endif // __DEBUG_H__
-
-    string arg = argv[1];
-
-    // Currently, stage 1 starts with flag -E and stage 2 with flag -fpreprocessed.
-
-    if ( arg == "-E" ) {
-#ifdef __DEBUG_H__
-	cerr << "Stage1" << endl;
-#endif // __DEBUG_H__
-	Stage1( argc, argv );
-    } else if ( arg == "-fpreprocessed" ) {
-#ifdef __DEBUG_H__
-	cerr << "Stage2" << endl;
-#endif // __DEBUG_H__
-	Stage2( argc, argv );
-    } else {
-	cerr << "Usage: " << argv[0] << " input-file [output-file] [options]" << endl;
-	exit( EXIT_FAILURE );
-    } // if
+	} // if
 } // main
 
-
 // Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
 // compile-command: "make install" //
 // End: //
Index: driver/cfa.cc
===================================================================
--- driver/cfa.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ driver/cfa.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,22 +1,24 @@
-//                              -*- Mode: C++ -*- 
-// 
-// CForall Version 1.0, Copyright (C) Peter A. Buhr 2002
-// 
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
 // cfa.cc -- 
-// 
+//
 // Author           : Peter A. Buhr
 // Created On       : Tue Aug 20 13:44:49 2002
 // Last Modified By : Peter A. Buhr
-// Last Modified On : Fri May 15 15:01:26 2015
-// Update Count     : 108
-// 
+// Last Modified On : Sat May 16 07:47:05 2015
+// Update Count     : 111
+//
 
 #include <iostream>
-#include <cstdio>					// perror
-#include <cstdlib>					// putenv, exit
-#include <unistd.h>					// execvp
-#include <string>					// STL version
-
-#include "config.h"					// configure info
+#include <cstdio>										// perror
+#include <cstdlib>										// putenv, exit
+#include <unistd.h>										// execvp
+#include <string>										// STL version
+
+#include "config.h"										// configure info
 
 using std::cerr;
@@ -29,329 +31,331 @@
 
 bool prefix( string arg, string pre ) {
-    return arg.substr( 0, pre.size() ) == pre;
+	return arg.substr( 0, pre.size() ) == pre;
 } // prefix
 
 
 void shuffle( const char *args[], int S, int E, int N ) {
-    // S & E index 1 passed the end so adjust with -1
-#ifdef __DEBUG_H__
-    cerr << "shuffle:" << S << " " << E << " " << N << endl;
-#endif // __DEBUG_H__
-    for ( int j = E-1 + N; j > S-1 + N; j -=1 ) {
-#ifdef __DEBUG_H__
-	cerr << "\t" << j << " " << j-N << endl;
-#endif // __DEBUG_H__
-	args[j] = args[j-N];
-    } // for
+	// S & E index 1 passed the end so adjust with -1
+#ifdef __DEBUG_H__
+	cerr << "shuffle:" << S << " " << E << " " << N << endl;
+#endif // __DEBUG_H__
+	for ( int j = E-1 + N; j > S-1 + N; j -=1 ) {
+#ifdef __DEBUG_H__
+		cerr << "\t" << j << " " << j-N << endl;
+#endif // __DEBUG_H__
+		args[j] = args[j-N];
+	} // for
 } // shuffle
 
 
 int main( int argc, char *argv[] ) {
-    string Version( VERSION );				// current version number from CONFIG
-    string Major( "0" ), Minor( "0" ), Patch( "0" );	// default version numbers
-    int posn1 = Version.find( "." );			// find the divider between major and minor version numbers
-    if ( posn1 == -1 ) {				// not there ?
-	Major = Version;
-    } else {
-	Major = Version.substr( 0, posn1 );
-	int posn2 = Version.find( ".", posn1 + 1 );	// find the divider between minor and patch numbers
-	if ( posn2 == -1 ) {				// not there ?
-	    Minor = Version.substr( posn1 );
+	string Version( VERSION );							// current version number from CONFIG
+	string Major( "0" ), Minor( "0" ), Patch( "0" );	// default version numbers
+	int posn1 = Version.find( "." );					// find the divider between major and minor version numbers
+	if ( posn1 == -1 ) {								// not there ?
+		Major = Version;
 	} else {
-	    Minor = Version.substr( posn1 + 1, posn2 - posn1 - 1 );
-	    Patch = Version.substr( posn2 + 1 );
-	} // if
-    } // if
-
-    string installincdir( CFA_INCDIR );			// fixed location of cc1 and cfa-cpp commands
-    string installlibdir( CFA_LIBDIR );			// fixed location of include files
-
-    string heading;					// banner printed at start of cfa compilation
-    string arg;						// current command-line argument during command-line parsing
-    string Bprefix;					// path where gcc looks for compiler command steps
-    string langstd;					// language standard
-
-    string compiler_path( GCC_PATH );			// path/name of C compiler
-    string compiler_name;				// name of C compiler
-
-    bool nonoptarg = false;				// indicates non-option argument specified
-    bool link = true;					// linking as well as compiling
-    bool verbose = false;				// -v flag
-    bool quiet = false;					// -quiet flag
-    bool debug = true;					// -debug flag
-    bool help = false;					// -help flag
-    bool CFA_flag = false;				// -CFA flag
-    bool cpp_flag = false;				// -E or -M flag, preprocessor only
-    bool debugging = false;				// -g flag
-
-    const char *args[argc + 100];			// cfa command line values, plus some space for additional flags
-    int sargs = 1;					// starting location for arguments in args list
-    int nargs = sargs;					// number of arguments in args list; 0 => command name
-
-    const char *libs[argc + 20];			// non-user libraries must come separately, plus some added libraries and flags
-    int nlibs = 0;
-
-#ifdef __DEBUG_H__
-    cerr << "CFA:" << endl;
-#endif // __DEBUG_H__
-
-    // process command-line arguments
-
-    for ( int i = 1; i < argc; i += 1 ) {
-#ifdef __DEBUG_H__
-	cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	arg = argv[i];					// convert to string value
-#ifdef __DEBUG_H__
-	cerr << "arg:\"" << arg << "\"" << endl;
-#endif // __DEBUG_H__
-	if ( prefix( arg, "-" ) ) {
-	    // pass through arguments
-
-	    if ( arg == "-Xlinker" || arg == "-o" ) {
-		args[nargs] = argv[i];			// pass the argument along
-		nargs += 1;
-		i += 1;
-		if ( i == argc ) continue;		// next argument available ?
-		args[nargs] = argv[i];			// pass the argument along
-		nargs += 1;
-	    } else if ( arg == "-XCFA" ) {		// CFA pass through
-		i += 1;
-		args[nargs] = ( *new string( string("-D__CFA_FLAG__=") + argv[i] ) ).c_str();
-		nargs += 1;
-
-	    // CFA specific arguments
-
-	    } else if ( arg == "-CFA" ) {
-		CFA_flag = true;			// strip the -CFA flag
-		link = false;
-		args[nargs] = "-E";			// replace the argument with -E
-		nargs += 1;
-	    } else if ( arg == "-debug" ) {
-		debug = true;				// strip the debug flag
-	    } else if ( arg == "-nodebug" ) {
-		debug = false;				// strip the nodebug flag
-	    } else if ( arg == "-quiet" ) {
-		quiet = true;				// strip the quiet flag
-	    } else if ( arg == "-noquiet" ) {
-		quiet = false;				// strip the noquiet flag
-	    } else if ( arg == "-help" ) {
-		help = true;				// strip the help flag
-	    } else if ( arg == "-nohelp" ) {
-		help = false;				// strip the nohelp flag
-	    } else if ( arg == "-compiler" ) {
-		// use the user specified compiler
-		i += 1;
-		if ( i == argc ) continue;		// next argument available ?
-		compiler_path = argv[i];
-		if ( putenv( (char *)( *new string( string( "__U_COMPILER__=" ) + argv[i]) ).c_str() ) != 0 ) {
-		    cerr << argv[0] << " error, cannot set environment variable." << endl;
-		    exit( EXIT_FAILURE );
+		Major = Version.substr( 0, posn1 );
+		int posn2 = Version.find( ".", posn1 + 1 );		// find the divider between minor and patch numbers
+		if ( posn2 == -1 ) {							// not there ?
+			Minor = Version.substr( posn1 );
+		} else {
+			Minor = Version.substr( posn1 + 1, posn2 - posn1 - 1 );
+			Patch = Version.substr( posn2 + 1 );
 		} // if
-
-	    // C++ specific arguments
-
-	    } else if ( arg == "-v" ) {
-		verbose = true;				// verbosity required
-		args[nargs] = argv[i];			// pass the argument along
-		nargs += 1;
-	    } else if ( arg == "-g" ) {
-		debugging = true;			// symbolic debugging required
-		args[nargs] = argv[i];			// pass the argument along
-		nargs += 1;
-	    } else if ( prefix( arg, "-B" ) ) {
-		Bprefix = arg.substr(2);		// strip the -B flag
+	} // if
+
+	string installincdir( CFA_INCDIR );					// fixed location of cc1 and cfa-cpp commands
+	string installlibdir( CFA_LIBDIR );					// fixed location of include files
+
+	string heading;										// banner printed at start of cfa compilation
+	string arg;											// current command-line argument during command-line parsing
+	string Bprefix;										// path where gcc looks for compiler command steps
+	string langstd;										// language standard
+
+	string compiler_path( GCC_PATH );					// path/name of C compiler
+	string compiler_name;								// name of C compiler
+
+	bool nonoptarg = false;								// indicates non-option argument specified
+	bool link = true;									// linking as well as compiling
+	bool verbose = false;								// -v flag
+	bool quiet = false;									// -quiet flag
+	bool debug = true;									// -debug flag
+	bool help = false;									// -help flag
+	bool CFA_flag = false;								// -CFA flag
+	bool cpp_flag = false;								// -E or -M flag, preprocessor only
+	bool debugging = false;								// -g flag
+
+	const char *args[argc + 100];						// cfa command line values, plus some space for additional flags
+	int sargs = 1;										// starting location for arguments in args list
+	int nargs = sargs;									// number of arguments in args list; 0 => command name
+
+	const char *libs[argc + 20];						// non-user libraries must come separately, plus some added libraries and flags
+	int nlibs = 0;
+
+#ifdef __DEBUG_H__
+	cerr << "CFA:" << endl;
+#endif // __DEBUG_H__
+
+	// process command-line arguments
+
+	for ( int i = 1; i < argc; i += 1 ) {
+#ifdef __DEBUG_H__
+		cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
+#endif // __DEBUG_H__
+		arg = argv[i];									// convert to string value
+#ifdef __DEBUG_H__
+		cerr << "arg:\"" << arg << "\"" << endl;
+#endif // __DEBUG_H__
+		if ( prefix( arg, "-" ) ) {
+			// pass through arguments
+
+			if ( arg == "-Xlinker" || arg == "-o" ) {
+				args[nargs] = argv[i];					// pass the argument along
+				nargs += 1;
+				i += 1;
+				if ( i == argc ) continue;				// next argument available ?
+				args[nargs] = argv[i];					// pass the argument along
+				nargs += 1;
+			} else if ( arg == "-XCFA" ) {				// CFA pass through
+				i += 1;
+				args[nargs] = ( *new string( string("-D__CFA_FLAG__=") + argv[i] ) ).c_str();
+				nargs += 1;
+
+				// CFA specific arguments
+
+			} else if ( arg == "-CFA" ) {
+				CFA_flag = true;						// strip the -CFA flag
+				link = false;
+				args[nargs] = "-E";						// replace the argument with -E
+				nargs += 1;
+			} else if ( arg == "-debug" ) {
+				debug = true;							// strip the debug flag
+			} else if ( arg == "-nodebug" ) {
+				debug = false;							// strip the nodebug flag
+			} else if ( arg == "-quiet" ) {
+				quiet = true;							// strip the quiet flag
+			} else if ( arg == "-noquiet" ) {
+				quiet = false;							// strip the noquiet flag
+			} else if ( arg == "-help" ) {
+				help = true;							// strip the help flag
+			} else if ( arg == "-nohelp" ) {
+				help = false;							// strip the nohelp flag
+			} else if ( arg == "-compiler" ) {
+				// use the user specified compiler
+				i += 1;
+				if ( i == argc ) continue;				// next argument available ?
+				compiler_path = argv[i];
+				if ( putenv( (char *)( *new string( string( "__U_COMPILER__=" ) + argv[i]) ).c_str() ) != 0 ) {
+					cerr << argv[0] << " error, cannot set environment variable." << endl;
+					exit( EXIT_FAILURE );
+				} // if
+
+				// C++ specific arguments
+
+			} else if ( arg == "-v" ) {
+				verbose = true;							// verbosity required
+				args[nargs] = argv[i];					// pass the argument along
+				nargs += 1;
+			} else if ( arg == "-g" ) {
+				debugging = true;						// symbolic debugging required
+				args[nargs] = argv[i];					// pass the argument along
+				nargs += 1;
+			} else if ( prefix( arg, "-B" ) ) {
+				Bprefix = arg.substr(2);				// strip the -B flag
+				args[nargs] = ( *new string( string("-D__GCC_BPREFIX__=") + Bprefix ) ).c_str();
+				nargs += 1;
+			} else if ( prefix( arg, "-b" ) ) {
+				if ( arg.length() == 2 ) {				// separate argument ?
+					i += 1;
+					if ( i == argc ) continue;			// next argument available ?
+					arg += argv[i];						// concatenate argument
+				} // if
+				// later versions of gcc require the -b option to appear at the start of the command line
+				shuffle( args, sargs, nargs, 1 );		// make room at front of argument list
+				args[sargs] = ( *new string( arg ) ).c_str(); // pass the argument along
+				if ( putenv( (char *)( *new string( string( "__GCC_MACHINE__=" ) + arg ) ).c_str() ) != 0 ) {
+					cerr << argv[0] << " error, cannot set environment variable." << endl;
+					exit( EXIT_FAILURE );
+				} // if
+				sargs += 1;
+				nargs += 1;
+			} else if ( prefix( arg, "-V" ) ) {
+				if ( arg.length() == 2 ) {				// separate argument ?
+					i += 1;
+					if ( i == argc ) continue;			// next argument available ?
+					arg += argv[i];						// concatenate argument
+				} // if
+				// later versions of gcc require the -V option to appear at the start of the command line
+				shuffle( args, sargs, nargs, 1 );		// make room at front of argument list
+				args[sargs] = ( *new string( arg ) ).c_str(); // pass the argument along
+				if ( putenv( (char *)( *new string( string( "__GCC_VERSION__=" ) + arg ) ).c_str() ) != 0 ) {
+					cerr << argv[0] << " error, cannot set environment variable." << endl;
+					exit( EXIT_FAILURE );
+				} // if
+				sargs += 1;
+				nargs += 1;
+			} else if ( arg == "-c" || arg == "-S" || arg == "-E" || arg == "-M" || arg == "-MM" ) {
+				args[nargs] = argv[i];					// pass the argument along
+				nargs += 1;
+				if ( arg == "-E" || arg == "-M" || arg == "-MM" ) {
+					cpp_flag = true;					// cpp only
+				} // if
+				link = false;                           // no linkage required
+			} else if ( arg[1] == 'l' ) {
+				// if the user specifies a library, load it after user code
+				libs[nlibs] = argv[i];
+				nlibs += 1;
+			} else {
+				// concatenate any other arguments
+				args[nargs] = argv[i];
+				nargs += 1;
+			} // if
+		} else {
+			// concatenate other arguments
+			args[nargs] = argv[i];
+			nargs += 1;
+			nonoptarg = true;
+		} // if
+	} // for
+
+#ifdef __DEBUG_H__
+	cerr << "args:";
+	for ( int i = 1; i < nargs; i += 1 ) {
+		cerr << " " << args[i];
+	} // for
+	cerr << endl;
+#endif // __DEBUG_H__
+
+	if ( cpp_flag && CFA_flag ) {
+		cerr << argv[0] << " error, cannot use -E and -CFA flags together." << endl;
+		exit( EXIT_FAILURE );
+	} // if
+
+	string d;
+	if ( debug ) {
+		d = "-d";
+	} // if
+
+	args[nargs] = "-I" CFA_INCDIR;
+	nargs += 1;
+
+	if ( link ) {
+		// include the cfa library in case it's needed
+		args[nargs] = "-L" CFA_LIBDIR;
+		nargs += 1;
+		args[nargs] = "-lcfa";
+		nargs += 1;
+	} // if
+
+	// add the correct set of flags based on the type of compile this is
+
+	args[nargs] = ( *new string( string("-D__CFA_MAJOR__=") + Major ) ).c_str();
+	nargs += 1;
+	args[nargs] = ( *new string( string("-D__CFA_MINOR__=") + Minor ) ).c_str();
+	nargs += 1;
+
+	if ( cpp_flag ) {
+		args[nargs] = "-D__CPP__";
+		nargs += 1;
+	} // if
+
+	if ( CFA_flag ) {
+		args[nargs] = "-D__CFA__";
+		nargs += 1;
+	} // if
+
+	if ( debug ) {
+		heading += " (debug)";
+		args[nargs] = "-D__CFA_DEBUG__";
+		nargs += 1;
+	} else {
+		heading += " (no debug)";
+	} // if
+
+	if ( Bprefix.length() == 0 ) {
+		Bprefix = installlibdir;
 		args[nargs] = ( *new string( string("-D__GCC_BPREFIX__=") + Bprefix ) ).c_str();
 		nargs += 1;
-	    } else if ( prefix( arg, "-b" ) ) {
-		if ( arg.length() == 2 ) {		// separate argument ?
-		    i += 1;
-		    if ( i == argc ) continue;		// next argument available ?
-		    arg += argv[i];			// concatenate argument
+	} // if
+
+	// execute the compilation command
+
+	args[0] = compiler_path.c_str();					// set compiler command for exec
+	// find actual name of the compiler independent of the path to it
+	int p = compiler_path.find_last_of( '/' );			// scan r -> l for first '/'
+	if ( p == -1 ) {
+		compiler_name = compiler_path;
+	} else {
+		compiler_name = *new string( compiler_path.substr( p + 1 ) );
+	} // if
+
+	if ( prefix( compiler_name, "gcc" ) ) {				// allow suffix on gcc name
+		args[nargs] = "-no-integrated-cpp";
+		nargs += 1;
+		args[nargs] = "-Wno-deprecated"; 
+		nargs += 1;
+		args[nargs] = "-std=c99";
+		nargs += 1;
+		args[nargs] = ( *new string( string("-B") + Bprefix + "/" ) ).c_str();
+		nargs += 1;
+	} else {
+		cerr << argv[0] << " error, compiler " << compiler_name << " not supported." << endl;
+		exit( EXIT_FAILURE );
+	} // if
+
+	for ( int i = 0; i < nlibs; i += 1 ) {				// copy non-user libraries after all user libraries
+		args[nargs] = libs[i];
+		nargs += 1;
+	} // for
+
+	args[nargs] = NULL;									// terminate with NULL
+
+#ifdef __DEBUG_H__
+	cerr << "nargs: " << nargs << endl;
+	cerr << "args:" << endl;
+	for ( int i = 0; args[i] != NULL; i += 1 ) {
+		cerr << " \"" << args[i] << "\"" << endl;
+	} // for
+#endif // __DEBUG_H__
+
+	if ( ! quiet ) {
+		cerr << "CFA " << "Version " << Version << heading << endl;
+
+		if ( help ) {
+			cerr <<
+				"-debug\t\t\t: use cfa runtime with debug checking" << endl <<
+				"-help\t\t\t: print this help message" << endl <<
+				"-quiet\t\t\t: print no messages from the cfa command" << endl <<
+				"-CFA\t\t\t: run the cpp preprocessor and the cfa-cpp translator" << endl <<
+				"-XCFA -cfa-cpp-flag\t: pass next flag as-is to the cfa-cpp translator" << endl <<
+				"...\t\t\t: any other " << compiler_name << " flags" << endl;
 		} // if
-		// later versions of gcc require the -b option to appear at the start of the command line
-		shuffle( args, sargs, nargs, 1 );	// make room at front of argument list
-		args[sargs] = ( *new string( arg ) ).c_str(); // pass the argument along
-		if ( putenv( (char *)( *new string( string( "__GCC_MACHINE__=" ) + arg ) ).c_str() ) != 0 ) {
-		    cerr << argv[0] << " error, cannot set environment variable." << endl;
-		    exit( EXIT_FAILURE );
-		} // if
-		sargs += 1;
-		nargs += 1;
-	    } else if ( prefix( arg, "-V" ) ) {
-		if ( arg.length() == 2 ) {		// separate argument ?
-		    i += 1;
-		    if ( i == argc ) continue;		// next argument available ?
-		    arg += argv[i];			// concatenate argument
-		} // if
-		// later versions of gcc require the -V option to appear at the start of the command line
-		shuffle( args, sargs, nargs, 1 );	// make room at front of argument list
-		args[sargs] = ( *new string( arg ) ).c_str(); // pass the argument along
-		if ( putenv( (char *)( *new string( string( "__GCC_VERSION__=" ) + arg ) ).c_str() ) != 0 ) {
-		    cerr << argv[0] << " error, cannot set environment variable." << endl;
-		    exit( EXIT_FAILURE );
-		} // if
-		sargs += 1;
-		nargs += 1;
-	    } else if ( arg == "-c" || arg == "-S" || arg == "-E" || arg == "-M" || arg == "-MM" ) {
-		args[nargs] = argv[i];			// pass the argument along
-		nargs += 1;
-		if ( arg == "-E" || arg == "-M" || arg == "-MM" ) {
-		    cpp_flag = true;			// cpp only
-		} // if
-		link = false;                           // no linkage required
-	    } else if ( arg[1] == 'l' ) {
-		// if the user specifies a library, load it after user code
-		libs[nlibs] = argv[i];
-		nlibs += 1;
-	    } else {
-		// concatenate any other arguments
-		args[nargs] = argv[i];
-		nargs += 1;
-	    } // if
-	} else {
-	    // concatenate other arguments
-	    args[nargs] = argv[i];
-	    nargs += 1;
-	    nonoptarg = true;
-	} // if
-    } // for
-
-#ifdef __DEBUG_H__
-    cerr << "args:";
-    for ( int i = 1; i < nargs; i += 1 ) {
-	cerr << " " << args[i];
-    } // for
-    cerr << endl;
-#endif // __DEBUG_H__
-
-    if ( cpp_flag && CFA_flag ) {
-	cerr << argv[0] << " error, cannot use -E and -CFA flags together." << endl;
+	} // if
+
+	if ( verbose ) {
+		if ( argc == 2 ) exit( EXIT_SUCCESS );			// if only the -v flag is specified, do not invoke gcc
+
+		for ( int i = 0; args[i] != NULL; i += 1 ) {
+			cerr << args[i] << " ";
+		} // for
+		cerr << endl;
+	} // if
+
+	if ( ! nonoptarg ) {
+		cerr << argv[0] << " error, no input files" << endl;
+		exit( EXIT_FAILURE );
+	} // if
+
+	// execute the command and return the result
+
+	execvp( args[0], (char *const *)args );				// should not return
+	perror( "CFA Translator error: cfa level, execvp" );
 	exit( EXIT_FAILURE );
-    } // if
-
-    string d;
-    if ( debug ) {
-	d = "-d";
-    } // if
-
-    args[nargs] = "-I" CFA_INCDIR;
-    nargs += 1;
-
-    if ( link ) {
-	// include the cfa library in case it's needed
-	args[nargs] = "-L" CFA_LIBDIR;
-	nargs += 1;
-	args[nargs] = "-lcfa";
-	nargs += 1;
-    } // if
-
-    // add the correct set of flags based on the type of compile this is
-
-    args[nargs] = ( *new string( string("-D__CFA_MAJOR__=") + Major ) ).c_str();
-    nargs += 1;
-    args[nargs] = ( *new string( string("-D__CFA_MINOR__=") + Minor ) ).c_str();
-    nargs += 1;
-
-    if ( cpp_flag ) {
-	args[nargs] = "-D__CPP__";
-	nargs += 1;
-    } // if
-
-    if ( CFA_flag ) {
-	args[nargs] = "-D__CFA__";
-	nargs += 1;
-    } // if
-
-    if ( debug ) {
-	heading += " (debug)";
-	args[nargs] = "-D__CFA_DEBUG__";
-	nargs += 1;
-    } else {
-	heading += " (no debug)";
-    } // if
-
-    if ( Bprefix.length() == 0 ) {
-	Bprefix = installlibdir;
-	args[nargs] = ( *new string( string("-D__GCC_BPREFIX__=") + Bprefix ) ).c_str();
-	nargs += 1;
-    } // if
-
-    // execute the compilation command
-
-    args[0] = compiler_path.c_str();			// set compiler command for exec
-    // find actual name of the compiler independent of the path to it
-    int p = compiler_path.find_last_of( '/' );		// scan r -> l for first '/'
-    if ( p == -1 ) {
-	compiler_name = compiler_path;
-    } else {
-	compiler_name = *new string( compiler_path.substr( p + 1 ) );
-    } // if
-
-    if ( prefix( compiler_name, "gcc" ) ) {		// allow suffix on gcc name
-	args[nargs] = "-no-integrated-cpp";
-	nargs += 1;
-	args[nargs] = "-Wno-deprecated"; 
-	nargs += 1;
-	args[nargs] = "-std=c99";
-	nargs += 1;
-	args[nargs] = ( *new string( string("-B") + Bprefix + "/" ) ).c_str();
-	nargs += 1;
-    } else {
-	cerr << argv[0] << " error, compiler " << compiler_name << " not supported." << endl;
-	exit( EXIT_FAILURE );
-    } // if
-
-    for ( int i = 0; i < nlibs; i += 1 ) {		// copy non-user libraries after all user libraries
-	args[nargs] = libs[i];
-	nargs += 1;
-    } // for
-
-    args[nargs] = NULL;					// terminate with NULL
-
-#ifdef __DEBUG_H__
-    cerr << "nargs: " << nargs << endl;
-    cerr << "args:" << endl;
-    for ( int i = 0; args[i] != NULL; i += 1 ) {
-	cerr << " \"" << args[i] << "\"" << endl;
-    } // for
-#endif // __DEBUG_H__
-
-    if ( ! quiet ) {
-	cerr << "CFA " << "Version " << Version << heading << endl;
-
-	if ( help ) {
-	    cerr <<
-		"-debug\t\t\t: use cfa runtime with debug checking" << endl <<
-		"-help\t\t\t: print this help message" << endl <<
-		"-quiet\t\t\t: print no messages from the cfa command" << endl <<
-		"-CFA\t\t\t: run the cpp preprocessor and the cfa-cpp translator" << endl <<
-		"-XCFA -cfa-cpp-flag\t: pass next flag as-is to the cfa-cpp translator" << endl <<
-		"...\t\t\t: any other " << compiler_name << " flags" << endl;
-	} // if
-    } // if
-
-    if ( verbose ) {
-	if ( argc == 2 ) exit( EXIT_SUCCESS );		// if only the -v flag is specified, do not invoke gcc
-
-	for ( int i = 0; args[i] != NULL; i += 1 ) {
-	    cerr << args[i] << " ";
-	} // for
-	cerr << endl;
-    } // if
-
-    if ( ! nonoptarg ) {
-	cerr << argv[0] << " error, no input files" << endl;
-	exit( EXIT_FAILURE );
-    } // if
-
-    // execute the command and return the result
-
-    execvp( args[0], (char *const *)args );		// should not return
-    perror( "CFA Translator error: cfa level, execvp" );
-    exit( EXIT_FAILURE );
 } // main
 
 // Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
 // compile-command: "make install" //
 // End: //
Index: iver/cpp.cc
===================================================================
--- driver/cpp.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ 	(revision )
@@ -1,379 +1,0 @@
-//                              -*- Mode: C++ -*- 
-// 
-// CForall Version 1.0, Copyright (C) Peter A. Buhr 2002
-// 
-// cpp.cc -- 
-// 
-// Author           : Peter A. Buhr
-// Created On       : Thu Aug 29 12:24:06 2002
-// Last Modified By : Peter A. Buhr
-// Last Modified On : Tue Apr 21 07:23:38 2015
-// Update Count     : 52
-// 
-
-#include <iostream>
-#include <string>
-#include <stdio.h>					// tempnam, freopen, perror
-#include <unistd.h>					// execvp, fork, unlink
-#include <sys/wait.h>					// wait
-
-#include "../config.h"					// configure info
-
-using namespace std;
-
-
-//#define __DEBUG_H__
-
-
-int main( int argc, char *argv[] ) {
-    int code;
-    int i;
-
-    string arg;
-    string bprefix;
-
-    string cpp_in;
-    string cpp_out;
-    string cpp;
-    string cpp_name( "gcc" );
-
-    bool CFA_flag = false;
-    bool cpp_flag = false;
-    bool gnu = false;
-
-    const char *args[argc + 100];			// leave space for 100 additional cfa command line values
-    int nargs = 1;					// 0 => command name
-    const char *argsCppOnly[argc];			// cpp only arguments
-    int nargsCppOnly = 0;
-    const char *argsCFAOnly[argc];			// CFA only arguments
-    int nargsCFAOnly = 0;
-
-    // get a name of a temporary file
-
-    char *tmpfile = tempnam( NULL, "CFA" );		// storage is not freed
-
-#ifdef __DEBUG_H__
-    cerr << "CPP:" << endl;
-#endif // __DEBUG_H__
-
-    // process all the arguments
-
-    for ( i = 1; i < argc; i += 1 ) {
-#ifdef __DEBUG_H__
-	cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	arg = argv[i];
-#ifdef __DEBUG_H__
-	cerr << "arg:\"" << arg << "\"" << endl;
-#endif // __DEBUG_H__
-	if ( arg.substr(0,1) == "-" ) {
-	    if ( arg == "-D__CFA__" ) {
-		CFA_flag = true;			// strip -D__CFA__ flag
-	    } else if ( arg == "-D__CPP__" ) {
-		cpp_flag = true;			// strip -D__CPP__ flag
-	    } else if ( arg.substr(0,sizeof("-D__GNU")-1) == "-D__GNU" ) {
-		gnu = true;				// strip -D__GNUxxx flags to remove duplication
-	    } else if ( arg == "-lang-c" ) {		// strip -lang-c flag
-	    } else if ( arg.substr(0,sizeof("-A")-1) == "-A" ) { // strip -A flags
-	    } else if ( arg.substr(0,sizeof("-D__STDC_HOSTED__")-1) == "-D__STDC_HOSTED__" ) { // strip this define: causes conflict
-	    } else if ( arg.substr(0,sizeof("-o")-1) == "-o" ) {
-		i += 1;					// strip -o flag and its argument
-	    } else if ( arg.substr(0,sizeof("-D__CFA_FLAG__")-1) == "-D__CFA_FLAG__" ) {
-		argsCFAOnly[nargsCFAOnly] = ( *new string( arg.substr(sizeof("-D__CFA_FLAG__")) ) ).c_str(); // pass argument along
-		nargsCFAOnly += 1;
-	    } else if ( arg == "-v" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg.substr(0,sizeof("-I")-1) == "-I" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg == "-C" || arg == "-P" || arg == "-H" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg.substr(0,sizeof("-W")-1) == "-W" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg == "-lint" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg == "-pedantic" || arg == "-pedantic-errors" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg == "-traditional" || arg == "-trigraphs" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg == "-dM" || arg == "-dD" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg == "-M" || arg == "-MG" || arg == "-MM" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg == "-MD" || arg == "-MMD" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-		i += 1;
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-#ifdef __DEBUG_H__
-		cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	    } else if ( arg == "-imacros" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-		i += 1;
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-#ifdef __DEBUG_H__
-		cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	    } else if ( arg == "-include" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-		i += 1;
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-#ifdef __DEBUG_H__
-		cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	    } else if ( arg == "-idirafter" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-		i += 1;
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-#ifdef __DEBUG_H__
-		cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	    } else if ( arg == "-iprefix" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-		i += 1;
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-#ifdef __DEBUG_H__
-		cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	    } else if ( arg == "-iwithprefix" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-		i += 1;
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-#ifdef __DEBUG_H__
-		cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	    } else if ( arg == "-isystem" ) {
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-		i += 1;
-		argsCppOnly[nargsCppOnly] = argv[i];	// pass argument along
-		nargsCppOnly += 1;
-#ifdef __DEBUG_H__
-		cerr << "argv[" << i << "]:\"" << argv[i] << "\"" << endl;
-#endif // __DEBUG_H__
-	    } else if ( arg.substr(0,sizeof("-D__GCC_BPREFIX__")-1) == "-D__GCC_BPREFIX__" ) {
-		bprefix = arg.substr(sizeof("-D__GCC_BPREFIX__"));
-	    } else if ( arg.substr(0,sizeof("-D__GCC_MACHINE__")-1) == "-D__GCC_MACHINE__" ) {
-		argsCppOnly[nargsCppOnly] = "-b";	// pass argument along
-		nargsCppOnly += 1;
-		argsCppOnly[nargsCppOnly] = ( *new string(arg.substr(sizeof("-D__GCC_MACHINE__")) ) ).c_str(); // pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg.substr(0,sizeof("-D__GCC_VERSION__")-1) == "-D__GCC_VERSION__" ) {
-		argsCppOnly[nargsCppOnly] = "-V";	// pass argument along
-		nargsCppOnly += 1;
-		argsCppOnly[nargsCppOnly] = ( *new string( arg.substr(sizeof("-D__GCC_VERSION__")) ) ).c_str(); // pass argument along
-		nargsCppOnly += 1;
-	    } else if ( arg.substr(0,sizeof("-D__CPP_NAME__")-1) == "-D__CPP_NAME__" ) {
-		cpp_name = arg.substr(sizeof("-D__CPP_NAME__"));
-	    } else if ( arg.substr(1,1) != "+" ) {
-		args[nargs] = argv[i];			// pass argument along
-		nargs += 1;
-	    } // if
-	} else {
-	    if ( cpp_in.length() == 0 ) {
-		cpp_in = arg;
-#ifdef __DEBUG_H__
-		cerr << "cpp_in:\"" << cpp_in << "\"" << endl;
-#endif // __DEBUG_H__
-	    } else if ( cpp_out.length() == 0 ) {
-		cpp_out = arg;
-#ifdef __DEBUG_H__
-		cerr << "cpp_out:\"" << cpp_out << "\""<< endl;
-#endif // __DEBUG_H__
-	    } else {
-		cerr << "Usage: " << argv[0] << " input-file [output-file] [options]" << endl;
-		exit( 1 );
-	    } // if
-	} // if
-    } // for
-
-    argsCppOnly[nargsCppOnly] = "-D__cplusplus";
-    nargsCppOnly += 1;
-
-    if ( cpp_in.length() == 0 ) {
-	cerr << "Usage: " << argv[0] << " input-file [output-file] [options]" << endl;
-	exit( 1 );
-    } // if
-
-    if ( cpp_flag && CFA_flag ) {
-	cerr << argv[0] << " Error cannot use -E and -CFA flags together." << endl;
-	exit( EXIT_FAILURE );
-    } // if
-
-    // The -E flag is specified so only run the preprocessor and output is
-    // written to standard output.
-    //
-    // OR
-    //
-    // The preprocessor is called internally during compilation, probably by
-    // "collect" during linking to compile some ctor/dtor code. In this case,
-    // the cfa-cpp preprocessor is not run.  Output is redirected to cpp_out
-
-    if ( cpp_flag || bprefix.length() == 0 ) {
-	if ( ! cpp_flag ) {
-	    if ( freopen( cpp_out.c_str(), "w", stdout ) == NULL ) { // redirect stdout if not -E
-		cerr << argv[0] << ": Error can't write to " << cpp_out << endl;
-		exit( EXIT_FAILURE );
-	    } // if
-
-	    // If called by collect, must prevent the compiler from recursively
-	    // calling this cpp through the -B path. To stop the recursion,
-	    // sent the COMPILER_PATH environment variable to the NULL string,
-	    // which removes the -B path supplied on the initial cfa command.
-
-	    if ( gnu ) {
-		putenv( "COMPILER_PATH=" );
-	    } // if
-	} // if
-
-	if ( bprefix.length() == 0 ) {			// collect ?
-	    args[0] = "gcc";				// use gcc
-	} else {
-	    args[0] = cpp_name.c_str();
-	} // if
-	args[nargs] = "-E";
-	nargs += 1;
-
-	for ( i = 0; i < nargsCppOnly; i += 1 ) {	// copy cpp only arguments
-	    args[nargs] = argsCppOnly[i];
-	    nargs += 1;
-	} // if
-
-	args[nargs] = cpp_in.c_str();
-	nargs += 1;
-	args[nargs] = NULL;				// terminate argument list
-
-#ifdef __DEBUG_H__
-	cerr << "nargs: " << nargs << endl;
-	for ( i = 0; args[i] != NULL; i += 1 ) {
-	    cerr << args[i] << " ";
-	} // for
-	cerr << endl;
-#endif // __DEBUG_H__
-
-	execvp( args[0], (char *const *)args );		// should not return
-	perror( "CFA translator error: cpp level, exec" );
-	exit( EXIT_FAILURE );
-    } // if
-
-    // Run the C preprocessor and save the output in tmpfile.
-
-    if ( fork() == 0 ) {				// child process ?
-	if ( freopen( tmpfile, "w", stdout ) == NULL) {	// redirect output to tmpfile
-	    cerr << argv[0] << ": Error can't write to " << tmpfile << endl;
-	    exit( EXIT_FAILURE );
-	} // if
-
-	args[0] = cpp_name.c_str();
-	args[nargs] = "-E";
-	nargs += 1;
-
-	for ( i = 0; i < nargsCppOnly; i += 1 ) {	// copy cpp only arguments
-	    args[nargs] = argsCppOnly[i];
-	    nargs += 1;
-	} // if
-
-	args[nargs] = cpp_in.c_str();
-	nargs += 1;
-	args[nargs] = NULL;				// terminate argument list
-
-#ifdef __DEBUG_H__
-	cerr << "cpp nargs: " << nargs << endl;
-	for ( i = 0; args[i] != NULL; i += 1 ) {
-	    cerr << args[i] << " ";
-	} // for
-	cerr << endl;
-#endif // __DEBUG_H__
-
-	execvp( args[0], (char *const *)args );		// should not return
-	perror( "CFA translator error: cpp level, exec" );
-	exit( EXIT_FAILURE );
-    } // if
-
-    wait( &code );					// wait for child to finish
-
-    if ( WIFSIGNALED(code) != 0 ) {			// child completed successfully ?
-	unlink( tmpfile );
-	cerr << "CFA translator error: cpp failed with signal " << WTERMSIG(code) << endl;
-	exit( EXIT_FAILURE );
-    } // if
-
-    // If -CFA flag specified, run the cfa-cpp preprocessor on the temporary
-    // file, and output is written to standard output.  Otherwise, run the
-    // cfa-cpp preprocessor on the temporary file and save the result into the
-    // output file.
-
-    if ( fork() == 0 ) {				// child process ?
-	args[0] = ( *new string( bprefix + "/cfa-cpp" ) ).c_str();
-
-	for ( i = 0; i < nargsCFAOnly; i += 1 ) {	// copy CFA only arguments
-	    args[nargs] = argsCFAOnly[i];
-	    nargs += 1;
-	} // if
-	args[nargs] = "-p";
-	nargs += 1;
-
-	args[nargs] = tmpfile;
-	nargs += 1;
-
-	if ( ! CFA_flag ) {				// run cfa-cpp ?
-	    args[nargs] = cpp_out.c_str();
-	    nargs += 1;
-	} // if
-	args[nargs] = NULL;				// terminate argument list
-
-#ifdef __DEBUG_H__
-	cerr << "cfa-cpp nargs: " << nargs << endl;
-	for ( i = 0; args[i] != NULL; i += 1 ) {
-	    cerr << args[i] << " ";
-	} // for
-	cerr << endl;
-#endif // __DEBUG_H__
-
-	execvp( args[0], (char *const *)args );		// should not return
-	perror( "CFA translator error: cpp level, exec" );
-    } // if
-
-    wait( &code );					// wait for child to finish
-
-    if ( unlink( tmpfile ) == -1 ) {
-	cerr << "CFA translator error: cfa-cpp failed " << errno << " to remove temporary file \"" << tmpfile << "\"" << endl;
-	exit( EXIT_FAILURE );
-    } // if
-
-    if ( WIFSIGNALED(code) != 0 ) {			// child completed successfully ?
-	cerr << "CFA translator error: cfa-cpp failed with signal " << WTERMSIG(code) << endl;
-	exit( EXIT_FAILURE );
-    } // if
-
-    if ( CFA_flag ) {					// -CFA flag ?
-	exit( EXIT_FAILURE );				// tell gcc not to go any further
-    } else {
-	exit( WEXITSTATUS(code) );
-    } // if
-} // main
-
-
-// Local Variables: //
-// compile-command: "gmake" //
-// End: //
Index: include/bfd.h
===================================================================
--- include/bfd.h	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ include/bfd.h	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,13 +1,15 @@
-//                              -*- Mode: C++ -*- 
-// 
-// Cforall Version 1.0.0, Copyright (C) Peter A. Buhr 2015
-// 
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
 // bfd.h -- 
-// 
+//
 // Author           : Peter A. Buhr
 // Created On       : Thu Jan  8 15:50:56 2015
 // Last Modified By : Peter A. Buhr
-// Last Modified On : Sat Jan 10 14:12:35 2015
-// Update Count     : 3
+// Last Modified On : Sat May 16 07:54:59 2015
+// Update Count     : 5
 
 // This include file uses the CFA keyword "type" as a field name of a structure.
@@ -19,4 +21,6 @@
 
 // Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
 // compile-command: "make install" //
 // End: //
Index: include/math.h
===================================================================
--- include/math.h	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ include/math.h	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,13 +1,15 @@
-//                              -*- Mode: C++ -*- 
-// 
-// Cforall Version 1.0.0, Copyright (C) Peter A. Buhr 2014
-// 
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
 // math.h -- 
-// 
+//
 // Author           : Peter A. Buhr
 // Created On       : Mon Nov 10 23:41:29 2014
 // Last Modified By : Peter A. Buhr
-// Last Modified On : Sat Jan 10 14:12:21 2015
-// Update Count     : 2
+// Last Modified On : Sat May 16 07:55:52 2015
+// Update Count     : 3
 
 // This include file uses the CFA keyword "type" as a field name of a structure.
@@ -19,4 +21,6 @@
 
 // Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
 // compile-command: "make install" //
 // End: //
Index: libcfa/Makefile.in
===================================================================
--- libcfa/Makefile.in	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ libcfa/Makefile.in	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,18 @@
+######################### -*- Mode: Makefile-Gmake -*- ########################
+##
+## Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+##
+## The contents of this file are covered under the licence agreement in the
+## file "LICENCE" distributed with Cforall.
+##
+## Makefile.in -- 
+##
+## Author           : Peter A. Buhr
+## Created On       : Sat May 16 08:05:18 2015
+## Last Modified By : Peter A. Buhr
+## Last Modified On : Sat May 16 08:06:05 2015
+## Update Count     : 1
+###############################################################################
+
 INSTALL=@INSTALL@
 BACKEND_CC := @BACKEND_CC@
Index: libcfa/prototypes.awk
===================================================================
--- libcfa/prototypes.awk	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ libcfa/prototypes.awk	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+#
+# Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+#
+# The contents of this file are covered under the licence agreement in the
+# file "LICENCE" distributed with Cforall.
+#
+# prototypes.awk -- 
+#
+# Author           : Peter A. Buhr
+# Created On       : Sat May 16 07:57:37 2015
+# Last Modified By : Peter A. Buhr
+# Last Modified On : Sat May 16 08:02:10 2015
+# Update Count     : 3
+# 
+
 # http://llvm.org/svn/llvm-project/cfe/trunk/include/clang/Basic/Builtins.def
 
@@ -4,48 +19,48 @@
     FS = "("
     # order so string search is longest string
-    types[0]  = "UINTMAX";			vtypes[0]  = "unsigned long int"
-    types[1]  = "UINT16";			vtypes[1]  = "short int"
-    types[2]  = "UINT32";			vtypes[2]  = "int"
-    types[3]  = "UINT64";			vtypes[3]  = "long long int"
-    types[4]  = "UINT";				vtypes[4]  = "unsigned int"
-    types[5]  = "INTMAX";			vtypes[5]  = "long int"
-    types[6]  = "INTPTR";			vtypes[6]  = "int *"
-    types[7]  = "WINT";				vtypes[7]  = "unsigned int"
-    types[8]  = "INT";				vtypes[8]  = "int"
-    types[9]  = "ULONGLONG";			vtypes[9]  = "unsigned long long"
-    types[10] = "ULONG";			vtypes[10] = "unsigned long"
-    types[11] = "UNSIGNED";			vtypes[11] = "unsigned"
+    types[0]  = "UINTMAX";					vtypes[0]  = "unsigned long int"
+    types[1]  = "UINT16";					vtypes[1]  = "short int"
+    types[2]  = "UINT32";					vtypes[2]  = "int"
+    types[3]  = "UINT64";					vtypes[3]  = "long long int"
+    types[4]  = "UINT";						vtypes[4]  = "unsigned int"
+    types[5]  = "INTMAX";					vtypes[5]  = "long int"
+    types[6]  = "INTPTR";					vtypes[6]  = "int *"
+    types[7]  = "WINT";						vtypes[7]  = "unsigned int"
+    types[8]  = "INT";						vtypes[8]  = "int"
+    types[9]  = "ULONGLONG";				vtypes[9]  = "unsigned long long"
+    types[10] = "ULONG";					vtypes[10] = "unsigned long"
+    types[11] = "UNSIGNED";					vtypes[11] = "unsigned"
     types[12] = "COMPLEX_LONGDOUBLE";		vtypes[12] = "_Complex long double"
-    types[13] = "COMPLEX_DOUBLE";		vtypes[13] = "_Complex double"
-    types[14] = "COMPLEX_FLOAT";		vtypes[14] = "_Complex float"
-    types[15] = "LONGDOUBLEPTR";		vtypes[15] = "long double *"
-    types[16] = "LONGDOUBLE";			vtypes[16] = "long double"
-    types[17] = "LONGLONG";			vtypes[17] = "long long"
-    types[18] = "LONG";				vtypes[18] = "long"
-    types[19] = "DFLOAT32";			vtypes[19] = "_Decimal32"
-    types[20] = "DFLOAT64";			vtypes[20] = "_Decimal64"
-    types[21] = "DFLOAT128";			vtypes[21] = "_Decimal128"
-    types[22] = "DOUBLEPTR";			vtypes[22] = "double *"
-    types[23] = "DOUBLE";			vtypes[23] = "double"
-    types[24] = "FLOATPTR";			vtypes[24] = "float *"
-    types[25] = "FLOAT";			vtypes[25] = "float"
-    types[26] = "CONST_PTR";			vtypes[26] = "const void *"
-    types[27] = "CONST_STRING";			vtypes[27] = "const char *"
+    types[13] = "COMPLEX_DOUBLE";			vtypes[13] = "_Complex double"
+    types[14] = "COMPLEX_FLOAT";			vtypes[14] = "_Complex float"
+    types[15] = "LONGDOUBLEPTR";			vtypes[15] = "long double *"
+    types[16] = "LONGDOUBLE";				vtypes[16] = "long double"
+    types[17] = "LONGLONG";					vtypes[17] = "long long"
+    types[18] = "LONG";						vtypes[18] = "long"
+    types[19] = "DFLOAT32";					vtypes[19] = "_Decimal32"
+    types[20] = "DFLOAT64";					vtypes[20] = "_Decimal64"
+    types[21] = "DFLOAT128";				vtypes[21] = "_Decimal128"
+    types[22] = "DOUBLEPTR";				vtypes[22] = "double *"
+    types[23] = "DOUBLE";					vtypes[23] = "double"
+    types[24] = "FLOATPTR";					vtypes[24] = "float *"
+    types[25] = "FLOAT";					vtypes[25] = "float"
+    types[26] = "CONST_PTR";				vtypes[26] = "const void *"
+    types[27] = "CONST_STRING";				vtypes[27] = "const char *"
     types[28] = "PTR_FN_VOID_VAR_PTR_SIZE";	vtypes[28] = ""
-    types[29] = "PTR_CONST_STRING";		vtypes[29] = "char *const"
-    types[30] = "PTRMODE_PTR";			vtypes[30] = ""
-    types[31] = "PTRPTR";			vtypes[31] = "void **"
-    types[32] = "PTR";				vtypes[32] = "void *"
-    types[33] = "VOID";				vtypes[33] = "void"
-    types[34] = "STRING";			vtypes[34] = "char *"
-    types[35] = "FILEPTR";			vtypes[35] = "struct _IO_FILE *"
-    types[36] = "SIZE";				vtypes[36] = "unsigned long"
-    types[37] = "VAR";				vtypes[37] = "..."
-    types[38] = "VALIST_ARG";			vtypes[38] = "void **"
-    types[39] = "VALIST_REF";			vtypes[39] = "void **"
-    types[40] = "UNWINDWORD";			vtypes[40] = "void *"
-    types[41] = "WORD";				vtypes[41] = ""
-    types[42] = "SSIZE";			vtypes[42] = "long int"
-    types[43] = "PID";				vtypes[43] = "int"
+    types[29] = "PTR_CONST_STRING";			vtypes[29] = "char *const"
+    types[30] = "PTRMODE_PTR";				vtypes[30] = ""
+    types[31] = "PTRPTR";					vtypes[31] = "void **"
+    types[32] = "PTR";						vtypes[32] = "void *"
+    types[33] = "VOID";						vtypes[33] = "void"
+    types[34] = "STRING";					vtypes[34] = "char *"
+    types[35] = "FILEPTR";					vtypes[35] = "struct _IO_FILE *"
+    types[36] = "SIZE";						vtypes[36] = "unsigned long"
+    types[37] = "VAR";						vtypes[37] = "..."
+    types[38] = "VALIST_ARG";				vtypes[38] = "void **"
+    types[39] = "VALIST_REF";				vtypes[39] = "void **"
+    types[40] = "UNWINDWORD";				vtypes[40] = "void *"
+    types[41] = "WORD";						vtypes[41] = ""
+    types[42] = "SSIZE";					vtypes[42] = "long int"
+    types[43] = "PID";						vtypes[43] = "int"
     N = 44
 } # BEGIN
@@ -60,51 +75,51 @@
     # generate C types for macros names
     for ( i = 0; i < N; i += 1 ) {
-	printf( "#define BT_%s %s\n", types[i], vtypes[i] )
+		printf( "#define BT_%s %s\n", types[i], vtypes[i] )
     } # for
     printf( "\n" )
 
     for ( prototype in prototypes ) {
-	if ( index( "BT_LAST", prototype ) == 1 ) {
-	    continue
-	} # if
+		if ( index( "BT_LAST", prototype ) == 1 ) {
+			continue
+		} # if
 
-	printf( "#define %s(NAME) FUNC_SIMPLE(", prototype )
+		printf( "#define %s(NAME) FUNC_SIMPLE(", prototype )
 
-	if ( sub( "BT_FN_", "", prototype ) == 0 ) {
-	    printf( "\n********** BAD MACRO NAME \"%s\" **********\n", prototype )
-	    exit 0
-	} # if
+		if ( sub( "BT_FN_", "", prototype ) == 0 ) {
+			printf( "\n********** BAD MACRO NAME \"%s\" **********\n", prototype )
+			exit 0
+		} # if
 
-	# generate function return type as macro
-	for ( t = 0; t < N; t += 1 ) {			# find longest match 
-	    type = types[t];
-	    if ( index( prototype, type ) == 1 ) {	# found match
-		printf( "BT_%s, NAME", type )
-		sub( type, "", prototype )
-		break;
-	    } # if
-	} # for
+		# generate function return type as macro
+		for ( t = 0; t < N; t += 1 ) {					# find longest match 
+			type = types[t];
+			if ( index( prototype, type ) == 1 ) {		# found match
+				printf( "BT_%s, NAME", type )
+				sub( type, "", prototype )
+				break;
+			} # if
+		} # for
 
-	# generate function parameter types as macro
-	if ( index( prototype, "VAR" ) != 2 ) {		# C-style empty parameters ?
-	    for ( p = 0; length( prototype ) > 0; p += 1 ) { # until all parameters types are removed
-		sub( "_", "", prototype)		# remove "_"
-		printf( ", ", type )
-		temp = prototype
-		for ( t = 0; t < N; t += 1 ) {		# find longest match
-		    type = types[t];
-		    if ( index( prototype, type ) == 1 ) { # found match
-			printf( "BT_%s", type )
-			sub( type, "", prototype )
-			break;
-		    } # if
-		} # for
-		if ( temp == prototype ) {		# no match found for parameter in macro table
-		    printf( "\n********** MISSING TYPE \"%s\" **********\n", prototype )
-		    exit 0
+		# generate function parameter types as macro
+		if ( index( prototype, "VAR" ) != 2 ) {			# C-style empty parameters ?
+			for ( p = 0; length( prototype ) > 0; p += 1 ) { # until all parameters types are removed
+				sub( "_", "", prototype)				# remove "_"
+				printf( ", ", type )
+				temp = prototype
+				for ( t = 0; t < N; t += 1 ) {			# find longest match
+					type = types[t];
+					if ( index( prototype, type ) == 1 ) { # found match
+						printf( "BT_%s", type )
+						sub( type, "", prototype )
+						break;
+					} # if
+				} # for
+				if ( temp == prototype ) {				# no match found for parameter in macro table
+					printf( "\n********** MISSING TYPE \"%s\" **********\n", prototype )
+					exit 0
+				} # if
+			} # for
 		} # if
-	    } # for
-	} # if
-	printf( ")\n" )
+		printf( ")\n" )
     } # for
 
@@ -115,2 +130,8 @@
     printf( "typedef int wchar_t;\n" );
 } # END
+
+# Local Variables: #
+# tab-width: 4 #
+# mode: awk #
+# compile-command: "make install" #
+# End: #
Index: translator/ArgTweak/FunctionFixer.cc
===================================================================
--- translator/ArgTweak/FunctionFixer.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/ArgTweak/FunctionFixer.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// FunctionFixer.cc -- 
+//
+// Author           : Peter A. Buhr
+// Created On       : Sat May 16 08:12:38 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 08:17:07 2015
+// Update Count     : 5
+//
+
 #include <list>
 #include <vector>
@@ -10,108 +25,101 @@
 
 namespace ArgTweak {
+	FunctionFixer::FunctionFixer( SymTab::Indexer *ind ) : index( ind ) {
+		if ( index == 0 ) index = new SymTab::Indexer();
+	}
 
+	FunctionFixer::~FunctionFixer() {
+		delete index;
+	}
 
-  FunctionFixer::FunctionFixer( SymTab::Indexer *ind ) : index( ind )
-  {
-    if ( index == 0 ) index = new SymTab::Indexer();
-  }
+	DeclarationWithType *FunctionFixer::mutate( FunctionDecl *functionDecl ) {
+		index->visit( functionDecl );
+		/* check for duplicate named parameters here?  It might not be an error if they're never used, on the other hand, it
+		   might be to costly to check for duplicates every time we try a match */
+		return Parent::mutate( functionDecl );
+	}
 
-  FunctionFixer::~FunctionFixer()
-  {
-    delete index;
-  }
+	Expression *FunctionFixer::mutate( UntypedExpr *untypedExpr ) throw ( SemanticError ) {
+		assert( untypedExpr != 0 );
+		NameExpr *function;
 
-  DeclarationWithType *FunctionFixer::mutate( FunctionDecl *functionDecl )
-  {
-    index->visit( functionDecl );
-    /* check for duplicate named parameters here?  It might not be an
-    error if they're never used, on the other hand, it might be to
-    costly to check for duplicates every time we try a match */
-    return Parent::mutate( functionDecl );
-  }
+		if ( ( function = dynamic_cast< NameExpr *>(untypedExpr->get_function()) ) != 0 ) {
+			std::list < DeclarationWithType * > options;
+			index->lookupId ( function->get_name(), options );
+			for ( std::list < DeclarationWithType * >::iterator i = options.begin(); i != options.end(); i++ ) {
+				FunctionType *f;
+				if ( ( f = dynamic_cast< FunctionType * > ( (*i)->get_type() ) ) != 0 )	{
+					std::list < DeclarationWithType * > &pars = f->get_parameters();
 
-  Expression *FunctionFixer::mutate( UntypedExpr *untypedExpr )
-    throw ( SemanticError )
-  {
-    assert( untypedExpr != 0 );
-    NameExpr *function;
+					bool candidateExists ;
+					for ( std::list < DeclarationWithType * >::iterator p = pars.begin(); p != pars.end(); p++ )
+						if ( ( candidateExists = align( f->get_parameters(), untypedExpr->get_args(), Matcher() ) ) ) break;
 
-    if ( ( function = dynamic_cast< NameExpr *>(untypedExpr->get_function()) ) != 0 )
-      {
-	std::list < DeclarationWithType * > options;
-	index->lookupId ( function->get_name(), options );
- 	for ( std::list < DeclarationWithType * >::iterator i = options.begin(); i != options.end(); i++ )
- 	  {
- 	    FunctionType *f;
- 	    if ( ( f = dynamic_cast< FunctionType * > ( (*i)->get_type() ) ) != 0 )
- 	      {
- 		std::list < DeclarationWithType * > &pars = f->get_parameters();
+					if ( !candidateExists ) throw SemanticError("Error in function call");
+				} // if
+			} // for
+		} // if
+		return untypedExpr;
+	}
 
- 		bool candidateExists ;
- 		for( std::list < DeclarationWithType * >::iterator p = pars.begin(); p != pars.end(); p++ )
- 		  if ( ( candidateExists = align( f->get_parameters(), untypedExpr->get_args(), Matcher() ) ) ) break;
+	template < class L1, class L2, class Helper >
+	bool align( L1 &pattern, L2 &possible_permutation, Helper help ) {
+		std::map < typename Helper::key, int > positions;
+		int p = 0;
 
- 		if ( !candidateExists ) throw SemanticError("Error in function call");
- 	      }
- 	  }
-      }
-    return untypedExpr;
-  }
+		for ( typename L1::iterator i = pattern.begin(); i != pattern.end(); i++, p++ )
+			if ( help.extract_key( *i ) != Helper::null_key )
+				positions[ help.extract_key( *i ) ] = p;
 
-  template < class L1, class L2, class Helper >
-  bool align( L1 &pattern, L2 &possible_permutation, Helper help )
-  {
-    std::map < typename Helper::key, int > positions;
-    int p = 0;
+		L2 copy_pp( possible_permutation );
 
-    for ( typename L1::iterator i = pattern.begin(); i != pattern.end(); i++, p++ )
-      if ( help.extract_key( *i ) != Helper::null_key )
-	positions[ help.extract_key( *i ) ] = p;
+		std::vector< typename L2::value_type > temp(copy_pp.size(), Helper::null_value );
+		for ( typename L2::iterator i = copy_pp.begin(); i != copy_pp.end(); i++ )
+			if ( positions.find( help.extract_key( *i ) ) != positions.end() ) {
+				temp [ positions [ help.extract_key( *i ) ] ] = *i;
+				*i = Helper::null_value;
+			} // if
 
-    L2 copy_pp( possible_permutation );
+		// rest of the arguments
+		int a = 0;
+		bool goAhead = true;							// go ahead and change the list
+		for ( typename L2::iterator i = copy_pp.begin(); i != copy_pp.end(); i++, a++ ) {
+			if (  *i != Helper::null_value )
+				if ( temp[a] == Helper::null_value )
+					temp[a] = *i;
+				else
+					{ goAhead = false; /* there's something there already */; break; }
+			else
+				if ( temp[a] == Helper::null_value )
+					{ goAhead = false; /* can't leave empty spaces */ break; }
+				else
+					;									// all good, this was filled during the first pass
+			assert ( temp[a] != Helper::null_value );
+		} // for
 
-    std::vector< typename L2::value_type > temp(copy_pp.size(), Helper::null_value );
-    for ( typename L2::iterator i = copy_pp.begin(); i != copy_pp.end(); i++ )
-      if ( positions.find( help.extract_key( *i ) ) != positions.end() ) {
-	temp [ positions [ help.extract_key( *i ) ] ] = *i;
-	*i = Helper::null_value;
-      }
+		// Change the original list
+		if ( goAhead ) std::copy( temp.begin(), temp.end(), possible_permutation.begin() );
 
-    // rest of the arguments
-    int a = 0;
-    bool goAhead = true;  // go ahead and change the list
-    for ( typename L2::iterator i = copy_pp.begin(); i != copy_pp.end(); i++, a++ ) {
-      if (  *i != Helper::null_value )
-	if ( temp[a] == Helper::null_value )
-	  temp[a] = *i;
-	else
-	  { goAhead = false; /* there's something there already */; break; }
-      else
-	if ( temp[a] == Helper::null_value )
-	  { goAhead = false; /* can't leave empty spaces */ break; }
-	else
-	  ; // all good, this was filled during the first pass
-      assert ( temp[a] != Helper::null_value );
-    }
+		return goAhead;
+	}
 
-    // Change the original list
-    if ( goAhead ) std::copy( temp.begin(), temp.end(), possible_permutation.begin() );
+	std::string FunctionFixer::Matcher::null_key("");
+	Expression *FunctionFixer::Matcher::null_value = 0;
 
-    return goAhead;
-  }
+	std::string FunctionFixer::Matcher::extract_key ( DeclarationWithType *decl ) {
+		return decl->get_name();
+	}
 
-  std::string FunctionFixer::Matcher::null_key("");
-  Expression *FunctionFixer::Matcher::null_value = 0;
+	std::string FunctionFixer::Matcher::extract_key ( Expression *expression ) {
+		if ( expression->get_argName() == 0 )
+			return std::string("");
+		else
+			return *(expression->get_argName());
+	}
+} // namespace ArgTweak
 
-  std::string FunctionFixer::Matcher::extract_key ( DeclarationWithType *decl ) {
-    return decl->get_name();
-  }
-
-  std::string FunctionFixer::Matcher::extract_key ( Expression *expression ) {
-    if ( expression->get_argName() == 0 )
-      return std::string("");
-    else
-      return *(expression->get_argName());
-  }
-
-} // namespace ArgTweak
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/MakeLibCfa.cc
===================================================================
--- translator/MakeLibCfa.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/MakeLibCfa.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,10 +1,19 @@
-/*
- * This file is part of the Cforall project
- *
- * $Id: MakeLibCfa.cc,v 1.6 2005/08/29 20:14:14 rcbilson Exp $
- *
- */
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// MakeLibCfa.cc -- 
+//
+// Author           : Richard C. Bilson
+// Created On       : Sat May 16 10:33:33 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 10:40:44 2015
+// Update Count     : 13
+// 
 
 #include "MakeLibCfa.h"
+#include "SynTree/Visitor.h"
 #include "SynTree/Declaration.h"
 #include "SynTree/Type.h"
@@ -12,95 +21,90 @@
 #include "SynTree/Statement.h"
 #include "SynTree/Initializer.h"
-#include "SynTree/Visitor.h"
 #include "CodeGen/OperatorTable.h"
 #include "UniqueName.h"
 
+namespace LibCfa {
+	class MakeLibCfa : public Visitor {
+	  public:
+		void visit( FunctionDecl* funcDecl );
+		void visit( ObjectDecl* objDecl );
+  
+		std::list< Declaration* > &get_newDecls() { return newDecls; }
+	  private:
+		std::list< Declaration* > newDecls;
+	};
 
-namespace LibCfa {
+	void makeLibCfa( std::list< Declaration* > &prelude ) {
+		MakeLibCfa maker;
+		acceptAll( prelude, maker );
+		prelude.splice( prelude.end(), maker.get_newDecls() );
+	}
 
-class MakeLibCfa : public Visitor
-{
-public:
-  void visit( FunctionDecl* funcDecl );
-  void visit( ObjectDecl* objDecl );
+	void MakeLibCfa::visit( FunctionDecl* origFuncDecl ) {
+		if ( origFuncDecl->get_linkage() != LinkageSpec::Intrinsic ) return;
   
-  std::list< Declaration* > &get_newDecls() { return newDecls; }
+		FunctionDecl *funcDecl = origFuncDecl->clone();
+		CodeGen::OperatorInfo opInfo;
+		bool lookResult = CodeGen::operatorLookup( funcDecl->get_name(), opInfo );
+		assert( lookResult );
+		assert( !funcDecl->get_statements() );
+		UntypedExpr *newExpr = new UntypedExpr( new NameExpr( funcDecl->get_name() ) );
+		UniqueName paramNamer( "_p" );
+		std::list< DeclarationWithType* >::iterator param = funcDecl->get_functionType()->get_parameters().begin();
+		assert( param != funcDecl->get_functionType()->get_parameters().end() );
+
+		if ( (*param)->get_name() == "" ) {
+			(*param)->set_name( paramNamer.newName() );
+			(*param)->set_linkage( LinkageSpec::C );
+		} // if
+
+		switch( opInfo.type ) {
+		  case CodeGen::OT_INDEX:
+		  case CodeGen::OT_CALL:
+		  case CodeGen::OT_PREFIX:
+		  case CodeGen::OT_POSTFIX:
+		  case CodeGen::OT_INFIX:
+			newExpr->get_args().push_back( new VariableExpr( *param ) );
+			break;
+		  case CodeGen::OT_PREFIXASSIGN:
+		  case CodeGen::OT_POSTFIXASSIGN:
+		  case CodeGen::OT_INFIXASSIGN:
+			{
+				newExpr->get_args().push_back( new VariableExpr( *param ) );
+				// UntypedExpr *deref = new UntypedExpr( new NameExpr( "*?" ) );
+				// deref->get_args().push_back( new VariableExpr( *param ) );
+				// newExpr->get_args().push_back( deref );
+				break;
+			}
+		  case CodeGen::OT_CONSTANT:
+			assert( false );
+		} // switch
+
+		for ( param++; param != funcDecl->get_functionType()->get_parameters().end(); ++param ) {
+			if ( (*param)->get_name() == "" ) {
+				(*param)->set_name( paramNamer.newName() );
+				(*param)->set_linkage( LinkageSpec::C );
+			}
+			newExpr->get_args().push_back( new VariableExpr( *param ) );
+		} // for
+		funcDecl->set_statements( new CompoundStmt( std::list< Label >() ) );
+		funcDecl->get_statements()->get_kids().push_back( new ReturnStmt( std::list< Label >(), newExpr ) );
+		newDecls.push_back( funcDecl );
+	}
+
+	void MakeLibCfa::visit( ObjectDecl* origObjDecl ) {
+		if ( origObjDecl->get_linkage() != LinkageSpec::Intrinsic ) return;
   
-private:
-  std::list< Declaration* > newDecls;
-};
+		ObjectDecl *objDecl = origObjDecl->clone();
+		assert( !objDecl->get_init() );
+		std::list< Expression* > noDesignators;
+		objDecl->set_init( new SingleInit( new NameExpr( objDecl->get_name() ), noDesignators ) );
+		newDecls.push_back( objDecl );
+	}
+} // namespace LibCfa
 
-void
-makeLibCfa( std::list< Declaration* > &prelude )
-{
-  MakeLibCfa maker;
-  acceptAll( prelude, maker );
-  prelude.splice( prelude.end(), maker.get_newDecls() );
-}
-
-void 
-MakeLibCfa::visit( FunctionDecl* origFuncDecl )
-{
-  if( origFuncDecl->get_linkage() != LinkageSpec::Intrinsic ) return;
-  
-  FunctionDecl *funcDecl = origFuncDecl->clone();
-  CodeGen::OperatorInfo opInfo;
-  bool lookResult = CodeGen::operatorLookup( funcDecl->get_name(), opInfo );
-  assert( lookResult );
-  assert( !funcDecl->get_statements() );
-  UntypedExpr *newExpr = new UntypedExpr( new NameExpr( funcDecl->get_name() ) );
-  UniqueName paramNamer( "_p" );
-  std::list< DeclarationWithType* >::iterator param = funcDecl->get_functionType()->get_parameters().begin();
-  assert( param != funcDecl->get_functionType()->get_parameters().end() );
-  if( (*param)->get_name() == "" ) {
-    (*param)->set_name( paramNamer.newName() );
-    (*param)->set_linkage( LinkageSpec::C );
-  }
-  switch( opInfo.type ) {
-  case CodeGen::OT_INDEX:
-  case CodeGen::OT_CALL:
-  case CodeGen::OT_PREFIX:
-  case CodeGen::OT_POSTFIX:
-  case CodeGen::OT_INFIX:
-    newExpr->get_args().push_back( new VariableExpr( *param ) );
-    break;
-    
-  case CodeGen::OT_PREFIXASSIGN:
-  case CodeGen::OT_POSTFIXASSIGN:
-  case CodeGen::OT_INFIXASSIGN:
-  {
-    newExpr->get_args().push_back( new VariableExpr( *param ) );
-///     UntypedExpr *deref = new UntypedExpr( new NameExpr( "*?" ) );
-///     deref->get_args().push_back( new VariableExpr( *param ) );
-///     newExpr->get_args().push_back( deref );
-    break;
-  }
-    
-  case CodeGen::OT_CONSTANT:
-    assert( false );
-  }
-  for( param++; param != funcDecl->get_functionType()->get_parameters().end(); ++param ) {
-    if( (*param)->get_name() == "" ) {
-      (*param)->set_name( paramNamer.newName() );
-      (*param)->set_linkage( LinkageSpec::C );
-    }
-    newExpr->get_args().push_back( new VariableExpr( *param ) );
-  }
-  funcDecl->set_statements( new CompoundStmt( std::list< Label >() ) );
-  funcDecl->get_statements()->get_kids().push_back( new ReturnStmt( std::list< Label >(), newExpr ) );
-  newDecls.push_back( funcDecl );
-}
-
-void 
-MakeLibCfa::visit( ObjectDecl* origObjDecl )
-{
-  if( origObjDecl->get_linkage() != LinkageSpec::Intrinsic ) return;
-  
-  ObjectDecl *objDecl = origObjDecl->clone();
-  assert( !objDecl->get_init() );
-  std::list< Expression* > noDesignators;
-  objDecl->set_init( new SingleInit( new NameExpr( objDecl->get_name() ), noDesignators ) );
-  newDecls.push_back( objDecl );
-}
-
-} // namespace LibCfa
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/MakeLibCfa.h
===================================================================
--- translator/MakeLibCfa.h	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/MakeLibCfa.h	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,8 +1,16 @@
-/*
- * This file is part of the Cforall project
- *
- * $Id: MakeLibCfa.h,v 1.2 2005/08/29 20:14:14 rcbilson Exp $
- *
- */
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// MakeLibCfa.h -- 
+//
+// Author           : Richard C. Bilson
+// Created On       : Sat May 16 10:42:14 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 10:43:29 2015
+// Update Count     : 1
+//
 
 #ifndef LIBCFA_MAKELIBCFA_H
@@ -13,8 +21,12 @@
 
 namespace LibCfa {
-
-void makeLibCfa( std::list< Declaration* > &prelude );
-
+	void makeLibCfa( std::list< Declaration* > &prelude );
 } // namespace LibCfa
 
-#endif /* #ifndef LIBCFA_MAKELIBCFA_H */
+#endif // LIBCFA_MAKELIBCFA_H
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Makefile.in
===================================================================
--- translator/Makefile.in	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Makefile.in	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,11 +1,24 @@
-# This makefile is adapted from Peter Miller's article
-# "Recursive Make Considered Harmful"
-#
-# http://www.pcug.org.au/~millerp/rmch/recu-make-cons-harm.html
+######################### -*- Mode: Makefile-Gmake -*- ########################
+##
+## Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+##
+## The contents of this file are covered under the licence agreement in the
+## file "LICENCE" distributed with Cforall.
+##
+## Makefile.in -- 
+##
+## Author           : Peter A. Buhr
+## Created On       : Sat May 16 08:37:37 2015
+## Last Modified By : Peter A. Buhr
+## Last Modified On : Sat May 16 08:38:52 2015
+## Update Count     : 2
+###############################################################################
 
-MODULES := Common Parser SynTree SymTab ResolvExpr CodeGen ControlStruct GenPoly Tuples InitTweak Designators #Try ArgTweak Explain
+# This makefile is adapted from Peter Miller's article "Recursive Make Considered Harmful"
+
+MODULES := Common Parser SynTree SymTab ResolvExpr CodeGen ControlStruct GenPoly Tuples InitTweak Designators # Try ArgTweak Explain
 TARGET := cfa-cpp
 
-all: $(TARGET)
+all: ${TARGET}
 
 # look for include files in each of the modules
@@ -16,8 +29,4 @@
 # this is the back-end compiler, used to compile libcfa & builtins to link with user code
 BACKEND_CC := @BACKEND_CC@
-
-# uncomment the definition of this variable to enable purify
-#  (do a "purerun" first)
-#PURIFY := purify --cache-dir=$(HOME)/tmp
 
 # extra libraries if required
@@ -31,27 +40,27 @@
 
 # include the description for each module
-include $(patsubst %,%/module.mk,$(MODULES))
+include ${patsubst %,%/module.mk,${MODULES}}
 
 # determine the object files
-OBJ := $(patsubst %.cc,%.o,$(filter %.cc,$(SRC))) \
-       $(patsubst %.y,%.tab.o,$(filter %.y,$(SRC))) \
-       $(patsubst %.l,%.yy.o,$(filter %.l,$(SRC)))
+OBJ := ${patsubst %.cc,%.o,${filter %.cc,${SRC}}} \
+       ${patsubst %.y,%.tab.o,${filter %.y,${SRC}}} \
+       ${patsubst %.l,%.yy.o,${filter %.l,${SRC}}}
 
 # include the C include dependencies
-DEPS := $(OBJ:.o=.d)
--include $(DEPS)
+DEPS := ${OBJ:.o=.d}
+-include ${DEPS}
 
 # link the program
-$(TARGET): $(OBJ)
-	$(PURIFY) $(CXX) -o $@ $(OBJ) $(LIBS)
+${TARGET}: ${OBJ}
+	${PURIFY} ${CXX} -o $@ ${OBJ} ${LIBS}
 
 #installing
-install: $(TARGET)
-	$(INSTALL) -d @CFA_LIBDIR@
-	$(INSTALL) $(TARGET) @CFA_LIBDIR@
+install: ${TARGET}
+	${INSTALL} -d @CFA_LIBDIR@
+	${INSTALL} ${TARGET} @CFA_LIBDIR@
 
 # clean-up rule
 clean:
-	rm -f $(OBJ) $(DEPS) $(TARGET) tags $(EXTRA_OUTPUT)
+	rm -f ${OBJ} ${DEPS} ${TARGET} tags ${EXTRA_OUTPUT}
 	find . -name "Expected*" -prune -o \( -name "*.tst" -o -name "report" \) -print | xargs rm -f
 	find . -name "core*" -print | xargs rm -f
Index: translator/Parser/DeclarationNode.cc
===================================================================
--- translator/Parser/DeclarationNode.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/DeclarationNode.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// DeclarationNode.cc -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 12:34:05 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 12:38:20 2015
+// Update Count     : 4
+//
+
 #include <string>
 #include <list>
@@ -23,14 +38,14 @@
 
 DeclarationNode *DeclarationNode::clone() const {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = maybeClone( type );
-    newnode->name = name;
-    newnode->storageClasses = storageClasses;
-    newnode->bitfieldWidth = maybeClone( bitfieldWidth );
-    newnode->hasEllipsis = hasEllipsis;
-    newnode->initializer = initializer;
-    newnode->next = maybeClone( next );
-    newnode->linkage = linkage;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = maybeClone( type );
+	newnode->name = name;
+	newnode->storageClasses = storageClasses;
+	newnode->bitfieldWidth = maybeClone( bitfieldWidth );
+	newnode->hasEllipsis = hasEllipsis;
+	newnode->initializer = initializer;
+	newnode->next = maybeClone( next );
+	newnode->linkage = linkage;
+	return newnode;
 }
 
@@ -39,744 +54,742 @@
 
 DeclarationNode::~DeclarationNode() {
-    delete type;
-    delete bitfieldWidth;
-    delete initializer;
+	delete type;
+	delete bitfieldWidth;
+	delete initializer;
 }
 
 bool DeclarationNode::get_hasEllipsis() const {
-    return hasEllipsis;
+	return hasEllipsis;
 }
 
 const char *storageClassName[] = {
-    // order must correspond with DeclarationNode::StorageClass
-    "extern",
-    "static",
-    "auto",
-    "register",
-    "inline",
-    "fortran",
+	// order must correspond with DeclarationNode::StorageClass
+	"extern",
+	"static",
+	"auto",
+	"register",
+	"inline",
+	"fortran",
 };
 
 void DeclarationNode::print( std::ostream &os, int indent ) const {
-    os << string(indent, ' ' );
-    if ( name == "" ) {
-	os << "unnamed: ";
-    } else {
-	os << name << ": ";
-    }
-
-    if ( linkage != LinkageSpec::Cforall ) {
-	os << LinkageSpec::toString( linkage ) << " ";
-    }
-
-    printEnums( storageClasses.begin(), storageClasses.end(), storageClassName, os );
-    if ( type ) {
-	type->print( os, indent );
-    } else {
-	os << "untyped entity ";
-    }
-
-    if ( bitfieldWidth ) {
-	os << endl << string(indent+2,  ' ') << "with bitfield width ";
-	bitfieldWidth->printOneLine( os );
-    }
-
-    if ( initializer != 0 ) {
-	os << endl << string(indent+2,  ' ') << "with initializer ";
-	initializer->printOneLine( os );
-    }
-
-    os << endl;
+	os << string(indent, ' ' );
+	if ( name == "" ) {
+		os << "unnamed: ";
+	} else {
+		os << name << ": ";
+	}
+
+	if ( linkage != LinkageSpec::Cforall ) {
+		os << LinkageSpec::toString( linkage ) << " ";
+	}
+
+	printEnums( storageClasses.begin(), storageClasses.end(), storageClassName, os );
+	if ( type ) {
+		type->print( os, indent );
+	} else {
+		os << "untyped entity ";
+	}
+
+	if ( bitfieldWidth ) {
+		os << endl << string(indent+2,  ' ') << "with bitfield width ";
+		bitfieldWidth->printOneLine( os );
+	}
+
+	if ( initializer != 0 ) {
+		os << endl << string(indent+2,  ' ') << "with initializer ";
+		initializer->printOneLine( os );
+	}
+
+	os << endl;
 }
 
 void DeclarationNode::printList( std::ostream &os, int indent ) const {
-    ParseNode::printList( os, indent );
-    if ( hasEllipsis ) {
-	os << string( indent, ' ' )  << "and a variable number of other arguments" << endl;
-    }
+	ParseNode::printList( os, indent );
+	if ( hasEllipsis ) {
+		os << string( indent, ' ' )  << "and a variable number of other arguments" << endl;
+	}
 }
 
 DeclarationNode *DeclarationNode::newFunction( std::string *name, DeclarationNode *ret, DeclarationNode *param, StatementNode *body, bool newStyle ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->name = assign_strptr( name );
-
-    newnode->type = new TypeData( TypeData::Function );
-    newnode->type->function->params = param;
-    newnode->type->function->newStyle = newStyle;
-    newnode->type->function->body = body;
-
-    if ( body ) {
-	newnode->type->function->hasBody = true;
-    }
-
-    if ( ret ) {
-	newnode->type->base = ret->type;
-	ret->type = 0;
-	delete ret;
-    }
-
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->name = assign_strptr( name );
+
+	newnode->type = new TypeData( TypeData::Function );
+	newnode->type->function->params = param;
+	newnode->type->function->newStyle = newStyle;
+	newnode->type->function->body = body;
+
+	if ( body ) {
+		newnode->type->function->hasBody = true;
+	}
+
+	if ( ret ) {
+		newnode->type->base = ret->type;
+		ret->type = 0;
+		delete ret;
+	}
+
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newQualifier( Qualifier q ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData();
-    newnode->type->qualifiers.push_back( q );
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData();
+	newnode->type->qualifiers.push_back( q );
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newStorageClass( StorageClass sc ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->storageClasses.push_back( sc );
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->storageClasses.push_back( sc );
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newBasicType( BasicType bt ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Basic );
-    newnode->type->basic->typeSpec.push_back( bt );
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Basic );
+	newnode->type->basic->typeSpec.push_back( bt );
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newModifier( Modifier mod ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Basic );
-    newnode->type->basic->modifiers.push_back( mod );
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Basic );
+	newnode->type->basic->modifiers.push_back( mod );
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newForall( DeclarationNode* forall ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Unknown );
-    newnode->type->forall = forall;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Unknown );
+	newnode->type->forall = forall;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newFromTypedef( std::string* name ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::SymbolicInst );
-    newnode->type->symbolic->name = assign_strptr( name );
-    newnode->type->symbolic->isTypedef = true;
-    newnode->type->symbolic->params = 0;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::SymbolicInst );
+	newnode->type->symbolic->name = assign_strptr( name );
+	newnode->type->symbolic->isTypedef = true;
+	newnode->type->symbolic->params = 0;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newAggregate( TyCon kind, std::string* name, DeclarationNode *formals, ExpressionNode *actuals, DeclarationNode *fields ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Aggregate );
-    newnode->type->aggregate->kind = kind;
-    newnode->type->aggregate->name = assign_strptr( name );
-    if ( newnode->type->aggregate->name == "" ) {
-	newnode->type->aggregate->name = DeclarationNode::anonymous.newName();
-    }
-    newnode->type->aggregate->params = formals;
-    newnode->type->aggregate->actuals = actuals;
-    newnode->type->aggregate->members = fields;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Aggregate );
+	newnode->type->aggregate->kind = kind;
+	newnode->type->aggregate->name = assign_strptr( name );
+	if ( newnode->type->aggregate->name == "" ) {
+		newnode->type->aggregate->name = DeclarationNode::anonymous.newName();
+	}
+	newnode->type->aggregate->params = formals;
+	newnode->type->aggregate->actuals = actuals;
+	newnode->type->aggregate->members = fields;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newEnum( std::string *name, DeclarationNode *constants ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->name = assign_strptr( name );
-    newnode->type = new TypeData( TypeData::Enum );
-    newnode->type->enumeration->name = newnode->name;
-    if ( newnode->type->enumeration->name == "" ) {
-	newnode->type->enumeration->name = DeclarationNode::anonymous.newName();
-    }
-    newnode->type->enumeration->constants = constants;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->name = assign_strptr( name );
+	newnode->type = new TypeData( TypeData::Enum );
+	newnode->type->enumeration->name = newnode->name;
+	if ( newnode->type->enumeration->name == "" ) {
+		newnode->type->enumeration->name = DeclarationNode::anonymous.newName();
+	}
+	newnode->type->enumeration->constants = constants;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newEnumConstant( std::string* name, ExpressionNode *constant ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->name = assign_strptr( name );
-    // do something with the constant
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->name = assign_strptr( name );
+	// do something with the constant
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newName( std::string* name ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->name = assign_strptr( name );
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->name = assign_strptr( name );
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newFromTypeGen( std::string* name, ExpressionNode *params ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::SymbolicInst );
-    newnode->type->symbolic->name = assign_strptr( name );
-    newnode->type->symbolic->isTypedef = false;
-    newnode->type->symbolic->actuals = params;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::SymbolicInst );
+	newnode->type->symbolic->name = assign_strptr( name );
+	newnode->type->symbolic->isTypedef = false;
+	newnode->type->symbolic->actuals = params;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newTypeParam( TypeClass tc, std::string* name ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->name = assign_strptr( name );
-    newnode->type = new TypeData( TypeData::Variable );
-    newnode->type->variable->tyClass = tc;
-    newnode->type->variable->name = newnode->name;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->name = assign_strptr( name );
+	newnode->type = new TypeData( TypeData::Variable );
+	newnode->type->variable->tyClass = tc;
+	newnode->type->variable->name = newnode->name;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newContext( std::string *name, DeclarationNode *params, DeclarationNode *asserts ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Aggregate );
-    newnode->type->aggregate->kind = Context;
-    newnode->type->aggregate->params = params;
-    newnode->type->aggregate->members = asserts;
-    newnode->type->aggregate->name = assign_strptr( name );
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Aggregate );
+	newnode->type->aggregate->kind = Context;
+	newnode->type->aggregate->params = params;
+	newnode->type->aggregate->members = asserts;
+	newnode->type->aggregate->name = assign_strptr( name );
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newContextUse( std::string *name, ExpressionNode *params ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::AggregateInst );
-    newnode->type->aggInst->aggregate = new TypeData( TypeData::Aggregate );
-    newnode->type->aggInst->aggregate->aggregate->kind = Context;
-    newnode->type->aggInst->aggregate->aggregate->name = assign_strptr( name );
-    newnode->type->aggInst->params = params;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::AggregateInst );
+	newnode->type->aggInst->aggregate = new TypeData( TypeData::Aggregate );
+	newnode->type->aggInst->aggregate->aggregate->kind = Context;
+	newnode->type->aggInst->aggregate->aggregate->name = assign_strptr( name );
+	newnode->type->aggInst->params = params;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newTypeDecl( std::string *name, DeclarationNode *typeParams ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->name = assign_strptr( name );
-    newnode->type = new TypeData( TypeData::Symbolic );
-    newnode->type->symbolic->isTypedef = false;
-    newnode->type->symbolic->params = typeParams;
-    newnode->type->symbolic->name = newnode->name;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->name = assign_strptr( name );
+	newnode->type = new TypeData( TypeData::Symbolic );
+	newnode->type->symbolic->isTypedef = false;
+	newnode->type->symbolic->params = typeParams;
+	newnode->type->symbolic->name = newnode->name;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newPointer( DeclarationNode *qualifiers ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Pointer );
-    return newnode->addQualifiers( qualifiers );
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Pointer );
+	return newnode->addQualifiers( qualifiers );
 }
 
 DeclarationNode *DeclarationNode::newArray( ExpressionNode *size, DeclarationNode *qualifiers, bool isStatic ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Array );
-    newnode->type->array->dimension = size;
-    newnode->type->array->isStatic = isStatic;
-    newnode->type->array->isVarLen = false;
-    return newnode->addQualifiers( qualifiers );
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Array );
+	newnode->type->array->dimension = size;
+	newnode->type->array->isStatic = isStatic;
+	newnode->type->array->isVarLen = false;
+	return newnode->addQualifiers( qualifiers );
 }
 
 DeclarationNode *DeclarationNode::newVarArray( DeclarationNode *qualifiers ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Array );
-    newnode->type->array->dimension = 0;
-    newnode->type->array->isStatic = false;
-    newnode->type->array->isVarLen = true;
-    return newnode->addQualifiers( qualifiers );
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Array );
+	newnode->type->array->dimension = 0;
+	newnode->type->array->isStatic = false;
+	newnode->type->array->isVarLen = true;
+	return newnode->addQualifiers( qualifiers );
 }
 
 DeclarationNode *DeclarationNode::newBitfield( ExpressionNode *size ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->bitfieldWidth = size;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->bitfieldWidth = size;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newTuple( DeclarationNode *members ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Tuple );
-    newnode->type->tuple->members = members;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Tuple );
+	newnode->type->tuple->members = members;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newTypeof( ExpressionNode *expr ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Typeof );
-    newnode->type->typeexpr->expr = expr;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Typeof );
+	newnode->type->typeexpr->expr = expr;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newAttr( std::string *name, ExpressionNode *expr ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Attr );
-    newnode->type->attr->name = assign_strptr( name );
-    newnode->type->attr->expr = expr;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Attr );
+	newnode->type->attr->name = assign_strptr( name );
+	newnode->type->attr->expr = expr;
+	return newnode;
 }
 
 DeclarationNode *DeclarationNode::newAttr( std::string *name, DeclarationNode *type ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = new TypeData( TypeData::Attr );
-    newnode->type->attr->name = assign_strptr( name );
-    newnode->type->attr->type = type;
-    return newnode;
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = new TypeData( TypeData::Attr );
+	newnode->type->attr->name = assign_strptr( name );
+	newnode->type->attr->type = type;
+	return newnode;
 }
 
 static void addQualifiersToType( TypeData *&src, TypeData *dst ) {
-    if ( src && dst ) {
-	if ( src->forall && dst->kind == TypeData::Function ) {
-	    if ( dst->forall ) {
-		dst->forall->appendList( src->forall );
-	    } else {
-		dst->forall = src->forall;
-	    }
-	    src->forall = 0;
-	}
-	if ( dst->base ) {
-	    addQualifiersToType( src, dst->base );
-	} else if ( dst->kind == TypeData::Function ) {
-	    dst->base = src;
-	    src = 0;
-	} else {
-	    dst->qualifiers.splice( dst->qualifiers.end(), src->qualifiers );
-	}
-    }
-}
-      
+	if ( src && dst ) {
+		if ( src->forall && dst->kind == TypeData::Function ) {
+			if ( dst->forall ) {
+				dst->forall->appendList( src->forall );
+			} else {
+				dst->forall = src->forall;
+			}
+			src->forall = 0;
+		}
+		if ( dst->base ) {
+			addQualifiersToType( src, dst->base );
+		} else if ( dst->kind == TypeData::Function ) {
+			dst->base = src;
+			src = 0;
+		} else {
+			dst->qualifiers.splice( dst->qualifiers.end(), src->qualifiers );
+		}
+	}
+}
+	  
 DeclarationNode *DeclarationNode::addQualifiers( DeclarationNode *q ) {
-    if ( q ) {
-	storageClasses.splice( storageClasses.end(), q->storageClasses );
-	if ( q->type ) {
-	    if ( ! type ) {
-		type = new TypeData;
-	    }
-	    addQualifiersToType( q->type, type );
-	    if ( q->type && q->type->forall ) {
-		if ( type->forall ) {
-		    type->forall->appendList( q->type->forall );
+	if ( q ) {
+		storageClasses.splice( storageClasses.end(), q->storageClasses );
+		if ( q->type ) {
+			if ( ! type ) {
+				type = new TypeData;
+			}
+			addQualifiersToType( q->type, type );
+			if ( q->type && q->type->forall ) {
+				if ( type->forall ) {
+					type->forall->appendList( q->type->forall );
+				} else {
+					type->forall = q->type->forall;
+				}
+				q->type->forall = 0;
+			}
+		}
+	}
+	delete q;
+	return this;
+}
+
+DeclarationNode *DeclarationNode::copyStorageClasses( DeclarationNode *q ) {
+	storageClasses = q->storageClasses;
+	return this;
+}
+
+static void addTypeToType( TypeData *&src, TypeData *&dst ) {
+	if ( src && dst ) {
+		if ( src->forall && dst->kind == TypeData::Function ) {
+			if ( dst->forall ) {
+				dst->forall->appendList( src->forall );
+			} else {
+				dst->forall = src->forall;
+			}
+			src->forall = 0;
+		}
+		if ( dst->base ) {
+			addTypeToType( src, dst->base );
 		} else {
-		    type->forall = q->type->forall;
-		}
-		q->type->forall = 0;
-	    }
-	}
-    }
-    delete q;
-    return this;
-}
-
-DeclarationNode *DeclarationNode::copyStorageClasses( DeclarationNode *q ) {
-    storageClasses = q->storageClasses;
-    return this;
-}
-
-static void addTypeToType( TypeData *&src, TypeData *&dst ) {
-    if ( src && dst ) {
-	if ( src->forall && dst->kind == TypeData::Function ) {
-	    if ( dst->forall ) {
-		dst->forall->appendList( src->forall );
-	    } else {
-		dst->forall = src->forall;
-	    }
-	    src->forall = 0;
-	}
-	if ( dst->base ) {
-	    addTypeToType( src, dst->base );
-	} else {
-	    switch ( dst->kind ) {
-	      case TypeData::Unknown:
-		src->qualifiers.splice( src->qualifiers.end(), dst->qualifiers );
-		dst = src;
-		src = 0;
+			switch ( dst->kind ) {
+			  case TypeData::Unknown:
+				src->qualifiers.splice( src->qualifiers.end(), dst->qualifiers );
+				dst = src;
+				src = 0;
+				break;
+
+			  case TypeData::Basic:
+				dst->qualifiers.splice( dst->qualifiers.end(), src->qualifiers );
+				if ( src->kind != TypeData::Unknown ) {
+					assert( src->kind == TypeData::Basic );
+					dst->basic->modifiers.splice( dst->basic->modifiers.end(), src->basic->modifiers );
+					dst->basic->typeSpec.splice( dst->basic->typeSpec.end(), src->basic->typeSpec );
+				}
+				break;
+
+			  default:
+				switch ( src->kind ) {
+				  case TypeData::Aggregate:
+				  case TypeData::Enum:
+					dst->base = new TypeData( TypeData::AggregateInst );
+					dst->base->aggInst->aggregate = src;
+					if ( src->kind == TypeData::Aggregate ) {
+						dst->base->aggInst->params = maybeClone( src->aggregate->actuals );
+					}
+					dst->base->qualifiers.splice( dst->base->qualifiers.end(), src->qualifiers );
+					src = 0;
+					break;
+
+				  default:
+					if ( dst->forall ) {
+						dst->forall->appendList( src->forall );
+					} else {
+						dst->forall = src->forall;
+					}
+					src->forall = 0;
+					dst->base = src;
+					src = 0;
+				}
+			}
+		}
+	}
+}
+
+DeclarationNode *DeclarationNode::addType( DeclarationNode *o ) {
+	if ( o ) {
+		storageClasses.splice( storageClasses.end(), o->storageClasses );
+		if ( o->type ) {
+			if ( ! type ) {
+				if ( o->type->kind == TypeData::Aggregate || o->type->kind == TypeData::Enum ) {
+					type = new TypeData( TypeData::AggregateInst );
+					type->aggInst->aggregate = o->type;
+					if ( o->type->kind == TypeData::Aggregate ) {
+						type->aggInst->params = maybeClone( o->type->aggregate->actuals );
+					}
+					type->qualifiers.splice( type->qualifiers.end(), o->type->qualifiers );
+				} else {
+					type = o->type;
+				}
+				o->type = 0;
+			} else {
+				addTypeToType( o->type, type );
+			}
+		}
+		if ( o->bitfieldWidth ) {
+			bitfieldWidth = o->bitfieldWidth;
+		}
+	}
+	delete o;
+	return this;
+}
+
+DeclarationNode *DeclarationNode::addTypedef() {
+	TypeData *newtype = new TypeData( TypeData::Symbolic );
+	newtype->symbolic->params = 0;
+	newtype->symbolic->isTypedef = true;
+	newtype->symbolic->name = name;
+	newtype->base = type;
+	type = newtype;
+	return this;
+}
+
+DeclarationNode *DeclarationNode::addAssertions( DeclarationNode* assertions ) {
+	assert( type );
+	switch ( type->kind ) {
+	  case TypeData::Symbolic:
+		if ( type->symbolic->assertions ) {
+			type->symbolic->assertions->appendList( assertions );
+		} else {
+			type->symbolic->assertions = assertions;
+		}
 		break;
-
-	      case TypeData::Basic:
-		dst->qualifiers.splice( dst->qualifiers.end(), src->qualifiers );
-		if ( src->kind != TypeData::Unknown ) {
-		    assert( src->kind == TypeData::Basic );
-		    dst->basic->modifiers.splice( dst->basic->modifiers.end(), src->basic->modifiers );
-		    dst->basic->typeSpec.splice( dst->basic->typeSpec.end(), src->basic->typeSpec );
+	
+	  case TypeData::Variable:
+		if ( type->variable->assertions ) {
+			type->variable->assertions->appendList( assertions );
+		} else {
+			type->variable->assertions = assertions;
 		}
 		break;
-
-	      default:
-		switch ( src->kind ) {
-		  case TypeData::Aggregate:
-		  case TypeData::Enum:
-		    dst->base = new TypeData( TypeData::AggregateInst );
-		    dst->base->aggInst->aggregate = src;
-		    if ( src->kind == TypeData::Aggregate ) {
-			dst->base->aggInst->params = maybeClone( src->aggregate->actuals );
-		    }
-		    dst->base->qualifiers.splice( dst->base->qualifiers.end(), src->qualifiers );
-		    src = 0;
-		    break;
-          
-		  default:
-		    if ( dst->forall ) {
-			dst->forall->appendList( src->forall );
-		    } else {
-			dst->forall = src->forall;
-		    }
-		    src->forall = 0;
-		    dst->base = src;
-		    src = 0;
-		}
-	    }
-	}
-    }
-}
-
-DeclarationNode *DeclarationNode::addType( DeclarationNode *o ) {
-    if ( o ) {
-	storageClasses.splice( storageClasses.end(), o->storageClasses );
-	if ( o->type ) {
-	    if ( ! type ) {
-		if ( o->type->kind == TypeData::Aggregate || o->type->kind == TypeData::Enum ) {
-		    type = new TypeData( TypeData::AggregateInst );
-		    type->aggInst->aggregate = o->type;
-		    if ( o->type->kind == TypeData::Aggregate ) {
-			type->aggInst->params = maybeClone( o->type->aggregate->actuals );
-		    }
-		    type->qualifiers.splice( type->qualifiers.end(), o->type->qualifiers );
-		} else {
-		    type = o->type;
-		}
-		o->type = 0;
-	    } else {
-		addTypeToType( o->type, type );
-	    }
-	}
-	if ( o->bitfieldWidth ) {
-	    bitfieldWidth = o->bitfieldWidth;
-	}
-    }
-    delete o;
-    return this;
-}
-
-DeclarationNode *DeclarationNode::addTypedef() {
-    TypeData *newtype = new TypeData( TypeData::Symbolic );
-    newtype->symbolic->params = 0;
-    newtype->symbolic->isTypedef = true;
-    newtype->symbolic->name = name;
-    newtype->base = type;
-    type = newtype;
-    return this;
-}
-
-DeclarationNode *DeclarationNode::addAssertions( DeclarationNode* assertions ) {
-    assert( type );
-    switch ( type->kind ) {
-      case TypeData::Symbolic:
-	if ( type->symbolic->assertions ) {
-	    type->symbolic->assertions->appendList( assertions );
-	} else {
-	    type->symbolic->assertions = assertions;
-	}
-	break;
-    
-      case TypeData::Variable:
-	if ( type->variable->assertions ) {
-	    type->variable->assertions->appendList( assertions );
-	} else {
-	    type->variable->assertions = assertions;
-	}
-	break;
-    
-      default:
-	assert( false );
-    }
-    
-    return this;
+	
+	  default:
+		assert( false );
+	}
+	
+	return this;
 }
 
 DeclarationNode *DeclarationNode::addName( std::string* newname ) {
-    name = assign_strptr( newname );
-    return this;
+	name = assign_strptr( newname );
+	return this;
 }
 
 DeclarationNode *DeclarationNode::addBitfield( ExpressionNode *size ) {
-    bitfieldWidth = size;
-    return this;
+	bitfieldWidth = size;
+	return this;
 }
 
 DeclarationNode *DeclarationNode::addVarArgs() {
-    assert( type );
-    hasEllipsis = true;
-    return this;
+	assert( type );
+	hasEllipsis = true;
+	return this;
 }
 
 DeclarationNode *DeclarationNode::addFunctionBody( StatementNode *body ) {
-    assert( type );
-    assert( type->kind == TypeData::Function );
-    assert( type->function->body == 0 );
-    type->function->body = body;
-    type->function->hasBody = true;
-    return this;
+	assert( type );
+	assert( type->kind == TypeData::Function );
+	assert( type->function->body == 0 );
+	type->function->body = body;
+	type->function->hasBody = true;
+	return this;
 }
 
 DeclarationNode *DeclarationNode::addOldDeclList( DeclarationNode *list ) {
-    assert( type );
-    assert( type->kind == TypeData::Function );
-    assert( type->function->oldDeclList == 0 );
-    type->function->oldDeclList = list;
-    return this;
+	assert( type );
+	assert( type->kind == TypeData::Function );
+	assert( type->function->oldDeclList == 0 );
+	type->function->oldDeclList = list;
+	return this;
 }
 
 static void
 setBase( TypeData *&type, TypeData *newType ) {
-    if ( type ) {
-	TypeData *prevBase = type;
-	TypeData *curBase = type->base;
-	while( curBase != 0 ) {
-	    prevBase = curBase;
-	    curBase = curBase->base;
-	}
-	prevBase->base = newType;
-    } else {
-	type = newType;
-    }
+	if ( type ) {
+		TypeData *prevBase = type;
+		TypeData *curBase = type->base;
+		while( curBase != 0 ) {
+			prevBase = curBase;
+			curBase = curBase->base;
+		}
+		prevBase->base = newType;
+	} else {
+		type = newType;
+	}
 }
 
 DeclarationNode *DeclarationNode::addPointer( DeclarationNode *p ) {
-    if ( p ) {
-	assert( p->type->kind == TypeData::Pointer );
-	setBase( type, p->type );
-	p->type = 0;
-	delete p;
-    }
-    return this;
+	if ( p ) {
+		assert( p->type->kind == TypeData::Pointer );
+		setBase( type, p->type );
+		p->type = 0;
+		delete p;
+	}
+	return this;
 }
 
 DeclarationNode *DeclarationNode::addArray( DeclarationNode *a ) {
-    if ( a ) {
-	assert( a->type->kind == TypeData::Array );
-	setBase( type, a->type );
-	a->type = 0;
-	delete a;
-    }
-    return this;
+	if ( a ) {
+		assert( a->type->kind == TypeData::Array );
+		setBase( type, a->type );
+		a->type = 0;
+		delete a;
+	}
+	return this;
 }
 
 DeclarationNode *DeclarationNode::addNewPointer( DeclarationNode *p ) {
-    if ( p ) {
-	assert( p->type->kind == TypeData::Pointer );
+	if ( p ) {
+		assert( p->type->kind == TypeData::Pointer );
+		if ( type ) {
+			switch ( type->kind ) {
+			  case TypeData::Aggregate:
+			  case TypeData::Enum:
+				p->type->base = new TypeData( TypeData::AggregateInst );
+				p->type->base->aggInst->aggregate = type;
+				if ( type->kind == TypeData::Aggregate ) {
+					p->type->base->aggInst->params = maybeClone( type->aggregate->actuals );
+				}
+				p->type->base->qualifiers.splice( p->type->base->qualifiers.end(), type->qualifiers );
+				break;
+
+			  default:
+				p->type->base = type;
+			}
+			type = 0;
+		}
+		delete this;
+		return p;
+	} else {
+		return this;
+	}
+}
+
+static TypeData *findLast( TypeData *a ) {
+	assert( a );
+	TypeData *cur = a;
+	while( cur->base ) {
+		cur = cur->base;
+	}
+	return cur;
+}
+
+DeclarationNode *DeclarationNode::addNewArray( DeclarationNode *a ) {
+	if ( a ) {
+		assert( a->type->kind == TypeData::Array );
+		TypeData *lastArray = findLast( a->type );
+		if ( type ) {  
+			switch ( type->kind ) {
+			  case TypeData::Aggregate:
+			  case TypeData::Enum:
+				lastArray->base = new TypeData( TypeData::AggregateInst );
+				lastArray->base->aggInst->aggregate = type;
+				if ( type->kind == TypeData::Aggregate ) {
+					lastArray->base->aggInst->params = maybeClone( type->aggregate->actuals );
+				}
+				lastArray->base->qualifiers.splice( lastArray->base->qualifiers.end(), type->qualifiers );
+				break;
+			  default:
+				lastArray->base = type;
+			}
+			type = 0;
+		}
+		delete this;
+		return a;
+	} else {
+		return this;
+	}
+}
+
+DeclarationNode *DeclarationNode::addParamList( DeclarationNode *params ) {
+	TypeData *ftype = new TypeData( TypeData::Function );
+	ftype->function->params = params;
+	setBase( type, ftype );
+	return this;
+}
+
+static TypeData *addIdListToType( TypeData *type, DeclarationNode *ids ) {
 	if ( type ) {
-	    switch ( type->kind ) {
-	      case TypeData::Aggregate:
-	      case TypeData::Enum:
-		p->type->base = new TypeData( TypeData::AggregateInst );
-		p->type->base->aggInst->aggregate = type;
-		if ( type->kind == TypeData::Aggregate ) {
-		    p->type->base->aggInst->params = maybeClone( type->aggregate->actuals );
-		}
-		p->type->base->qualifiers.splice( p->type->base->qualifiers.end(), type->qualifiers );
-		break;
-        
-	      default:
-		p->type->base = type;
-	    }
-	    type = 0;
-	}
-	delete this;
-	return p;
-    } else {
-	return this;
-    }
-}
-
-static TypeData *findLast( TypeData *a ) {
-    assert( a );
-    TypeData *cur = a;
-    while( cur->base ) {
-	cur = cur->base;
-    }
-    return cur;
-}
-
-DeclarationNode *DeclarationNode::addNewArray( DeclarationNode *a ) {
-    if ( a ) {
-	assert( a->type->kind == TypeData::Array );
-	TypeData *lastArray = findLast( a->type );
-	if ( type ) {  
-	    switch ( type->kind ) {
-	      case TypeData::Aggregate:
-	      case TypeData::Enum:
-		lastArray->base = new TypeData( TypeData::AggregateInst );
-		lastArray->base->aggInst->aggregate = type;
-		if ( type->kind == TypeData::Aggregate ) {
-		    lastArray->base->aggInst->params = maybeClone( type->aggregate->actuals );
-		}
-		lastArray->base->qualifiers.splice( lastArray->base->qualifiers.end(), type->qualifiers );
-		break;
-        
-	      default:
-		lastArray->base = type;
-	    }
-	    type = 0;
-	}
-	delete this;
-	return a;
-    } else {
-	return this;
-    }
-}
-
-DeclarationNode *DeclarationNode::addParamList( DeclarationNode *params ) {
-    TypeData *ftype = new TypeData( TypeData::Function );
-    ftype->function->params = params;
-    setBase( type, ftype );
-    return this;
-}
-
-static TypeData *addIdListToType( TypeData *type, DeclarationNode *ids ) {
-    if ( type ) {
-	if ( type->kind != TypeData::Function ) {
-	    type->base = addIdListToType( type->base, ids );
+		if ( type->kind != TypeData::Function ) {
+			type->base = addIdListToType( type->base, ids );
+		} else {
+			type->function->idList = ids;
+		}
+		return type;
 	} else {
-	    type->function->idList = ids;
-	}
-	return type;
-    } else {
-	TypeData *newtype = new TypeData( TypeData::Function );
-	newtype->function->idList = ids;
-	return newtype;
-    }
-}
-    
+		TypeData *newtype = new TypeData( TypeData::Function );
+		newtype->function->idList = ids;
+		return newtype;
+	}
+}
+	
 DeclarationNode *DeclarationNode::addIdList( DeclarationNode *ids ) {
-    type = addIdListToType( type, ids );
-    return this;
+	type = addIdListToType( type, ids );
+	return this;
 }
 
 DeclarationNode *DeclarationNode::addInitializer( InitializerNode *init ) {
-    //assert
-    initializer = init;
-    return this;
+	//assert
+	initializer = init;
+	return this;
 }
 
 DeclarationNode *DeclarationNode::cloneBaseType( string *newName ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    TypeData *srcType = type;
-    while( srcType->base ) {
-	srcType = srcType->base;
-    }
-    newnode->type = maybeClone( srcType );
-    if ( newnode->type->kind == TypeData::AggregateInst ) {
-	// don't duplicate members
-	if ( newnode->type->aggInst->aggregate->kind == TypeData::Enum ) {
-	    delete newnode->type->aggInst->aggregate->enumeration->constants;
-	    newnode->type->aggInst->aggregate->enumeration->constants = 0;
+	DeclarationNode *newnode = new DeclarationNode;
+	TypeData *srcType = type;
+	while( srcType->base ) {
+		srcType = srcType->base;
+	}
+	newnode->type = maybeClone( srcType );
+	if ( newnode->type->kind == TypeData::AggregateInst ) {
+		// don't duplicate members
+		if ( newnode->type->aggInst->aggregate->kind == TypeData::Enum ) {
+			delete newnode->type->aggInst->aggregate->enumeration->constants;
+			newnode->type->aggInst->aggregate->enumeration->constants = 0;
+		} else {
+			assert( newnode->type->aggInst->aggregate->kind == TypeData::Aggregate );
+			delete newnode->type->aggInst->aggregate->aggregate->members;
+			newnode->type->aggInst->aggregate->aggregate->members = 0;
+		}
+	}
+	newnode->type->forall = maybeClone( type->forall );
+	newnode->storageClasses = storageClasses;
+	newnode->name = assign_strptr( newName );
+	return newnode;
+}
+
+DeclarationNode *DeclarationNode::cloneBaseType( DeclarationNode *o ) {
+	if ( o ) {
+		o->storageClasses.insert( o->storageClasses.end(), storageClasses.begin(), storageClasses.end() );
+		if ( type ) {
+			TypeData *srcType = type;
+			while( srcType->base ) {
+				srcType = srcType->base;
+			}
+			TypeData *newType = srcType->clone();
+			if ( newType->kind == TypeData::AggregateInst ) {
+				// don't duplicate members
+				if ( newType->aggInst->aggregate->kind == TypeData::Enum ) {
+					delete newType->aggInst->aggregate->enumeration->constants;
+					newType->aggInst->aggregate->enumeration->constants = 0;
+				} else {
+					assert( newType->aggInst->aggregate->kind == TypeData::Aggregate );
+					delete newType->aggInst->aggregate->aggregate->members;
+					newType->aggInst->aggregate->aggregate->members = 0;
+				}
+			}
+			newType->forall = maybeClone( type->forall );
+			if ( ! o->type ) {
+				o->type = newType;
+			} else {
+				addTypeToType( newType, o->type );
+				delete newType;
+			}
+		}
+	}
+	return o;
+}
+
+DeclarationNode *DeclarationNode::cloneType( string *newName ) {
+	DeclarationNode *newnode = new DeclarationNode;
+	newnode->type = maybeClone( type );
+	newnode->storageClasses = storageClasses;
+	newnode->name = assign_strptr( newName );
+	return newnode;
+}
+
+DeclarationNode *DeclarationNode::cloneType( DeclarationNode *o ) {
+	if ( o ) {
+		o->storageClasses.insert( o->storageClasses.end(), storageClasses.begin(), storageClasses.end() );
+		if ( type ) {
+			TypeData *newType = type->clone();
+			if ( ! o->type ) {
+				o->type = newType;
+			} else {
+				addTypeToType( newType, o->type );
+				delete newType;
+			}
+		}
+	}
+	return o;
+}
+
+DeclarationNode *DeclarationNode::appendList( DeclarationNode *node ) {
+	if ( node != 0 ) {
+		set_link( node );
+	}
+	return this;
+}
+
+DeclarationNode *DeclarationNode::extractAggregate() const {
+	if ( type ) {
+		TypeData *ret = type->extractAggregate();
+		if ( ret ) {
+			DeclarationNode *newnode = new DeclarationNode;
+			newnode->type = ret;
+			return newnode;
+		} else {
+			return 0;
+		}
 	} else {
-	    assert( newnode->type->aggInst->aggregate->kind == TypeData::Aggregate );
-	    delete newnode->type->aggInst->aggregate->aggregate->members;
-	    newnode->type->aggInst->aggregate->aggregate->members = 0;
-	}
-    }
-    newnode->type->forall = maybeClone( type->forall );
-    newnode->storageClasses = storageClasses;
-    newnode->name = assign_strptr( newName );
-    return newnode;
-}
-
-DeclarationNode *DeclarationNode::cloneBaseType( DeclarationNode *o ) {
-    if ( o ) {
-	o->storageClasses.insert( o->storageClasses.end(), storageClasses.begin(), storageClasses.end() );
-	if ( type ) {
-	    TypeData *srcType = type;
-	    while( srcType->base ) {
-		srcType = srcType->base;
-	    }
-	    TypeData *newType = srcType->clone();
-	    if ( newType->kind == TypeData::AggregateInst ) {
-		// don't duplicate members
-		if ( newType->aggInst->aggregate->kind == TypeData::Enum ) {
-		    delete newType->aggInst->aggregate->enumeration->constants;
-		    newType->aggInst->aggregate->enumeration->constants = 0;
-		} else {
-		    assert( newType->aggInst->aggregate->kind == TypeData::Aggregate );
-		    delete newType->aggInst->aggregate->aggregate->members;
-		    newType->aggInst->aggregate->aggregate->members = 0;
-		}
-	    }
-	    newType->forall = maybeClone( type->forall );
-	    if ( ! o->type ) {
-		o->type = newType;
-	    } else {
-		addTypeToType( newType, o->type );
-		delete newType;
-	    }
-	}
-    }
-    return o;
-}
-
-DeclarationNode *DeclarationNode::cloneType( string *newName ) {
-    DeclarationNode *newnode = new DeclarationNode;
-    newnode->type = maybeClone( type );
-    newnode->storageClasses = storageClasses;
-    newnode->name = assign_strptr( newName );
-    return newnode;
-}
-
-DeclarationNode *DeclarationNode::cloneType( DeclarationNode *o ) {
-    if ( o ) {
-	o->storageClasses.insert( o->storageClasses.end(), storageClasses.begin(), storageClasses.end() );
-	if ( type ) {
-	    TypeData *newType = type->clone();
-	    if ( ! o->type ) {
-		o->type = newType;
-	    } else {
-		addTypeToType( newType, o->type );
-		delete newType;
-	    }
-	}
-    }
-    return o;
-}
-
-DeclarationNode *DeclarationNode::appendList( DeclarationNode *node ) {
-    if ( node != 0 ) {
-	set_link( node );
-    }
-    return this;
-}
-
-DeclarationNode *DeclarationNode::extractAggregate() const {
-    if ( type ) {
-	TypeData *ret = type->extractAggregate();
-	if ( ret ) {
-	    DeclarationNode *newnode = new DeclarationNode;
-	    newnode->type = ret;
-	    return newnode;
-	} else {
-	    return 0;
-	}
-    } else {
-	return 0;
-    }
+		return 0;
+	}
 }
 
 void buildList( const DeclarationNode *firstNode, std::list< Declaration* > &outputList ) {
-    SemanticError errors;
-    std::back_insert_iterator< std::list< Declaration* > > out( outputList );
-    const DeclarationNode *cur = firstNode;
-    while( cur ) {
-	try {
-	    if ( DeclarationNode *extr = cur->extractAggregate() ) {
-		// handle the case where a structure declaration is contained within an object or type
-		// declaration
-		Declaration *decl = extr->build();
-		if ( decl ) {
-		   *out++ = decl;
-		}
-	    }
-	    Declaration *decl = cur->build();
-	    if ( decl ) {
-		*out++ = decl;
-	    }
-	} catch( SemanticError &e ) {
-	    errors.append( e );
-	}
-	cur = dynamic_cast< DeclarationNode* >( cur->get_link() );
-    }
-    if ( ! errors.isEmpty() ) {
-	throw errors;
-    }
+	SemanticError errors;
+	std::back_insert_iterator< std::list< Declaration* > > out( outputList );
+	const DeclarationNode *cur = firstNode;
+	while( cur ) {
+		try {
+			if ( DeclarationNode *extr = cur->extractAggregate() ) {
+				// handle the case where a structure declaration is contained within an object or type declaration
+				Declaration *decl = extr->build();
+				if ( decl ) {
+					*out++ = decl;
+				}
+			}
+			Declaration *decl = cur->build();
+			if ( decl ) {
+				*out++ = decl;
+			}
+		} catch( SemanticError &e ) {
+			errors.append( e );
+		}
+		cur = dynamic_cast< DeclarationNode* >( cur->get_link() );
+	}
+	if ( ! errors.isEmpty() ) {
+		throw errors;
+	}
 }
 
 void buildList( const DeclarationNode *firstNode, std::list< DeclarationWithType* > &outputList ) {
-    SemanticError errors;
-    std::back_insert_iterator< std::list< DeclarationWithType* > > out( outputList );
-    const DeclarationNode *cur = firstNode;
-    while( cur ) {
-	try {
+	SemanticError errors;
+	std::back_insert_iterator< std::list< DeclarationWithType* > > out( outputList );
+	const DeclarationNode *cur = firstNode;
+	while( cur ) {
+		try {
 ///       if ( DeclarationNode *extr = cur->extractAggregate() ) {
 /// 	// handle the case where a structure declaration is contained within an object or type
@@ -787,131 +800,137 @@
 /// 	}
 ///       }
-	    Declaration *decl = cur->build();
-	    if ( decl ) {
-		if ( DeclarationWithType *dwt = dynamic_cast< DeclarationWithType* >( decl ) ) {
-		   *out++ = dwt;
-		} else if ( StructDecl *agg = dynamic_cast< StructDecl* >( decl ) ) {
-		    StructInstType *inst = new StructInstType( Type::Qualifiers(), agg->get_name() );
-		    *out++ = new ObjectDecl( "", Declaration::NoStorageClass, linkage, 0, inst, 0 );
-		    delete agg;
-		} else if ( UnionDecl *agg = dynamic_cast< UnionDecl* >( decl ) ) {
-		    UnionInstType *inst = new UnionInstType( Type::Qualifiers(), agg->get_name() );
-		    *out++ = new ObjectDecl( "", Declaration::NoStorageClass, linkage, 0, inst, 0 );
-		}
-	    }
-	} catch( SemanticError &e ) {
-	    errors.append( e );
-	}
-	cur = dynamic_cast< DeclarationNode* >( cur->get_link() );
-    }
-    if ( ! errors.isEmpty() ) {
-	throw errors;
-    }
+			Declaration *decl = cur->build();
+			if ( decl ) {
+				if ( DeclarationWithType *dwt = dynamic_cast< DeclarationWithType* >( decl ) ) {
+					*out++ = dwt;
+				} else if ( StructDecl *agg = dynamic_cast< StructDecl* >( decl ) ) {
+					StructInstType *inst = new StructInstType( Type::Qualifiers(), agg->get_name() );
+					*out++ = new ObjectDecl( "", Declaration::NoStorageClass, linkage, 0, inst, 0 );
+					delete agg;
+				} else if ( UnionDecl *agg = dynamic_cast< UnionDecl* >( decl ) ) {
+					UnionInstType *inst = new UnionInstType( Type::Qualifiers(), agg->get_name() );
+					*out++ = new ObjectDecl( "", Declaration::NoStorageClass, linkage, 0, inst, 0 );
+				}
+			}
+		} catch( SemanticError &e ) {
+			errors.append( e );
+		}
+		cur = dynamic_cast< DeclarationNode* >( cur->get_link() );
+	}
+	if ( ! errors.isEmpty() ) {
+		throw errors;
+	}
 }
 
 void buildTypeList( const DeclarationNode *firstNode, std::list< Type* > &outputList ) {
-    SemanticError errors;
-    std::back_insert_iterator< std::list< Type* > > out( outputList );
-    const DeclarationNode *cur = firstNode;
-    while( cur ) {
-	try {
-	   *out++ = cur->buildType();
-	} catch( SemanticError &e ) {
-	    errors.append( e );
-	}
-	cur = dynamic_cast< DeclarationNode* >( cur->get_link() );
-    }
-    if ( ! errors.isEmpty() ) {
-	throw errors;
-    }
+	SemanticError errors;
+	std::back_insert_iterator< std::list< Type* > > out( outputList );
+	const DeclarationNode *cur = firstNode;
+	while( cur ) {
+		try {
+			*out++ = cur->buildType();
+		} catch( SemanticError &e ) {
+			errors.append( e );
+		}
+		cur = dynamic_cast< DeclarationNode* >( cur->get_link() );
+	}
+	if ( ! errors.isEmpty() ) {
+		throw errors;
+	}
 }
 
 Declaration *DeclarationNode::build() const {
 
-    if ( ! type ) {
-	if ( buildInline() ) {
-	    throw SemanticError( "invalid inline specification in declaration of ", this );
+	if ( ! type ) {
+		if ( buildInline() ) {
+			throw SemanticError( "invalid inline specification in declaration of ", this );
+		} else {
+			return new ObjectDecl( name, buildStorageClass(), linkage, maybeBuild< Expression >( bitfieldWidth ), 0, maybeBuild< Initializer >( initializer ) );
+		}
 	} else {
-	    return new ObjectDecl( name, buildStorageClass(), linkage, maybeBuild< Expression >( bitfieldWidth ), 0, maybeBuild< Initializer >( initializer ) );
-	}
-    } else {
-	Declaration *newDecl = type->buildDecl( name, buildStorageClass(), maybeBuild< Expression >( bitfieldWidth ), buildInline(), linkage, maybeBuild< Initializer >(initializer) );
-	return newDecl;
-    }
-    // we should never get here
-    assert( false );
-    return 0;
+		Declaration *newDecl = type->buildDecl( name, buildStorageClass(), maybeBuild< Expression >( bitfieldWidth ), buildInline(), linkage, maybeBuild< Initializer >(initializer) );
+		return newDecl;
+	}
+	// we should never get here
+	assert( false );
+	return 0;
 }
 
 Type *DeclarationNode::buildType() const {
-    assert( type );
+	assert( type );
   
-    switch ( type->kind ) {
-      case TypeData::Enum:
-	return new EnumInstType( type->buildQualifiers(), type->enumeration->name );
-      case TypeData::Aggregate: {
-	  ReferenceToType *ret;
-	  switch ( type->aggregate->kind ) {
-	    case DeclarationNode::Struct:
-	      ret = new StructInstType( type->buildQualifiers(), type->aggregate->name );
-	      break;
-	    case DeclarationNode::Union:
-	      ret = new UnionInstType( type->buildQualifiers(), type->aggregate->name );
-	      break;
-	    case DeclarationNode::Context:
-	      ret = new ContextInstType( type->buildQualifiers(), type->aggregate->name );
-	      break;
-	    default:
-	      assert( false );
-	  } // switch
-	  buildList( type->aggregate->actuals, ret->get_parameters() );
-	  return ret;
-      }
-      case TypeData::Symbolic: {
-	  TypeInstType *ret = new TypeInstType( type->buildQualifiers(), type->symbolic->name, false );
-	  buildList( type->symbolic->actuals, ret->get_parameters() );
-	  return ret;
-      }
-      default:
-	return type->build();
-    } // switch
+	switch ( type->kind ) {
+	  case TypeData::Enum:
+		return new EnumInstType( type->buildQualifiers(), type->enumeration->name );
+	  case TypeData::Aggregate: {
+		  ReferenceToType *ret;
+		  switch ( type->aggregate->kind ) {
+			case DeclarationNode::Struct:
+			  ret = new StructInstType( type->buildQualifiers(), type->aggregate->name );
+			  break;
+			case DeclarationNode::Union:
+			  ret = new UnionInstType( type->buildQualifiers(), type->aggregate->name );
+			  break;
+			case DeclarationNode::Context:
+			  ret = new ContextInstType( type->buildQualifiers(), type->aggregate->name );
+			  break;
+			default:
+			  assert( false );
+		  } // switch
+		  buildList( type->aggregate->actuals, ret->get_parameters() );
+		  return ret;
+	  }
+	  case TypeData::Symbolic: {
+		  TypeInstType *ret = new TypeInstType( type->buildQualifiers(), type->symbolic->name, false );
+		  buildList( type->symbolic->actuals, ret->get_parameters() );
+		  return ret;
+	  }
+	  default:
+		return type->build();
+	} // switch
 }
 
 Declaration::StorageClass DeclarationNode::buildStorageClass() const {
-    static const Declaration::StorageClass scMap[] = {  
-	Declaration::Extern,
-	Declaration::Static,
-	Declaration::Auto,
-	Declaration::Register,
-	Declaration::Inline,
-	Declaration::Fortran
-    };  
+	static const Declaration::StorageClass scMap[] = {  
+		Declaration::Extern,
+		Declaration::Static,
+		Declaration::Auto,
+		Declaration::Register,
+		Declaration::Inline,
+		Declaration::Fortran
+	};  
   
-    Declaration::StorageClass ret = Declaration::NoStorageClass;
-    for ( std::list< StorageClass >::const_iterator i = storageClasses.begin(); i != storageClasses.end(); ++i ) {
-	assert( unsigned( *i ) < sizeof( scMap ) / sizeof( scMap[0] ) );
-	if ( *i == Inline ) continue;
-	if ( ret == Declaration::NoStorageClass ) {
-	    ret = scMap[ *i ];
+	Declaration::StorageClass ret = Declaration::NoStorageClass;
+	for ( std::list< StorageClass >::const_iterator i = storageClasses.begin(); i != storageClasses.end(); ++i ) {
+		assert( unsigned( *i ) < sizeof( scMap ) / sizeof( scMap[0] ) );
+		if ( *i == Inline ) continue;
+		if ( ret == Declaration::NoStorageClass ) {
+			ret = scMap[ *i ];
+		} else {
+			throw SemanticError( "invalid combination of storage classes in declaration of ", this );
+		}
+	}
+	return ret;
+}
+
+bool DeclarationNode::buildInline() const {
+	std::list< StorageClass >::const_iterator first = std::find( storageClasses.begin(), storageClasses.end(), Inline );
+	if ( first == storageClasses.end() ) {
+		return false;
 	} else {
-	    throw SemanticError( "invalid combination of storage classes in declaration of ", this );
-	}
-    }
-    return ret;
-}
-
-bool DeclarationNode::buildInline() const {
-    std::list< StorageClass >::const_iterator first = std::find( storageClasses.begin(), storageClasses.end(), Inline );
-    if ( first == storageClasses.end() ) {
+		std::list< StorageClass >::const_iterator next = std::find( ++first, storageClasses.end(), Inline );
+		if ( next == storageClasses.end() ) {
+			return true;
+		} else {
+			throw SemanticError( "duplicate inline specification in declaration of ", this );
+		}
+	}
+	// we should never get here
 	return false;
-    } else {
-	std::list< StorageClass >::const_iterator next = std::find( ++first, storageClasses.end(), Inline );
-	if ( next == storageClasses.end() ) {
-	    return true;
-	} else {
-	    throw SemanticError( "duplicate inline specification in declaration of ", this );
-	}
-    }
-    // we should never get here
-    return false;
-}
+}
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/ExpressionNode.cc
===================================================================
--- translator/Parser/ExpressionNode.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/ExpressionNode.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// ExpressionNode.cc -- 
+// 
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 13:17:07 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 13:19:35 2015
+// Update Count     : 2
+// 
+
 #include <cassert>
 #include <cctype>
@@ -17,31 +32,31 @@
 
 ExpressionNode::ExpressionNode( string *name_) : ParseNode( *name_ ), argName( 0 ) {
-    delete name_;
+	delete name_;
 }
 
 ExpressionNode::ExpressionNode( const ExpressionNode &other ) : ParseNode( other.name ) {
-    if ( other.argName ) {
-	argName = other.argName->clone();
-    } else {
-	argName = 0;
-    } // if
+	if ( other.argName ) {
+		argName = other.argName->clone();
+	} else {
+		argName = 0;
+	} // if
 }
 
 ExpressionNode * ExpressionNode::set_asArgName( std::string *aName ) {
-    argName = new VarRefNode( aName );
-    return this;
+	argName = new VarRefNode( aName );
+	return this;
 }
 
 ExpressionNode * ExpressionNode::set_asArgName( ExpressionNode *aDesignator ) {
-    argName = aDesignator;
-    return this;
+	argName = aDesignator;
+	return this;
 }
 
 void ExpressionNode::printDesignation( std::ostream &os, int indent ) const {
-    if ( argName ) {
-	os << string(' ', indent ) << "(designated by:  ";
-	argName->printOneLine( os, indent );
-	os << ")" << std::endl;
-    } // if
+	if ( argName ) {
+		os << string(' ', indent ) << "(designated by:  ";
+		argName->printOneLine( os, indent );
+		os << ")" << std::endl;
+	} // if
 }
 
@@ -49,23 +64,23 @@
 
 NullExprNode *NullExprNode::clone() const {
-    return new NullExprNode();
+	return new NullExprNode();
 }
 
 void NullExprNode::print( std::ostream & os, int indent ) const {
-    printDesignation( os );
-    os << "null expression";
+	printDesignation( os );
+	os << "null expression";
 }
 
 void NullExprNode::printOneLine( std::ostream & os, int indent ) const {
-    printDesignation( os );
-    os << "null";
+	printDesignation( os );
+	os << "null";
 }
 
 Expression *NullExprNode::build() const {
-    return 0;
+	return 0;
 }
 
 CommaExprNode *ExpressionNode::add_to_list( ExpressionNode *exp ){
-    return new CommaExprNode( this, exp );
+	return new CommaExprNode( this, exp );
 }
 
@@ -77,144 +92,144 @@
 
 ConstantNode::ConstantNode( Type t, string *inVal ) : type( t ), sign( true ), longs(0), size(0) {
-    if ( inVal ) {
-	value = *inVal;
-	delete inVal;
-    } else {
-	value = "";
-    } // if
-
-    classify( value );
-}
-
-ConstantNode::ConstantNode( const ConstantNode &other )
-    : ExpressionNode( other ), type( other.type ), value( other.value ), sign( other.sign ), base( other.base ), longs( other.longs ), size( other.size ) {
+	if ( inVal ) {
+		value = *inVal;
+		delete inVal;
+	} else {
+		value = "";
+	} // if
+
+	classify( value );
+}
+
+ConstantNode::ConstantNode( const ConstantNode &other ) : ExpressionNode( other ), type( other.type ), value( other.value ), sign( other.sign ),
+														  base( other.base ), longs( other.longs ), size( other.size ) {
 }
 
 // for some reason, std::tolower doesn't work as an argument to std::transform in g++ 3.1
 inline char tolower_hack( char c ) {
-    return std::tolower( c );
+	return std::tolower( c );
 }
 
 void ConstantNode::classify( std::string &str ){
-    switch ( type ){
-      case Integer:
-      case Float:
-	{
-	    std::string sfx("");
-	    char c;
-	    int i = str.length() - 1;
-
-	    while ( i >= 0 && !isxdigit( c = str.at( i--)) )
-		sfx += c;
-
-	    value = str.substr( 0, i + 2 );
-
-	    // get rid of underscores
-	    value.erase( remove( value.begin(), value.end(), '_'), value.end());
-
-	    std::transform( sfx.begin(), sfx.end(), sfx.begin(), tolower_hack );
-
-	    if ( sfx.find("ll") != string::npos ){
-		longs = 2;
-	    } else if ( sfx.find("l") != string::npos ){
-		longs = 1;
-	    } // if
-
-	    assert(( longs >= 0) && ( longs <= 2));
-
-	    if ( sfx.find("u") != string::npos )
-		sign = false;
-
-	    break;
+	switch ( type ){
+	  case Integer:
+	  case Float:
+		{
+			std::string sfx("");
+			char c;
+			int i = str.length() - 1;
+
+			while ( i >= 0 && !isxdigit( c = str.at( i--)) )
+				sfx += c;
+
+			value = str.substr( 0, i + 2 );
+
+			// get rid of underscores
+			value.erase( remove( value.begin(), value.end(), '_'), value.end());
+
+			std::transform( sfx.begin(), sfx.end(), sfx.begin(), tolower_hack );
+
+			if ( sfx.find("ll") != string::npos ){
+				longs = 2;
+			} else if ( sfx.find("l") != string::npos ){
+				longs = 1;
+			} // if
+
+			assert(( longs >= 0) && ( longs <= 2));
+
+			if ( sfx.find("u") != string::npos )
+				sign = false;
+
+			break;
+		}
+	  case Character:
+		{
+			// remove underscores from hex and oct escapes
+			if ( str.substr(1,2) == "\\x")
+				value.erase( remove( value.begin(), value.end(), '_'), value.end());
+
+			break;
+		}
+	  default:
+		// shouldn't be here
+		;
 	}
-      case Character:
-	{
-	    // remove underscores from hex and oct escapes
-	    if ( str.substr(1,2) == "\\x")
-		value.erase( remove( value.begin(), value.end(), '_'), value.end());
-
-	    break;
+}
+
+ConstantNode::Type ConstantNode::get_type( void ) const {
+	return type;
+}
+
+ConstantNode *ConstantNode::append( std::string *newValue ) {
+	if ( newValue ) {
+		if ( type == String ){
+			std::string temp = *newValue;
+			value.resize( value.size() - 1 );
+			value += newValue->substr(1, newValue->size());
+		} else
+			value += *newValue;
+
+		delete newValue;
+	} // if
+	return this;
+}
+
+void ConstantNode::printOneLine( std::ostream &os, int indent ) const {
+	os << string( indent, ' ');
+	printDesignation( os );
+
+	switch ( type ) {
+		/* integers */
+	  case Integer:
+		os << value ;
+		break;
+	  case Float:
+		os << value ;
+		break;
+
+	  case Character:
+		os << "'" << value << "'";
+		break;
+
+	  case String:
+		os << '"' << value << '"';
+		break;
 	}
-      default:
-	// shouldn't be here
-	;
-    }
-}
-
-ConstantNode::Type ConstantNode::get_type( void ) const {
-    return type;
-}
-
-ConstantNode *ConstantNode::append( std::string *newValue ) {
-    if ( newValue ) {
-	if ( type == String ){
-	    std::string temp = *newValue;
-	    value.resize( value.size() - 1 );
-	    value += newValue->substr(1, newValue->size());
-	} else
-	    value += *newValue;
-
-	delete newValue;
-    } // if
-    return this;
-}
-
-void ConstantNode::printOneLine( std::ostream &os, int indent ) const {
-    os << string( indent, ' ');
-    printDesignation( os );
-
-    switch ( type ) {
-	/* integers */
-      case Integer:
-	os << value ;
-	break;
-      case Float:
-	os << value ;
-	break;
-
-      case Character:
-	os << "'" << value << "'";
-	break;
-
-      case String:
-	os << '"' << value << '"';
-	break;
-    }
-
-    os << ' ';
+
+	os << ' ';
 }
 
 void ConstantNode::print( std::ostream &os, int indent ) const {
-    printOneLine( os, indent );
-    os << endl;
+	printOneLine( os, indent );
+	os << endl;
 }
 
 Expression *ConstantNode::build() const {
-    ::Type::Qualifiers q;
-    BasicType *bt;
-
-    switch ( get_type()){
-      case Integer:
-	/* Cfr. standard 6.4.4.1 */
-	//bt.set_kind( BasicType::SignedInt );
-	bt = new BasicType( q, BasicType::SignedInt );
-	break;
-      case Float:
-	bt = new BasicType( q, BasicType::Float );
-	break;
-      case Character:
-	bt = new BasicType( q, BasicType::Char );
-	break;
-      case String:
-	// string should probably be a primitive type
-	ArrayType *at;
-	std::string value = get_value();
-	at = new ArrayType( q, new BasicType( q, BasicType::Char ),
-			   new ConstantExpr( Constant( new BasicType( q, BasicType::SignedInt ),
-						       toString( value.size() - 1 ) ) ),  // account for '\0'
-			   false, false );
-	return new ConstantExpr( Constant( at, value ), maybeBuild< Expression >( get_argName() ) );
-    }
-    return new ConstantExpr(  Constant( bt, get_value()),  maybeBuild< Expression >( get_argName() ) );
+	::Type::Qualifiers q;
+	BasicType *bt;
+
+	switch ( get_type()){
+	  case Integer:
+		/* Cfr. standard 6.4.4.1 */
+		//bt.set_kind( BasicType::SignedInt );
+		bt = new BasicType( q, BasicType::SignedInt );
+		break;
+	  case Float:
+		bt = new BasicType( q, BasicType::Float );
+		break;
+	  case Character:
+		bt = new BasicType( q, BasicType::Char );
+		break;
+	  case String:
+		// string should probably be a primitive type
+		ArrayType *at;
+		std::string value = get_value();
+		at = new ArrayType( q, new BasicType( q, BasicType::Char ),
+							new ConstantExpr( Constant( new BasicType( q, BasicType::SignedInt ),
+														toString( value.size() - 1 ) ) ),  // account for '\0'
+							false, false );
+		return new ConstantExpr( Constant( at, value ), maybeBuild< Expression >( get_argName() ) );
+	}
+	return new ConstantExpr(  Constant( bt, get_value()),  maybeBuild< Expression >( get_argName() ) );
 }
 
@@ -227,17 +242,17 @@
 
 Expression *VarRefNode::build() const {
-    return new NameExpr( get_name(), maybeBuild< Expression >( get_argName() ) );
+	return new NameExpr( get_name(), maybeBuild< Expression >( get_argName() ) );
 }
 
 void VarRefNode::printOneLine( std::ostream &os, int indent ) const {
-    printDesignation( os );
-    os << get_name() << ' ';
+	printDesignation( os );
+	os << get_name() << ' ';
 }
 
 void VarRefNode::print( std::ostream &os, int indent ) const {
-    printDesignation( os );
-    os << '\r' << string( indent, ' ') << "Referencing: ";
-    os << "Variable: " << get_name();
-    os << endl;
+	printDesignation( os );
+	os << '\r' << string( indent, ' ') << "Referencing: ";
+	os << "Variable: " << get_name();
+	os << endl;
 }
 
@@ -250,34 +265,34 @@
 
 OperatorNode::Type OperatorNode::get_type( void ) const{
-    return type;
+	return type;
 }
 
 void OperatorNode::printOneLine( std::ostream &os, int indent ) const {
-    printDesignation( os );
-    os << OpName[ type ] << ' ';
+	printDesignation( os );
+	os << OpName[ type ] << ' ';
 }
 
 void OperatorNode::print( std::ostream &os, int indent ) const{
-    printDesignation( os );
-    os << '\r' << string( indent, ' ') << "Operator: " << OpName[type] << endl;
-    return;
+	printDesignation( os );
+	os << '\r' << string( indent, ' ') << "Operator: " << OpName[type] << endl;
+	return;
 }
 
 std::string OperatorNode::get_typename( void ) const{
-    return string( OpName[ type ]);
+	return string( OpName[ type ]);
 }
 
 const char *OperatorNode::OpName[] = {
-    "TupleC",  "Comma", "TupleFieldSel",// "TuplePFieldSel", //n-adic
-    // triadic
-    "Cond",   "NCond",
-    // diadic
-    "SizeOf",      "AlignOf", "Attr", "CompLit", "Plus",    "Minus",   "Mul",     "Div",     "Mod",      "Or",
-    "And",       "BitOr",   "BitAnd",  "Xor",     "Cast",    "LShift",  "RShift",  "LThan",   "GThan",
-    "LEThan",    "GEThan", "Eq",      "Neq",     "Assign",  "MulAssn", "DivAssn", "ModAssn", "PlusAssn",
-    "MinusAssn", "LSAssn", "RSAssn",  "AndAssn", "ERAssn",  "OrAssn",  "Index",   "FieldSel","PFieldSel",
-    "Range",
-    // monadic
-    "UnPlus", "UnMinus", "AddressOf", "PointTo", "Neg", "BitNeg", "Incr", "IncrPost", "Decr", "DecrPost", "LabelAddress"
+	"TupleC",  "Comma", "TupleFieldSel",// "TuplePFieldSel", //n-adic
+	// triadic
+	"Cond",   "NCond",
+	// diadic
+	"SizeOf",      "AlignOf", "Attr", "CompLit", "Plus",    "Minus",   "Mul",     "Div",     "Mod",      "Or",
+	"And",       "BitOr",   "BitAnd",  "Xor",     "Cast",    "LShift",  "RShift",  "LThan",   "GThan",
+	"LEThan",    "GEThan", "Eq",      "Neq",     "Assign",  "MulAssn", "DivAssn", "ModAssn", "PlusAssn",
+	"MinusAssn", "LSAssn", "RSAssn",  "AndAssn", "ERAssn",  "OrAssn",  "Index",   "FieldSel","PFieldSel",
+	"Range",
+	// monadic
+	"UnPlus", "UnMinus", "AddressOf", "PointTo", "Neg", "BitNeg", "Incr", "IncrPost", "Decr", "DecrPost", "LabelAddress"
 };
 
@@ -289,40 +304,40 @@
 
 CompositeExprNode::CompositeExprNode( ExpressionNode *f, ExpressionNode *args ):
-    function( f ), arguments( args ) {
+	function( f ), arguments( args ) {
 }
 
 CompositeExprNode::CompositeExprNode( ExpressionNode *f, ExpressionNode *arg1, ExpressionNode *arg2):
-    function( f ), arguments( arg1) {
-    arguments->set_link( arg2);
+	function( f ), arguments( arg1) {
+	arguments->set_link( arg2);
 }
 
 CompositeExprNode::CompositeExprNode( const CompositeExprNode &other ) : ExpressionNode( other ), function( maybeClone( other.function ) ) {
-    ParseNode *cur = other.arguments;
-    while ( cur ) {
-	if ( arguments ) {
-	    arguments->set_link( cur->clone() );
-	} else {
-	    arguments = ( ExpressionNode*)cur->clone();
-	} // if
-	cur = cur->get_link();
-    }
+	ParseNode *cur = other.arguments;
+	while ( cur ) {
+		if ( arguments ) {
+			arguments->set_link( cur->clone() );
+		} else {
+			arguments = ( ExpressionNode*)cur->clone();
+		} // if
+		cur = cur->get_link();
+	}
 }
 
 CompositeExprNode::~CompositeExprNode() {
-    delete function;
-    delete arguments;
+	delete function;
+	delete arguments;
 }
 
 // the names that users use to define operator functions
 static const char *opFuncName[] = {
-    "",  "", "",
-    "",   "",
-    // diadic
-    "",   "", "", "", "?+?",    "?-?",   "?*?",     "?/?",     "?%?",     "",       "",
-    "?|?",  "?&?",  "?^?",     "",    "?<<?",  "?>>?",  "?<?",   "?>?",    "?<=?",
-    "?>=?", "?==?",      "?!=?",     "?=?",  "?*=?", "?/=?", "?%=?", "?+=?", "?-=?",
-    "?<<=?", "?>>=?",  "?&=?", "?^=?",  "?|=?",  "?[?]",   "","","Range",
-    // monadic
-    "+?", "-?", "", "*?", "!?", "~?", "++?", "?++", "--?", "?--", "LabAddress"
+	"",  "", "",
+	"",   "",
+	// diadic
+	"",   "", "", "", "?+?",    "?-?",   "?*?",     "?/?",     "?%?",     "",       "",
+	"?|?",  "?&?",  "?^?",     "",    "?<<?",  "?>>?",  "?<?",   "?>?",    "?<=?",
+	"?>=?", "?==?",      "?!=?",     "?=?",  "?*=?", "?/=?", "?%=?", "?+=?", "?-=?",
+	"?<<=?", "?>>=?",  "?&=?", "?^=?",  "?|=?",  "?[?]",   "","","Range",
+	// monadic
+	"+?", "-?", "", "*?", "!?", "~?", "++?", "?++", "--?", "?--", "LabAddress"
 };
 
@@ -330,382 +345,388 @@
 
 Expression *CompositeExprNode::build() const {
-    OperatorNode *op;
-    std::list<Expression *> args;
-
-    buildList( get_args(), args );
-
-    if ( ! ( op = dynamic_cast<OperatorNode *>( function )) ) {
-	// a function as opposed to an operator
-	return new UntypedExpr( function->build(), args, maybeBuild< Expression >( get_argName() ));
-    } else {
-	switch ( op->get_type()){
-	  case OperatorNode::Incr:
-	  case OperatorNode::Decr:
-	  case OperatorNode::IncrPost:
-	  case OperatorNode::DecrPost:
-	  case OperatorNode::Assign:
-	  case OperatorNode::MulAssn:
-	  case OperatorNode::DivAssn:
-	  case OperatorNode::ModAssn:
-	  case OperatorNode::PlusAssn:
-	  case OperatorNode::MinusAssn:
-	  case OperatorNode::LSAssn:
-	  case OperatorNode::RSAssn:
-	  case OperatorNode::AndAssn:
-	  case OperatorNode::ERAssn:
-	  case OperatorNode::OrAssn:
-	    // the rewrite rules for these expressions specify that the first argument has its address taken
-	    assert( !args.empty() );
-	    args.front() = new AddressExpr( args.front() );
-	    break;
-	  default:
-	    /* do nothing */
-	    ;
-	}
-
-	switch ( op->get_type() ) {
-	  case OperatorNode::Incr:
-	  case OperatorNode::Decr:
-	  case OperatorNode::IncrPost:
-	  case OperatorNode::DecrPost:
-	  case OperatorNode::Assign:
-	  case OperatorNode::MulAssn:
-	  case OperatorNode::DivAssn:
-	  case OperatorNode::ModAssn:
-	  case OperatorNode::PlusAssn:
-	  case OperatorNode::MinusAssn:
-	  case OperatorNode::LSAssn:
-	  case OperatorNode::RSAssn:
-	  case OperatorNode::AndAssn:
-	  case OperatorNode::ERAssn:
-	  case OperatorNode::OrAssn:
-	  case OperatorNode::Plus:
-	  case OperatorNode::Minus:
-	  case OperatorNode::Mul:
-	  case OperatorNode::Div:
-	  case OperatorNode::Mod:
-	  case OperatorNode::BitOr:
-	  case OperatorNode::BitAnd:
-	  case OperatorNode::Xor:
-	  case OperatorNode::LShift:
-	  case OperatorNode::RShift:
-	  case OperatorNode::LThan:
-	  case OperatorNode::GThan:
-	  case OperatorNode::LEThan:
-	  case OperatorNode::GEThan:
-	  case OperatorNode::Eq:
-	  case OperatorNode::Neq:
-	  case OperatorNode::Index:
-	  case OperatorNode::Range:
-	  case OperatorNode::UnPlus:
-	  case OperatorNode::UnMinus:
-	  case OperatorNode::PointTo:
-	  case OperatorNode::Neg:
-	  case OperatorNode::BitNeg:
-	  case OperatorNode::LabelAddress:
-	    return new UntypedExpr( new NameExpr( opFuncName[ op->get_type() ] ), args );
-	  case OperatorNode::AddressOf:
-	    assert( args.size() == 1 );
-	    assert( args.front() );
-
-	    return new AddressExpr( args.front() );
-	  case OperatorNode::Cast:
-	    {
-		TypeValueNode * arg = dynamic_cast<TypeValueNode *>( get_args());
-		assert( arg );
-
-		DeclarationNode *decl_node = arg->get_decl();
-		ExpressionNode *expr_node = dynamic_cast<ExpressionNode *>( arg->get_link());
-
-		Type *targetType = decl_node->buildType();
-		if ( dynamic_cast< VoidType* >( targetType ) ) {
-		    delete targetType;
-		    return new CastExpr( expr_node->build(), maybeBuild< Expression >( get_argName() ) );
-		} else {
-		    return new CastExpr( expr_node->build(),targetType, maybeBuild< Expression >( get_argName() ) );
-		} // if
-	    }
-	  case OperatorNode::FieldSel:
-	    {
-		assert( args.size() == 2 );
-
-		NameExpr *member = dynamic_cast<NameExpr *>( args.back());
-		// TupleExpr *memberTup = dynamic_cast<TupleExpr *>( args.back());
-
-		if ( member != 0 ) {
-		    UntypedMemberExpr *ret = new UntypedMemberExpr( member->get_name(), args.front());
-		    delete member;
-		    return ret;
-		/* else if ( memberTup != 0 )
-		   {
-		   UntypedMemberExpr *ret = new UntypedMemberExpr( memberTup->get_name(), args.front());
-		   delete member;
-		   return ret;
-		   } */
-		} else
-		    assert( false );
-	    }
-	  case OperatorNode::PFieldSel:
-	    {
-		assert( args.size() == 2 );
-
-		NameExpr *member = dynamic_cast<NameExpr *>( args.back());  // modify for Tuples   xxx
-		assert( member != 0 );
-
-		UntypedExpr *deref = new UntypedExpr( new NameExpr( "*?" ) );
-		deref->get_args().push_back( args.front() );
-
-		UntypedMemberExpr *ret = new UntypedMemberExpr( member->get_name(), deref );
-		delete member;
-		return ret;
-	    }
-	  case OperatorNode::AlignOf:
-	  case OperatorNode::SizeOf:
-	    {
+	OperatorNode *op;
+	std::list<Expression *> args;
+
+	buildList( get_args(), args );
+
+	if ( ! ( op = dynamic_cast<OperatorNode *>( function )) ) {
+		// a function as opposed to an operator
+		return new UntypedExpr( function->build(), args, maybeBuild< Expression >( get_argName() ));
+	} else {
+		switch ( op->get_type()){
+		  case OperatorNode::Incr:
+		  case OperatorNode::Decr:
+		  case OperatorNode::IncrPost:
+		  case OperatorNode::DecrPost:
+		  case OperatorNode::Assign:
+		  case OperatorNode::MulAssn:
+		  case OperatorNode::DivAssn:
+		  case OperatorNode::ModAssn:
+		  case OperatorNode::PlusAssn:
+		  case OperatorNode::MinusAssn:
+		  case OperatorNode::LSAssn:
+		  case OperatorNode::RSAssn:
+		  case OperatorNode::AndAssn:
+		  case OperatorNode::ERAssn:
+		  case OperatorNode::OrAssn:
+			// the rewrite rules for these expressions specify that the first argument has its address taken
+			assert( !args.empty() );
+			args.front() = new AddressExpr( args.front() );
+			break;
+		  default:
+			/* do nothing */
+			;
+		}
+
+		switch ( op->get_type() ) {
+		  case OperatorNode::Incr:
+		  case OperatorNode::Decr:
+		  case OperatorNode::IncrPost:
+		  case OperatorNode::DecrPost:
+		  case OperatorNode::Assign:
+		  case OperatorNode::MulAssn:
+		  case OperatorNode::DivAssn:
+		  case OperatorNode::ModAssn:
+		  case OperatorNode::PlusAssn:
+		  case OperatorNode::MinusAssn:
+		  case OperatorNode::LSAssn:
+		  case OperatorNode::RSAssn:
+		  case OperatorNode::AndAssn:
+		  case OperatorNode::ERAssn:
+		  case OperatorNode::OrAssn:
+		  case OperatorNode::Plus:
+		  case OperatorNode::Minus:
+		  case OperatorNode::Mul:
+		  case OperatorNode::Div:
+		  case OperatorNode::Mod:
+		  case OperatorNode::BitOr:
+		  case OperatorNode::BitAnd:
+		  case OperatorNode::Xor:
+		  case OperatorNode::LShift:
+		  case OperatorNode::RShift:
+		  case OperatorNode::LThan:
+		  case OperatorNode::GThan:
+		  case OperatorNode::LEThan:
+		  case OperatorNode::GEThan:
+		  case OperatorNode::Eq:
+		  case OperatorNode::Neq:
+		  case OperatorNode::Index:
+		  case OperatorNode::Range:
+		  case OperatorNode::UnPlus:
+		  case OperatorNode::UnMinus:
+		  case OperatorNode::PointTo:
+		  case OperatorNode::Neg:
+		  case OperatorNode::BitNeg:
+		  case OperatorNode::LabelAddress:
+			return new UntypedExpr( new NameExpr( opFuncName[ op->get_type() ] ), args );
+		  case OperatorNode::AddressOf:
+			assert( args.size() == 1 );
+			assert( args.front() );
+
+			return new AddressExpr( args.front() );
+		  case OperatorNode::Cast:
+			{
+				TypeValueNode * arg = dynamic_cast<TypeValueNode *>( get_args());
+				assert( arg );
+
+				DeclarationNode *decl_node = arg->get_decl();
+				ExpressionNode *expr_node = dynamic_cast<ExpressionNode *>( arg->get_link());
+
+				Type *targetType = decl_node->buildType();
+				if ( dynamic_cast< VoidType* >( targetType ) ) {
+					delete targetType;
+					return new CastExpr( expr_node->build(), maybeBuild< Expression >( get_argName() ) );
+				} else {
+					return new CastExpr( expr_node->build(),targetType, maybeBuild< Expression >( get_argName() ) );
+				} // if
+			}
+		  case OperatorNode::FieldSel:
+			{
+				assert( args.size() == 2 );
+
+				NameExpr *member = dynamic_cast<NameExpr *>( args.back());
+				// TupleExpr *memberTup = dynamic_cast<TupleExpr *>( args.back());
+
+				if ( member != 0 ) {
+					UntypedMemberExpr *ret = new UntypedMemberExpr( member->get_name(), args.front());
+					delete member;
+					return ret;
+					/* else if ( memberTup != 0 )
+					   {
+					   UntypedMemberExpr *ret = new UntypedMemberExpr( memberTup->get_name(), args.front());
+					   delete member;
+					   return ret;
+					   } */
+				} else
+					assert( false );
+			}
+		  case OperatorNode::PFieldSel:
+			{
+				assert( args.size() == 2 );
+
+				NameExpr *member = dynamic_cast<NameExpr *>( args.back());  // modify for Tuples   xxx
+				assert( member != 0 );
+
+				UntypedExpr *deref = new UntypedExpr( new NameExpr( "*?" ) );
+				deref->get_args().push_back( args.front() );
+
+				UntypedMemberExpr *ret = new UntypedMemberExpr( member->get_name(), deref );
+				delete member;
+				return ret;
+			}
+		  case OperatorNode::AlignOf:
+		  case OperatorNode::SizeOf:
+			{
 /// 	bool isSizeOf = ( op->get_type() == OperatorNode::SizeOf );
 
-		if ( TypeValueNode * arg = dynamic_cast<TypeValueNode *>( get_args()) ) {
-		    return new SizeofExpr( arg->get_decl()->buildType());
-		} else {
-		    return new SizeofExpr( args.front());
-		} // if
-	    }
-	  case OperatorNode::Attr:
-	    {
-		VarRefNode *var = dynamic_cast<VarRefNode *>( get_args());
-		assert( var );
-		if ( !get_args()->get_link() ) {
-		    return new AttrExpr( var->build(), ( Expression*)0);
-		} else if ( TypeValueNode * arg = dynamic_cast<TypeValueNode *>( get_args()->get_link()) ) {
-		    return new AttrExpr( var->build(), arg->get_decl()->buildType());
-		} else {
-		    return new AttrExpr( var->build(), args.back());
-		} // if
-	    }
-	  case OperatorNode::CompLit:
-	    throw UnimplementedError( "C99 compound literals" );
-	    // the short-circuited operators
-	  case OperatorNode::Or:
-	  case OperatorNode::And:
-	    assert( args.size() == 2);
-	    return new LogicalExpr( notZeroExpr( args.front() ), notZeroExpr( args.back() ), ( op->get_type() == OperatorNode::And ) );
-	  case OperatorNode::Cond:
-	    {
-		assert( args.size() == 3);
-		std::list< Expression* >::const_iterator i = args.begin();
-		Expression *arg1 = notZeroExpr( *i++ );
-		Expression *arg2 = *i++;
-		Expression *arg3 = *i++;
-		return new ConditionalExpr( arg1, arg2, arg3 );
-	    }
-	  case OperatorNode::NCond:
-	    throw UnimplementedError( "GNU 2-argument conditional expression" );
-	  case OperatorNode::Comma:
-	    {
-		assert( args.size() == 2);
-		std::list< Expression* >::const_iterator i = args.begin();
-		Expression *ret = *i++;
-		while ( i != args.end() ) {
-		    ret = new CommaExpr( ret, *i++ );
-		}
-		return ret;
-	    }
-	    // Tuples
-	  case OperatorNode::TupleC:
-	    {
-		TupleExpr *ret = new TupleExpr();
-		std::copy( args.begin(), args.end(), back_inserter( ret->get_exprs() ) );
-		return ret;
-	    }
-	  default:
-	    // shouldn't happen
-	    return 0;
-	}
-    }
-}
-
-void CompositeExprNode::printOneLine( std::ostream &os, int indent ) const {
-    printDesignation( os );
-    os << "( ";
-    function->printOneLine( os, indent );
-    for ( ExpressionNode *cur = arguments; cur != 0; cur = dynamic_cast< ExpressionNode* >( cur->get_link() ) ) {
-	cur->printOneLine( os, indent );
-    }
-    os << ") ";
-}
-
-void CompositeExprNode::print( std::ostream &os, int indent ) const {
-    printDesignation( os );
-    os << '\r' << string( indent, ' ') << "Application of: " << endl;
-    function->print( os, indent + ParseNode::indent_by );
-
-    os << '\r' << string( indent, ' ') ;
-    if ( arguments ) {
-	os << "... on arguments: " << endl;
-	arguments->printList( os, indent + ParseNode::indent_by );
-    } else
-	os << "... on no arguments: " << endl;
-}
-
-void CompositeExprNode::set_function( ExpressionNode *f ){
-    function = f;
-}
-
-void CompositeExprNode::set_args( ExpressionNode *args ){
-    arguments = args;
-}
-
-ExpressionNode *CompositeExprNode::get_function( void ) const {
-    return function;
-}
-
-ExpressionNode *CompositeExprNode::get_args( void ) const {
-    return arguments;
-}
-
-void CompositeExprNode::add_arg( ExpressionNode *arg ){
-    if ( arguments )
-	arguments->set_link( arg );
-    else
-	set_args( arg );
-}
-
-CommaExprNode::CommaExprNode(): CompositeExprNode( new OperatorNode( OperatorNode::Comma )) {}
-
-CommaExprNode::CommaExprNode( ExpressionNode *exp ) : CompositeExprNode( new OperatorNode( OperatorNode::Comma ), exp ) {
-}
-
-CommaExprNode::CommaExprNode( ExpressionNode *exp1, ExpressionNode *exp2) : CompositeExprNode( new OperatorNode( OperatorNode::Comma ), exp1, exp2) {
-}
-
-CommaExprNode *CommaExprNode::add_to_list( ExpressionNode *exp ){
-    add_arg( exp );
-
-    return this;
-}
-
-CommaExprNode::CommaExprNode( const CommaExprNode &other ) : CompositeExprNode( other ) {
-}
-
-ValofExprNode::ValofExprNode( StatementNode *s ): body( s ) {}
-
-ValofExprNode::ValofExprNode( const ValofExprNode &other ) : ExpressionNode( other ), body( maybeClone( body ) ) {
-}
-
-ValofExprNode::~ValofExprNode() {
-    delete body;
-}
-
-void ValofExprNode::print( std::ostream &os, int indent ) const {
-    printDesignation( os );
-    os << string( indent, ' ') << "Valof Expression:" << std::endl;
-    get_body()->print( os, indent + 4);
-}
-
-void ValofExprNode::printOneLine( std::ostream &, int indent ) const {
-    assert( false );
-}
-
-Expression *ValofExprNode::build() const {
-    return new UntypedValofExpr ( get_body()->build(), maybeBuild< Expression >( get_argName() ) );
-}
-
-ForCtlExprNode::ForCtlExprNode( ParseNode *init_, ExpressionNode *cond, ExpressionNode *incr ) throw ( SemanticError ) : condition( cond ), change( incr ) {
-    if ( init_ == 0 )
-	init = 0;
-    else {
-	DeclarationNode *decl;
-	ExpressionNode *exp;
-
-	if (( decl = dynamic_cast<DeclarationNode *>( init_)) != 0)
-	    init = new StatementNode( decl );
-	else if (( exp = dynamic_cast<ExpressionNode *>( init_)) != 0)
-	    init = new StatementNode( StatementNode::Exp, exp );
-	else
-	    throw SemanticError("Error in for control expression");
-    }
-}
-
-ForCtlExprNode::ForCtlExprNode( const ForCtlExprNode &other )
-    : ExpressionNode( other ), init( maybeClone( other.init ) ), condition( maybeClone( other.condition ) ), change( maybeClone( other.change ) ) {
-}
-
-ForCtlExprNode::~ForCtlExprNode(){
-    delete init;
-    delete condition;
-    delete change;
-}
-
-Expression *ForCtlExprNode::build() const {
-    // this shouldn't be used!
-    assert( false );
-    return 0;
-}
-
-void ForCtlExprNode::print( std::ostream &os, int indent ) const{
-    os << string( indent,' ') << "For Control Expression -- : " << endl;
-
-    os << "\r" << string( indent + 2,' ') << "initialization: ";
-    if ( init != 0)
-	init->print( os, indent + 4);
-
-    os << "\n\r" << string( indent + 2,' ') << "condition: ";
-    if ( condition != 0)
-	condition->print( os, indent + 4);
-    os << "\n\r" << string( indent + 2,' ') << "increment: ";
-    if ( change != 0)
-	change->print( os, indent + 4);
-}
-
-void ForCtlExprNode::printOneLine( std::ostream &, int indent ) const {
-    assert( false );
-}
-
-TypeValueNode::TypeValueNode( DeclarationNode *decl )
-    : decl( decl ) {
-}
-
-TypeValueNode::TypeValueNode( const TypeValueNode &other )
-    : ExpressionNode( other ), decl( maybeClone( other.decl ) ) {
-}
-
-Expression *TypeValueNode::build() const {
-    return new TypeExpr( decl->buildType() );
-}
-
-void TypeValueNode::print( std::ostream &os, int indent ) const {
-    os << std::string( indent, ' ' ) << "Type:";
-    get_decl()->print( os, indent + 2);
-}
-
-void TypeValueNode::printOneLine( std::ostream &os, int indent ) const {
-    os << "Type:";
-    get_decl()->print( os, indent + 2);
-}
-
-ExpressionNode *flattenCommas( ExpressionNode *list ) {
-    if ( CompositeExprNode *composite = dynamic_cast< CompositeExprNode * >( list ) )
-	{
-	    OperatorNode *op;
-	    if ( ( op = dynamic_cast< OperatorNode * >( composite->get_function() )) && ( op->get_type() == OperatorNode::Comma ) )
-		{
-		    if ( ExpressionNode *next = dynamic_cast< ExpressionNode * >( list->get_link() ) )
-			composite->add_arg( next );
-		    return flattenCommas( composite->get_args() );
+				if ( TypeValueNode * arg = dynamic_cast<TypeValueNode *>( get_args()) ) {
+					return new SizeofExpr( arg->get_decl()->buildType());
+				} else {
+					return new SizeofExpr( args.front());
+				} // if
+			}
+		  case OperatorNode::Attr:
+			{
+				VarRefNode *var = dynamic_cast<VarRefNode *>( get_args());
+				assert( var );
+				if ( !get_args()->get_link() ) {
+					return new AttrExpr( var->build(), ( Expression*)0);
+				} else if ( TypeValueNode * arg = dynamic_cast<TypeValueNode *>( get_args()->get_link()) ) {
+					return new AttrExpr( var->build(), arg->get_decl()->buildType());
+				} else {
+					return new AttrExpr( var->build(), args.back());
+				} // if
+			}
+		  case OperatorNode::CompLit:
+			throw UnimplementedError( "C99 compound literals" );
+			// the short-circuited operators
+		  case OperatorNode::Or:
+		  case OperatorNode::And:
+			assert( args.size() == 2);
+			return new LogicalExpr( notZeroExpr( args.front() ), notZeroExpr( args.back() ), ( op->get_type() == OperatorNode::And ) );
+		  case OperatorNode::Cond:
+			{
+				assert( args.size() == 3);
+				std::list< Expression* >::const_iterator i = args.begin();
+				Expression *arg1 = notZeroExpr( *i++ );
+				Expression *arg2 = *i++;
+				Expression *arg3 = *i++;
+				return new ConditionalExpr( arg1, arg2, arg3 );
+			}
+		  case OperatorNode::NCond:
+			throw UnimplementedError( "GNU 2-argument conditional expression" );
+		  case OperatorNode::Comma:
+			{
+				assert( args.size() == 2);
+				std::list< Expression* >::const_iterator i = args.begin();
+				Expression *ret = *i++;
+				while ( i != args.end() ) {
+					ret = new CommaExpr( ret, *i++ );
+				}
+				return ret;
+			}
+			// Tuples
+		  case OperatorNode::TupleC:
+			{
+				TupleExpr *ret = new TupleExpr();
+				std::copy( args.begin(), args.end(), back_inserter( ret->get_exprs() ) );
+				return ret;
+			}
+		  default:
+			// shouldn't happen
+			return 0;
 		}
 	}
-
-    if ( ExpressionNode *next = dynamic_cast< ExpressionNode * >( list->get_link() ) )
-	list->set_next( flattenCommas( next ) );
-
-    return list;
+}
+
+void CompositeExprNode::printOneLine( std::ostream &os, int indent ) const {
+	printDesignation( os );
+	os << "( ";
+	function->printOneLine( os, indent );
+	for ( ExpressionNode *cur = arguments; cur != 0; cur = dynamic_cast< ExpressionNode* >( cur->get_link() ) ) {
+		cur->printOneLine( os, indent );
+	}
+	os << ") ";
+}
+
+void CompositeExprNode::print( std::ostream &os, int indent ) const {
+	printDesignation( os );
+	os << '\r' << string( indent, ' ') << "Application of: " << endl;
+	function->print( os, indent + ParseNode::indent_by );
+
+	os << '\r' << string( indent, ' ') ;
+	if ( arguments ) {
+		os << "... on arguments: " << endl;
+		arguments->printList( os, indent + ParseNode::indent_by );
+	} else
+		os << "... on no arguments: " << endl;
+}
+
+void CompositeExprNode::set_function( ExpressionNode *f ){
+	function = f;
+}
+
+void CompositeExprNode::set_args( ExpressionNode *args ){
+	arguments = args;
+}
+
+ExpressionNode *CompositeExprNode::get_function( void ) const {
+	return function;
+}
+
+ExpressionNode *CompositeExprNode::get_args( void ) const {
+	return arguments;
+}
+
+void CompositeExprNode::add_arg( ExpressionNode *arg ){
+	if ( arguments )
+		arguments->set_link( arg );
+	else
+		set_args( arg );
+}
+
+CommaExprNode::CommaExprNode(): CompositeExprNode( new OperatorNode( OperatorNode::Comma )) {}
+
+CommaExprNode::CommaExprNode( ExpressionNode *exp ) : CompositeExprNode( new OperatorNode( OperatorNode::Comma ), exp ) {
+}
+
+CommaExprNode::CommaExprNode( ExpressionNode *exp1, ExpressionNode *exp2) : CompositeExprNode( new OperatorNode( OperatorNode::Comma ), exp1, exp2) {
+}
+
+CommaExprNode *CommaExprNode::add_to_list( ExpressionNode *exp ){
+	add_arg( exp );
+
+	return this;
+}
+
+CommaExprNode::CommaExprNode( const CommaExprNode &other ) : CompositeExprNode( other ) {
+}
+
+ValofExprNode::ValofExprNode( StatementNode *s ): body( s ) {}
+
+ValofExprNode::ValofExprNode( const ValofExprNode &other ) : ExpressionNode( other ), body( maybeClone( body ) ) {
+}
+
+ValofExprNode::~ValofExprNode() {
+	delete body;
+}
+
+void ValofExprNode::print( std::ostream &os, int indent ) const {
+	printDesignation( os );
+	os << string( indent, ' ') << "Valof Expression:" << std::endl;
+	get_body()->print( os, indent + 4);
+}
+
+void ValofExprNode::printOneLine( std::ostream &, int indent ) const {
+	assert( false );
+}
+
+Expression *ValofExprNode::build() const {
+	return new UntypedValofExpr ( get_body()->build(), maybeBuild< Expression >( get_argName() ) );
+}
+
+ForCtlExprNode::ForCtlExprNode( ParseNode *init_, ExpressionNode *cond, ExpressionNode *incr ) throw ( SemanticError ) : condition( cond ), change( incr ) {
+	if ( init_ == 0 )
+		init = 0;
+	else {
+		DeclarationNode *decl;
+		ExpressionNode *exp;
+
+		if (( decl = dynamic_cast<DeclarationNode *>( init_)) != 0)
+			init = new StatementNode( decl );
+		else if (( exp = dynamic_cast<ExpressionNode *>( init_)) != 0)
+			init = new StatementNode( StatementNode::Exp, exp );
+		else
+			throw SemanticError("Error in for control expression");
+	}
+}
+
+ForCtlExprNode::ForCtlExprNode( const ForCtlExprNode &other )
+	: ExpressionNode( other ), init( maybeClone( other.init ) ), condition( maybeClone( other.condition ) ), change( maybeClone( other.change ) ) {
+}
+
+ForCtlExprNode::~ForCtlExprNode(){
+	delete init;
+	delete condition;
+	delete change;
+}
+
+Expression *ForCtlExprNode::build() const {
+	// this shouldn't be used!
+	assert( false );
+	return 0;
+}
+
+void ForCtlExprNode::print( std::ostream &os, int indent ) const{
+	os << string( indent,' ') << "For Control Expression -- : " << endl;
+
+	os << "\r" << string( indent + 2,' ') << "initialization: ";
+	if ( init != 0)
+		init->print( os, indent + 4);
+
+	os << "\n\r" << string( indent + 2,' ') << "condition: ";
+	if ( condition != 0)
+		condition->print( os, indent + 4);
+	os << "\n\r" << string( indent + 2,' ') << "increment: ";
+	if ( change != 0)
+		change->print( os, indent + 4);
+}
+
+void ForCtlExprNode::printOneLine( std::ostream &, int indent ) const {
+	assert( false );
+}
+
+TypeValueNode::TypeValueNode( DeclarationNode *decl )
+	: decl( decl ) {
+}
+
+TypeValueNode::TypeValueNode( const TypeValueNode &other )
+	: ExpressionNode( other ), decl( maybeClone( other.decl ) ) {
+}
+
+Expression *TypeValueNode::build() const {
+	return new TypeExpr( decl->buildType() );
+}
+
+void TypeValueNode::print( std::ostream &os, int indent ) const {
+	os << std::string( indent, ' ' ) << "Type:";
+	get_decl()->print( os, indent + 2);
+}
+
+void TypeValueNode::printOneLine( std::ostream &os, int indent ) const {
+	os << "Type:";
+	get_decl()->print( os, indent + 2);
+}
+
+ExpressionNode *flattenCommas( ExpressionNode *list ) {
+	if ( CompositeExprNode *composite = dynamic_cast< CompositeExprNode * >( list ) )
+		{
+			OperatorNode *op;
+			if ( ( op = dynamic_cast< OperatorNode * >( composite->get_function() )) && ( op->get_type() == OperatorNode::Comma ) )
+				{
+					if ( ExpressionNode *next = dynamic_cast< ExpressionNode * >( list->get_link() ) )
+						composite->add_arg( next );
+					return flattenCommas( composite->get_args() );
+				}
+		}
+
+	if ( ExpressionNode *next = dynamic_cast< ExpressionNode * >( list->get_link() ) )
+		list->set_next( flattenCommas( next ) );
+
+	return list;
 }
 
 ExpressionNode *tupleContents( ExpressionNode *tuple ) {
-    if ( CompositeExprNode *composite = dynamic_cast< CompositeExprNode * >( tuple ) ) {
-	OperatorNode *op = 0;
-	if ( ( op = dynamic_cast< OperatorNode * >( composite->get_function() )) && ( op->get_type() == OperatorNode::TupleC ) )
-	    return composite->get_args();
-    }
-    return tuple;
-}
+	if ( CompositeExprNode *composite = dynamic_cast< CompositeExprNode * >( tuple ) ) {
+		OperatorNode *op = 0;
+		if ( ( op = dynamic_cast< OperatorNode * >( composite->get_function() )) && ( op->get_type() == OperatorNode::TupleC ) )
+			return composite->get_args();
+	}
+	return tuple;
+}
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/InitializerNode.cc
===================================================================
--- translator/Parser/InitializerNode.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/InitializerNode.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// InitializerNode.cc -- 
+// 
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 13:20:24 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 13:21:40 2015
+// Update Count     : 2
+// 
+
 #include <cassert>
 #include <iostream>
@@ -9,82 +24,88 @@
 InitializerNode::InitializerNode( ExpressionNode *_expr, bool aggrp, ExpressionNode *des )
 	: expr( _expr ), aggregate( aggrp ), designator( des ), kids( 0 ) {
-    if ( aggrp )
-	kids = dynamic_cast< InitializerNode *>( get_link() );
+	if ( aggrp )
+		kids = dynamic_cast< InitializerNode *>( get_link() );
 
-    if ( kids != 0 )
-	set_link( 0 );
+	if ( kids != 0 )
+		set_link( 0 );
 }
 
 InitializerNode::InitializerNode( InitializerNode *init, bool aggrp, ExpressionNode *des )
-    : expr( 0 ), aggregate( aggrp ), designator( des ), kids( 0 ) {
-    if ( init != 0 )
-	set_link(init);
+	: expr( 0 ), aggregate( aggrp ), designator( des ), kids( 0 ) {
+	if ( init != 0 )
+		set_link(init);
 
-    if ( aggrp )
-	kids = dynamic_cast< InitializerNode *>( get_link() );
+	if ( aggrp )
+		kids = dynamic_cast< InitializerNode *>( get_link() );
 
-    if ( kids != 0 )
-	set_next( 0 );
+	if ( kids != 0 )
+		set_next( 0 );
 }
 
 InitializerNode::~InitializerNode() {
-    delete expr;
+	delete expr;
 }
 
 void InitializerNode::print( std::ostream &os, int indent ) const {
-    os << std::string(indent, ' ') << "Initializer expression" << std::endl;
+	os << std::string(indent, ' ') << "Initializer expression" << std::endl;
 }
 
 void InitializerNode::printOneLine( std::ostream &os ) const {
-    if ( ! aggregate ) {
-	if ( designator != 0 ) {
-	    os << "designated by: (";
-	    ExpressionNode *curdes = designator;
-	    while( curdes != 0) {
-		curdes->printOneLine(os);
-		curdes = (ExpressionNode *)(curdes->get_link());
-		if ( curdes ) os << ", ";
-	    } // while
-	    os << ")";
+	if ( ! aggregate ) {
+		if ( designator != 0 ) {
+			os << "designated by: (";
+			ExpressionNode *curdes = designator;
+			while( curdes != 0) {
+				curdes->printOneLine(os);
+				curdes = (ExpressionNode *)(curdes->get_link());
+				if ( curdes ) os << ", ";
+			} // while
+			os << ")";
+		} // if
+		if ( expr ) expr->printOneLine(os);
+	} else {  // It's an aggregate
+		os << "[--";
+		if ( next_init() != 0 )
+			next_init()->printOneLine(os);
+		if (aggregate) os << "--]";
 	} // if
-	if ( expr ) expr->printOneLine(os);
-    } else {  // It's an aggregate
-	os << "[--";
-	if ( next_init() != 0 )
-	    next_init()->printOneLine(os);
-	if (aggregate) os << "--]";
-    } // if
 
-    InitializerNode *moreInit;
-    if  ( get_link() != 0 && ((moreInit = dynamic_cast< InitializerNode * >( get_link() ) ) != 0) )
-	moreInit->printOneLine( os );
+	InitializerNode *moreInit;
+	if  ( get_link() != 0 && ((moreInit = dynamic_cast< InitializerNode * >( get_link() ) ) != 0) )
+		moreInit->printOneLine( os );
 }
 
 Initializer *InitializerNode::build() const {
-    // if ( get_expression() == 0 ) return 0;  // XXX (?)
+	// if ( get_expression() == 0 ) return 0;  // XXX (?)
 
-    if ( aggregate ) {
-	assert( next_init() != 0 );
+	if ( aggregate ) {
+		assert( next_init() != 0 );
 
-	std::list< Initializer *> initlist;
-	buildList<Initializer, InitializerNode>( next_init(), initlist );
+		std::list< Initializer *> initlist;
+		buildList<Initializer, InitializerNode>( next_init(), initlist );
 
-	std::list< Expression *> designlist;
+		std::list< Expression *> designlist;
 
-	if ( designator != 0 ) {
-	    buildList<Expression, ExpressionNode>( designator, designlist );
+		if ( designator != 0 ) {
+			buildList<Expression, ExpressionNode>( designator, designlist );
+		} // if
+
+		return new ListInit( initlist, designlist );
+	} else {
+		std::list< Expression *> designators;
+
+		if ( designator != 0 )
+			buildList<Expression, ExpressionNode>( designator, designators );
+
+		if ( get_expression() != 0)
+			return new SingleInit( get_expression()->build(), designators );
 	} // if
 
-	return new ListInit( initlist, designlist );
-    } else {
-	std::list< Expression *> designators;
+	return 0;
+}
 
-	if ( designator != 0 )
-	    buildList<Expression, ExpressionNode>( designator, designators );
-
-	if ( get_expression() != 0)
-	    return new SingleInit( get_expression()->build(), designators );
-    } // if
-
-    return 0;
-}
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/LinkageSpec.cc
===================================================================
--- translator/Parser/LinkageSpec.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/LinkageSpec.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// LinkageSpec.cc -- 
+// 
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 13:22:09 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 13:23:21 2015
+// Update Count     : 2
+// 
+
 #include <string>
 #include <cassert>
@@ -6,73 +21,79 @@
 
 LinkageSpec::Type LinkageSpec::fromString( const std::string &stringSpec ) {
-    if ( stringSpec == "\"Cforall\"" ) {
-	return Cforall;
-    } else if ( stringSpec == "\"C\"" ) {
-	return C;
-    } else {
-	throw SemanticError( "Invalid linkage specifier " + stringSpec );
-    }
+	if ( stringSpec == "\"Cforall\"" ) {
+		return Cforall;
+	} else if ( stringSpec == "\"C\"" ) {
+		return C;
+	} else {
+		throw SemanticError( "Invalid linkage specifier " + stringSpec );
+	}
 }
 
 std::string LinkageSpec::toString( LinkageSpec::Type linkage ) {
-    switch ( linkage ) {
-      case Intrinsic:
-	return "intrinsic";
-      case Cforall:
-	return "Cforall";
-      case C:
-	return "C";
-      case AutoGen:
-	return "automatically generated";
-      case Compiler:
-	return "compiler built-in";
-    }
-    assert( false );
-    return "";
+	switch ( linkage ) {
+	  case Intrinsic:
+		return "intrinsic";
+	  case Cforall:
+		return "Cforall";
+	  case C:
+		return "C";
+	  case AutoGen:
+		return "automatically generated";
+	  case Compiler:
+		return "compiler built-in";
+	}
+	assert( false );
+	return "";
 }
 
 bool LinkageSpec::isDecoratable( Type t ) {
-    switch ( t ) {
-      case Intrinsic:
-      case Cforall:
-      case AutoGen:
-	return true;
-      case C:
-      case Compiler:
+	switch ( t ) {
+	  case Intrinsic:
+	  case Cforall:
+	  case AutoGen:
+		return true;
+	  case C:
+	  case Compiler:
+		return false;
+	}
+	assert( false );
 	return false;
-    }
-    assert( false );
-    return false;
 }
 
 bool LinkageSpec::isGeneratable( Type t ) {
-    switch ( t ) {
-      case Intrinsic:
-      case Cforall:
-      case AutoGen:
-      case C:
-	return true;
-      case Compiler:
+	switch ( t ) {
+	  case Intrinsic:
+	  case Cforall:
+	  case AutoGen:
+	  case C:
+		return true;
+	  case Compiler:
+		return false;
+	}
+	assert( false );
 	return false;
-    }
-    assert( false );
-    return false;
 }
 
 bool LinkageSpec::isOverloadable( Type t ) {
-    return isDecoratable( t );
+	return isDecoratable( t );
 }
 
 bool LinkageSpec::isBuiltin( Type t ) {
-    switch ( t ) {
-      case Cforall:
-      case AutoGen:
-      case C:
+	switch ( t ) {
+	  case Cforall:
+	  case AutoGen:
+	  case C:
+		return false;
+	  case Intrinsic:
+	  case Compiler:
+		return true;
+	}
+	assert( false );
 	return false;
-      case Intrinsic:
-      case Compiler:
-	return true;
-    }
-    assert( false );
-    return false;
 }
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/LinkageSpec.h
===================================================================
--- translator/Parser/LinkageSpec.h	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/LinkageSpec.h	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// LinkageSpec.h -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 13:24:28 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 13:26:14 2015
+// Update Count     : 3
+//
+
 #ifndef LINKAGESPEC_H
 #define LINKAGESPEC_H
@@ -5,20 +20,26 @@
 
 struct LinkageSpec {
-    enum Type {
-	Intrinsic,		// C built-in defined in prelude
-	Cforall,		// ordinary
-	C,			// not overloadable, not mangled
-	AutoGen,		// built by translator (struct assignment)
-	Compiler		// gcc internal
-    };
+	enum Type {
+		Intrinsic,										// C built-in defined in prelude
+		Cforall,										// ordinary
+		C,												// not overloadable, not mangled
+		AutoGen,										// built by translator (struct assignment)
+		Compiler										// gcc internal
+	};
   
-    static Type fromString( const std::string & );
-    static std::string toString( Type );
+	static Type fromString( const std::string & );
+	static std::string toString( Type );
   
-    static bool isDecoratable( Type );
-    static bool isGeneratable( Type );
-    static bool isOverloadable( Type );
-    static bool isBuiltin( Type );
+	static bool isDecoratable( Type );
+	static bool isGeneratable( Type );
+	static bool isOverloadable( Type );
+	static bool isBuiltin( Type );
 };
 
 #endif // LINKAGESPEC_H
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/ParseNode.cc
===================================================================
--- translator/Parser/ParseNode.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/ParseNode.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// ParseNode.cc -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 13:26:29 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 13:27:51 2015
+// Update Count     : 2
+// 
+
 #include "ParseNode.h"
 using namespace std;
@@ -74,15 +89,13 @@
 
 ParseNode *mkList( ParseNode &pn ) {
-    /* it just relies on `operator,' to take care of the "arguments" and provides
-       a nice interface to an awful-looking address-of, rendering, for example
-       (StatementNode *)(&(*$5 + *$7)) into (StatementNode *)mkList(($5, $7))
-       (although "nice" is probably not the word)
-    */
+    // it just relies on `operator,' to take care of the "arguments" and provides a nice interface to an awful-looking
+    // address-of, rendering, for example (StatementNode *)(&(*$5 + *$7)) into (StatementNode *)mkList(($5, $7))
+    // (although "nice" is probably not the word)
     return &pn;
 }
 
-
 // Local Variables: //
-// mode: C++                //
-// compile-command: "gmake" //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
 // End: //
Index: translator/Parser/ParseNode.h
===================================================================
--- translator/Parser/ParseNode.h	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/ParseNode.h	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// ParseNode.h -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 13:28:16 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 13:30:24 2015
+// Update Count     : 3
+//
+
 #ifndef PARSENODE_H
 #define PARSENODE_H
@@ -21,29 +36,29 @@
 class ParseNode {
   public:
-    ParseNode( void );
-    ParseNode ( std::string );
-    virtual ~ParseNode( void );
-
-    ParseNode *set_name ( std::string ) ;
-    ParseNode *set_name ( std::string * ) ;
-
-    std::string get_name( void );
-
-    ParseNode *get_link( void ) const;
-    ParseNode *get_last( void );
-    ParseNode *set_link( ParseNode * );
-    void set_next( ParseNode *newlink ) { next = newlink; }
-
-    virtual ParseNode *clone() const { return 0; };
-
-    const std::string get_name( void ) const;
-    virtual void print( std::ostream &, int indent = 0 ) const;
-    virtual void printList( std::ostream &, int indent = 0 ) const;
-
-    ParseNode &operator,( ParseNode &);
+	ParseNode( void );
+	ParseNode ( std::string );
+	virtual ~ParseNode( void );
+
+	ParseNode *set_name ( std::string ) ;
+	ParseNode *set_name ( std::string * ) ;
+
+	std::string get_name( void );
+
+	ParseNode *get_link( void ) const;
+	ParseNode *get_last( void );
+	ParseNode *set_link( ParseNode * );
+	void set_next( ParseNode *newlink ) { next = newlink; }
+
+	virtual ParseNode *clone() const { return 0; };
+
+	const std::string get_name( void ) const;
+	virtual void print( std::ostream &, int indent = 0 ) const;
+	virtual void printList( std::ostream &, int indent = 0 ) const;
+
+	ParseNode &operator,( ParseNode &);
   protected:
-    std::string name;
-    ParseNode *next;
-    static int indent_by;
+	std::string name;
+	ParseNode *next;
+	static int indent_by;
 };
 
@@ -52,25 +67,25 @@
 class ExpressionNode : public ParseNode {
   public:
-    ExpressionNode();
-    ExpressionNode( std::string * );
-    ExpressionNode( const ExpressionNode &other );
-    virtual ~ExpressionNode() { /* can't delete asArgName because it might be referenced elsewhere */ };
-
-    virtual ExpressionNode *clone() const = 0;
-
-    virtual CommaExprNode *add_to_list( ExpressionNode * );
-
-    ExpressionNode *get_argName() const { return argName; }
-    ExpressionNode *set_asArgName( std::string *aName );
-    ExpressionNode *set_asArgName( ExpressionNode *aDesignator );
-
-    virtual void print( std::ostream &, int indent = 0) const = 0;
-    virtual void printOneLine( std::ostream &, int indent = 0) const = 0;
-
-    virtual Expression *build() const = 0;
+	ExpressionNode();
+	ExpressionNode( std::string * );
+	ExpressionNode( const ExpressionNode &other );
+	virtual ~ExpressionNode() {} // cannot delete asArgName because it might be referenced elsewhere
+
+	virtual ExpressionNode *clone() const = 0;
+
+	virtual CommaExprNode *add_to_list( ExpressionNode * );
+
+	ExpressionNode *get_argName() const { return argName; }
+	ExpressionNode *set_asArgName( std::string *aName );
+	ExpressionNode *set_asArgName( ExpressionNode *aDesignator );
+
+	virtual void print( std::ostream &, int indent = 0) const = 0;
+	virtual void printOneLine( std::ostream &, int indent = 0) const = 0;
+
+	virtual Expression *build() const = 0;
   protected:
-    void printDesignation ( std::ostream &, int indent = 0) const;
-  private:
-    ExpressionNode *argName;
+	void printDesignation ( std::ostream &, int indent = 0) const;
+  private:
+	ExpressionNode *argName;
 };
 
@@ -78,104 +93,104 @@
 class NullExprNode : public ExpressionNode {
   public:
-    NullExprNode();
-
-    virtual NullExprNode *clone() const;
-
-    virtual void print( std::ostream &, int indent = 0) const;
-    virtual void printOneLine( std::ostream &, int indent = 0) const;
-
-    virtual Expression *build() const;
+	NullExprNode();
+
+	virtual NullExprNode *clone() const;
+
+	virtual void print( std::ostream &, int indent = 0) const;
+	virtual void printOneLine( std::ostream &, int indent = 0) const;
+
+	virtual Expression *build() const;
 };
 
 class ConstantNode : public ExpressionNode {
   public:
-    enum Type {
-	Integer, Float, Character, String /* , Range, EnumConstant  */
-    };
-
-    ConstantNode( void );
-    ConstantNode( std::string * );
-    ConstantNode( Type, std::string * );
-    ConstantNode( const ConstantNode &other );
-
-    virtual ConstantNode *clone() const { return new ConstantNode( *this ); }
-
-    Type get_type( void ) const ;
-    virtual void print( std::ostream &, int indent = 0) const;
-    virtual void printOneLine( std::ostream &, int indent = 0) const;
-
-    std::string get_value() const { return value; }
-    ConstantNode *append( std::string *newValue );
-
-    Expression *build() const;
-  private:
-    void classify( std::string &);
-    Type type;
-    std::string value;
-    bool sign;
-    short base;
-    int longs, size;
+	enum Type {
+		Integer, Float, Character, String /* , Range, EnumConstant  */
+	};
+
+	ConstantNode( void );
+	ConstantNode( std::string * );
+	ConstantNode( Type, std::string * );
+	ConstantNode( const ConstantNode &other );
+
+	virtual ConstantNode *clone() const { return new ConstantNode( *this ); }
+
+	Type get_type( void ) const ;
+	virtual void print( std::ostream &, int indent = 0) const;
+	virtual void printOneLine( std::ostream &, int indent = 0) const;
+
+	std::string get_value() const { return value; }
+	ConstantNode *append( std::string *newValue );
+
+	Expression *build() const;
+  private:
+	void classify( std::string &);
+	Type type;
+	std::string value;
+	bool sign;
+	short base;
+	int longs, size;
 };
 
 class VarRefNode : public ExpressionNode {
   public:
-    VarRefNode();
-    VarRefNode( std::string *, bool isLabel = false );
-    VarRefNode( const VarRefNode &other );
-
-    virtual Expression *build() const ;
-
-    virtual VarRefNode *clone() const { return new VarRefNode( *this ); }
-
-    virtual void print( std::ostream &, int indent = 0) const;
-    virtual void printOneLine( std::ostream &, int indent = 0) const;
-  private:
-    bool isLabel;
+	VarRefNode();
+	VarRefNode( std::string *, bool isLabel = false );
+	VarRefNode( const VarRefNode &other );
+
+	virtual Expression *build() const ;
+
+	virtual VarRefNode *clone() const { return new VarRefNode( *this ); }
+
+	virtual void print( std::ostream &, int indent = 0) const;
+	virtual void printOneLine( std::ostream &, int indent = 0) const;
+  private:
+	bool isLabel;
 };
 
 class TypeValueNode : public ExpressionNode {
   public:
-    TypeValueNode( DeclarationNode * );
-    TypeValueNode( const TypeValueNode &other );
-
-    DeclarationNode *get_decl() const { return decl; }
-
-    virtual Expression *build() const ;
-
-    virtual TypeValueNode *clone() const { return new TypeValueNode( *this ); }
-
-    virtual void print( std::ostream &, int indent = 0) const;
-    virtual void printOneLine( std::ostream &, int indent = 0) const;
-  private:
-    DeclarationNode *decl;
+	TypeValueNode( DeclarationNode * );
+	TypeValueNode( const TypeValueNode &other );
+
+	DeclarationNode *get_decl() const { return decl; }
+
+	virtual Expression *build() const ;
+
+	virtual TypeValueNode *clone() const { return new TypeValueNode( *this ); }
+
+	virtual void print( std::ostream &, int indent = 0) const;
+	virtual void printOneLine( std::ostream &, int indent = 0) const;
+  private:
+	DeclarationNode *decl;
 };
 
 class OperatorNode : public ExpressionNode {
   public:
-    enum Type { TupleC, Comma, TupleFieldSel,
-		Cond, NCond, 
-		SizeOf, AlignOf, Attr, CompLit, Plus, Minus, Mul, Div, Mod, Or, And, 
-	        BitOr, BitAnd, Xor, Cast, LShift, RShift, LThan, GThan, LEThan, GEThan, Eq, Neq, 
-	        Assign, MulAssn, DivAssn, ModAssn, PlusAssn, MinusAssn, LSAssn, RSAssn, AndAssn, 
-	        ERAssn, OrAssn, Index, FieldSel, PFieldSel, Range,
-		UnPlus, UnMinus, AddressOf, PointTo, Neg, BitNeg, Incr, IncrPost, Decr, DecrPost, LabelAddress
-    };
-
-    OperatorNode( Type t );
-    OperatorNode( const OperatorNode &other );
-    virtual ~OperatorNode();
-
-    virtual OperatorNode *clone() const { return new OperatorNode( *this ); }
-
-    Type get_type( void ) const;
-    std::string get_typename( void ) const;
-
-    virtual void print( std::ostream &, int indent = 0) const;
-    virtual void printOneLine( std::ostream &, int indent = 0) const;
-
-    virtual Expression *build() const { return 0; }
-  private:
-    Type type;
-    static const char *OpName[];
+	enum Type { TupleC, Comma, TupleFieldSel,
+				Cond, NCond, 
+				SizeOf, AlignOf, Attr, CompLit, Plus, Minus, Mul, Div, Mod, Or, And, 
+				BitOr, BitAnd, Xor, Cast, LShift, RShift, LThan, GThan, LEThan, GEThan, Eq, Neq, 
+				Assign, MulAssn, DivAssn, ModAssn, PlusAssn, MinusAssn, LSAssn, RSAssn, AndAssn, 
+				ERAssn, OrAssn, Index, FieldSel, PFieldSel, Range,
+				UnPlus, UnMinus, AddressOf, PointTo, Neg, BitNeg, Incr, IncrPost, Decr, DecrPost, LabelAddress
+	};
+
+	OperatorNode( Type t );
+	OperatorNode( const OperatorNode &other );
+	virtual ~OperatorNode();
+
+	virtual OperatorNode *clone() const { return new OperatorNode( *this ); }
+
+	Type get_type( void ) const;
+	std::string get_typename( void ) const;
+
+	virtual void print( std::ostream &, int indent = 0) const;
+	virtual void printOneLine( std::ostream &, int indent = 0) const;
+
+	virtual Expression *build() const { return 0; }
+  private:
+	Type type;
+	static const char *OpName[];
 };
 
@@ -183,77 +198,77 @@
 class CompositeExprNode : public ExpressionNode {
   public:
-    CompositeExprNode( void );
-    CompositeExprNode( std::string * );
-    CompositeExprNode( ExpressionNode *f, ExpressionNode *args = 0 );
-    CompositeExprNode( ExpressionNode *f, ExpressionNode *arg1, ExpressionNode *arg2 );
-    CompositeExprNode( const CompositeExprNode &other );
-    virtual ~CompositeExprNode();
-
-    virtual CompositeExprNode *clone() const { return new CompositeExprNode( *this ); }
-    virtual Expression *build() const;
-
-    virtual void print( std::ostream &, int indent = 0) const;
-    virtual void printOneLine( std::ostream &, int indent = 0) const;
-
-    void set_function( ExpressionNode * );
-    void set_args( ExpressionNode * );
-
-    void add_arg( ExpressionNode * );
-
-    ExpressionNode *get_function() const;
-    ExpressionNode *get_args() const;
-  private:
-    ExpressionNode *function;
-    ExpressionNode *arguments;
+	CompositeExprNode( void );
+	CompositeExprNode( std::string * );
+	CompositeExprNode( ExpressionNode *f, ExpressionNode *args = 0 );
+	CompositeExprNode( ExpressionNode *f, ExpressionNode *arg1, ExpressionNode *arg2 );
+	CompositeExprNode( const CompositeExprNode &other );
+	virtual ~CompositeExprNode();
+
+	virtual CompositeExprNode *clone() const { return new CompositeExprNode( *this ); }
+	virtual Expression *build() const;
+
+	virtual void print( std::ostream &, int indent = 0) const;
+	virtual void printOneLine( std::ostream &, int indent = 0) const;
+
+	void set_function( ExpressionNode * );
+	void set_args( ExpressionNode * );
+
+	void add_arg( ExpressionNode * );
+
+	ExpressionNode *get_function() const;
+	ExpressionNode *get_args() const;
+  private:
+	ExpressionNode *function;
+	ExpressionNode *arguments;
 };
 
 class CommaExprNode : public CompositeExprNode {
   public:
-    CommaExprNode();
-    CommaExprNode( ExpressionNode * );
-    CommaExprNode( ExpressionNode *, ExpressionNode * );
-    CommaExprNode( const CommaExprNode &other );
-
-    virtual CommaExprNode *add_to_list( ExpressionNode * );
-    virtual CommaExprNode *clone() const { return new CommaExprNode( *this ); }
+	CommaExprNode();
+	CommaExprNode( ExpressionNode * );
+	CommaExprNode( ExpressionNode *, ExpressionNode * );
+	CommaExprNode( const CommaExprNode &other );
+
+	virtual CommaExprNode *add_to_list( ExpressionNode * );
+	virtual CommaExprNode *clone() const { return new CommaExprNode( *this ); }
 };
 
 class ForCtlExprNode : public ExpressionNode {
   public:
-    ForCtlExprNode( ParseNode *, ExpressionNode *, ExpressionNode * ) throw ( SemanticError );
-    ForCtlExprNode( const ForCtlExprNode &other );
-    ~ForCtlExprNode();
-
-    StatementNode *get_init() const { return init; }
-    ExpressionNode *get_condition() const { return condition; }
-    ExpressionNode *get_change() const { return change; }
-
-    virtual ForCtlExprNode *clone() const { return new ForCtlExprNode( *this ); }
-    virtual Expression *build() const;
-
-    virtual void print( std::ostream &, int indent = 0 ) const;
-    virtual void printOneLine( std::ostream &, int indent = 0 ) const;
-  private:
-    StatementNode *init;
-    ExpressionNode *condition;
-    ExpressionNode *change;
+	ForCtlExprNode( ParseNode *, ExpressionNode *, ExpressionNode * ) throw ( SemanticError );
+	ForCtlExprNode( const ForCtlExprNode &other );
+	~ForCtlExprNode();
+
+	StatementNode *get_init() const { return init; }
+	ExpressionNode *get_condition() const { return condition; }
+	ExpressionNode *get_change() const { return change; }
+
+	virtual ForCtlExprNode *clone() const { return new ForCtlExprNode( *this ); }
+	virtual Expression *build() const;
+
+	virtual void print( std::ostream &, int indent = 0 ) const;
+	virtual void printOneLine( std::ostream &, int indent = 0 ) const;
+  private:
+	StatementNode *init;
+	ExpressionNode *condition;
+	ExpressionNode *change;
 };
 
 class ValofExprNode : public ExpressionNode {
   public:
-    ValofExprNode();
-    ValofExprNode( StatementNode *s = 0 );
-    ValofExprNode( const ValofExprNode &other );
-    ~ValofExprNode();
+	ValofExprNode();
+	ValofExprNode( StatementNode *s = 0 );
+	ValofExprNode( const ValofExprNode &other );
+	~ValofExprNode();
   
-    virtual ValofExprNode *clone() const { return new ValofExprNode( *this ); }
-
-    StatementNode *get_body() const { return body; }
-    void print( std::ostream &, int indent = 0 ) const;
-    void printOneLine( std::ostream &, int indent = 0 ) const;
-    Expression *build() const;
-
-  private:
-    StatementNode *body;
+	virtual ValofExprNode *clone() const { return new ValofExprNode( *this ); }
+
+	StatementNode *get_body() const { return body; }
+	void print( std::ostream &, int indent = 0 ) const;
+	void printOneLine( std::ostream &, int indent = 0 ) const;
+	Expression *build() const;
+
+  private:
+	StatementNode *body;
 };
 
@@ -262,198 +277,198 @@
 class DeclarationNode : public ParseNode {
   public:
-    enum Qualifier { Const, Restrict, Volatile, Lvalue, Atomic, Attribute };
-    enum StorageClass { Extern, Static, Auto, Register, Inline, Fortran };
-    enum BasicType { Char, Int, Float, Double, Void, Bool, Complex, Imaginary };
-    enum Modifier { Signed, Unsigned, Short, Long };
-    enum TyCon { Struct, Union, Context };
-    enum TypeClass { Type, Dtype, Ftype };
-
-    static const char *qualifierName[];
-    static const char *basicTypeName[];
-    static const char *modifierName[];
-    static const char *tyConName[];
-    static const char *typeClassName[];
-
-    static DeclarationNode *newFunction( std::string *name, DeclarationNode *ret, DeclarationNode *param,
-					 StatementNode *body, bool newStyle = false );
-    static DeclarationNode *newQualifier( Qualifier );
-    static DeclarationNode *newStorageClass( StorageClass );
-    static DeclarationNode *newBasicType( BasicType );
-    static DeclarationNode *newModifier( Modifier );
-    static DeclarationNode *newForall( DeclarationNode *);
-    static DeclarationNode *newFromTypedef( std::string *);
-    static DeclarationNode *newAggregate( TyCon kind, std::string *name, DeclarationNode *formals, ExpressionNode *actuals, DeclarationNode *fields );
-    static DeclarationNode *newEnum( std::string *name, DeclarationNode *constants );
-    static DeclarationNode *newEnumConstant( std::string *name, ExpressionNode *constant );
-    static DeclarationNode *newName( std::string *);
-    static DeclarationNode *newFromTypeGen( std::string*, ExpressionNode *params );
-    static DeclarationNode *newTypeParam( TypeClass, std::string *);
-    static DeclarationNode *newContext( std::string *name, DeclarationNode *params, DeclarationNode *asserts );
-    static DeclarationNode *newContextUse( std::string *name, ExpressionNode *params );
-    static DeclarationNode *newTypeDecl( std::string *name, DeclarationNode *typeParams );
-    static DeclarationNode *newPointer( DeclarationNode *qualifiers );
-    static DeclarationNode *newArray( ExpressionNode *size, DeclarationNode *qualifiers, bool isStatic );
-    static DeclarationNode *newVarArray( DeclarationNode *qualifiers );
-    static DeclarationNode *newBitfield( ExpressionNode *size );
-    static DeclarationNode *newTuple( DeclarationNode *members );
-    static DeclarationNode *newTypeof( ExpressionNode *expr );
-    static DeclarationNode *newAttr( std::string*, ExpressionNode *expr );
-    static DeclarationNode *newAttr( std::string*, DeclarationNode *type );
-
-    DeclarationNode *addQualifiers( DeclarationNode *);
-    DeclarationNode *copyStorageClasses( DeclarationNode *);
-    DeclarationNode *addType( DeclarationNode *);
-    DeclarationNode *addTypedef();
-    DeclarationNode *addAssertions( DeclarationNode *);
-    DeclarationNode *addName( std::string *);
-    DeclarationNode *addBitfield( ExpressionNode *size );
-    DeclarationNode *addVarArgs();
-    DeclarationNode *addFunctionBody( StatementNode *body );
-    DeclarationNode *addOldDeclList( DeclarationNode *list );
-    DeclarationNode *addPointer( DeclarationNode *qualifiers );
-    DeclarationNode *addArray( DeclarationNode *array );
-    DeclarationNode *addNewPointer( DeclarationNode *pointer );
-    DeclarationNode *addNewArray( DeclarationNode *array );
-    DeclarationNode *addParamList( DeclarationNode *list );
-    DeclarationNode *addIdList( DeclarationNode *list );       // old-style functions
-    DeclarationNode *addInitializer( InitializerNode *init );
-
-    DeclarationNode *cloneType( std::string *newName );
-    DeclarationNode *cloneType( DeclarationNode *existing );
-    DeclarationNode *cloneType( int ) { return cloneType( ( std::string *)0 ); }
-    DeclarationNode *cloneBaseType( std::string *newName );
-    DeclarationNode *cloneBaseType( DeclarationNode *newdecl );
-
-    DeclarationNode *appendList( DeclarationNode  *);
-
-    DeclarationNode *clone() const;
-    void print( std::ostream &, int indent = 0 ) const;
-    void printList( std::ostream &, int indent = 0 ) const;
-
-    Declaration *build() const;
-    ::Type *buildType() const;
-
-    bool get_hasEllipsis() const;
-    std::string get_name() const { return name; }
-    LinkageSpec::Type get_linkage() const { return linkage; }
-    DeclarationNode *extractAggregate() const;
-
-    DeclarationNode();
-    ~DeclarationNode();
-  private:
-    Declaration::StorageClass buildStorageClass() const;
-    bool buildInline() const;
-
-    TypeData *type;
-    std::string name;
-    std::list< StorageClass > storageClasses;
-    ExpressionNode *bitfieldWidth;
-    InitializerNode *initializer;
-    bool hasEllipsis;
-    LinkageSpec::Type linkage;
-
-    static UniqueName anonymous;
+	enum Qualifier { Const, Restrict, Volatile, Lvalue, Atomic, Attribute };
+	enum StorageClass { Extern, Static, Auto, Register, Inline, Fortran };
+	enum BasicType { Char, Int, Float, Double, Void, Bool, Complex, Imaginary };
+	enum Modifier { Signed, Unsigned, Short, Long };
+	enum TyCon { Struct, Union, Context };
+	enum TypeClass { Type, Dtype, Ftype };
+
+	static const char *qualifierName[];
+	static const char *basicTypeName[];
+	static const char *modifierName[];
+	static const char *tyConName[];
+	static const char *typeClassName[];
+
+	static DeclarationNode *newFunction( std::string *name, DeclarationNode *ret, DeclarationNode *param,
+										 StatementNode *body, bool newStyle = false );
+	static DeclarationNode *newQualifier( Qualifier );
+	static DeclarationNode *newStorageClass( StorageClass );
+	static DeclarationNode *newBasicType( BasicType );
+	static DeclarationNode *newModifier( Modifier );
+	static DeclarationNode *newForall( DeclarationNode *);
+	static DeclarationNode *newFromTypedef( std::string *);
+	static DeclarationNode *newAggregate( TyCon kind, std::string *name, DeclarationNode *formals, ExpressionNode *actuals, DeclarationNode *fields );
+	static DeclarationNode *newEnum( std::string *name, DeclarationNode *constants );
+	static DeclarationNode *newEnumConstant( std::string *name, ExpressionNode *constant );
+	static DeclarationNode *newName( std::string *);
+	static DeclarationNode *newFromTypeGen( std::string*, ExpressionNode *params );
+	static DeclarationNode *newTypeParam( TypeClass, std::string *);
+	static DeclarationNode *newContext( std::string *name, DeclarationNode *params, DeclarationNode *asserts );
+	static DeclarationNode *newContextUse( std::string *name, ExpressionNode *params );
+	static DeclarationNode *newTypeDecl( std::string *name, DeclarationNode *typeParams );
+	static DeclarationNode *newPointer( DeclarationNode *qualifiers );
+	static DeclarationNode *newArray( ExpressionNode *size, DeclarationNode *qualifiers, bool isStatic );
+	static DeclarationNode *newVarArray( DeclarationNode *qualifiers );
+	static DeclarationNode *newBitfield( ExpressionNode *size );
+	static DeclarationNode *newTuple( DeclarationNode *members );
+	static DeclarationNode *newTypeof( ExpressionNode *expr );
+	static DeclarationNode *newAttr( std::string*, ExpressionNode *expr );
+	static DeclarationNode *newAttr( std::string*, DeclarationNode *type );
+
+	DeclarationNode *addQualifiers( DeclarationNode *);
+	DeclarationNode *copyStorageClasses( DeclarationNode *);
+	DeclarationNode *addType( DeclarationNode *);
+	DeclarationNode *addTypedef();
+	DeclarationNode *addAssertions( DeclarationNode *);
+	DeclarationNode *addName( std::string *);
+	DeclarationNode *addBitfield( ExpressionNode *size );
+	DeclarationNode *addVarArgs();
+	DeclarationNode *addFunctionBody( StatementNode *body );
+	DeclarationNode *addOldDeclList( DeclarationNode *list );
+	DeclarationNode *addPointer( DeclarationNode *qualifiers );
+	DeclarationNode *addArray( DeclarationNode *array );
+	DeclarationNode *addNewPointer( DeclarationNode *pointer );
+	DeclarationNode *addNewArray( DeclarationNode *array );
+	DeclarationNode *addParamList( DeclarationNode *list );
+	DeclarationNode *addIdList( DeclarationNode *list );       // old-style functions
+	DeclarationNode *addInitializer( InitializerNode *init );
+
+	DeclarationNode *cloneType( std::string *newName );
+	DeclarationNode *cloneType( DeclarationNode *existing );
+	DeclarationNode *cloneType( int ) { return cloneType( ( std::string *)0 ); }
+	DeclarationNode *cloneBaseType( std::string *newName );
+	DeclarationNode *cloneBaseType( DeclarationNode *newdecl );
+
+	DeclarationNode *appendList( DeclarationNode  *);
+
+	DeclarationNode *clone() const;
+	void print( std::ostream &, int indent = 0 ) const;
+	void printList( std::ostream &, int indent = 0 ) const;
+
+	Declaration *build() const;
+	::Type *buildType() const;
+
+	bool get_hasEllipsis() const;
+	std::string get_name() const { return name; }
+	LinkageSpec::Type get_linkage() const { return linkage; }
+	DeclarationNode *extractAggregate() const;
+
+	DeclarationNode();
+	~DeclarationNode();
+  private:
+	Declaration::StorageClass buildStorageClass() const;
+	bool buildInline() const;
+
+	TypeData *type;
+	std::string name;
+	std::list< StorageClass > storageClasses;
+	ExpressionNode *bitfieldWidth;
+	InitializerNode *initializer;
+	bool hasEllipsis;
+	LinkageSpec::Type linkage;
+
+	static UniqueName anonymous;
 };
 
 class StatementNode : public ParseNode {
   public:
-    enum Type { Exp,   If,        Switch,  Case,    Default,  Choose,   Fallthru, 
-		While, Do,        For,
-		Goto,  Continue,  Break,   Return,  Throw,
-		Try,   Catch,     Finally, Asm,
-		Decl
-    };
-
-    StatementNode( void );
-    StatementNode( std::string );
-    StatementNode( Type, ExpressionNode *e = 0, StatementNode *s = 0 );
-    StatementNode( Type, std::string *target );
-    StatementNode( DeclarationNode *decl );
-
-
-    ~StatementNode( void );
-
-    static StatementNode  *newCatchStmt( DeclarationNode *d = 0, StatementNode *s = 0, bool catchRestP = false );
-
-    void set_control( ExpressionNode * );
-    StatementNode * set_block( StatementNode * );
-
-    ExpressionNode *get_control() const ;
-    StatementNode *get_block() const;
-    StatementNode::Type get_type( void ) const;
-
-    StatementNode *add_label( std::string * );
-    std::list<std::string> *get_labels() const;
-
-    void addDeclaration( DeclarationNode *newDecl ) { decl = newDecl; }
-    void setCatchRest( bool newVal ) { isCatchRest = newVal; }
-
-    std::string get_target() const;
-
-    StatementNode *add_controlexp( ExpressionNode * );
-    StatementNode *append_block( StatementNode * );
-    StatementNode *append_last_case( StatementNode * );
-
-    void print( std::ostream &, int indent = 0) const;
-
-    virtual StatementNode *clone() const;
-
-    virtual Statement *build() const;
-  private:
-    static const char *StType[];
-    Type type;
-    ExpressionNode *control;
-    StatementNode *block;
-    std::list<std::string> *labels;
-    std::string *target;				// target label for jump statements
-    DeclarationNode *decl;
-
-    bool isCatchRest;
+	enum Type { Exp,   If,        Switch,  Case,    Default,  Choose,   Fallthru, 
+				While, Do,        For,
+				Goto,  Continue,  Break,   Return,  Throw,
+				Try,   Catch,     Finally, Asm,
+				Decl
+	};
+
+	StatementNode( void );
+	StatementNode( std::string );
+	StatementNode( Type, ExpressionNode *e = 0, StatementNode *s = 0 );
+	StatementNode( Type, std::string *target );
+	StatementNode( DeclarationNode *decl );
+
+
+	~StatementNode( void );
+
+	static StatementNode  *newCatchStmt( DeclarationNode *d = 0, StatementNode *s = 0, bool catchRestP = false );
+
+	void set_control( ExpressionNode * );
+	StatementNode * set_block( StatementNode * );
+
+	ExpressionNode *get_control() const ;
+	StatementNode *get_block() const;
+	StatementNode::Type get_type( void ) const;
+
+	StatementNode *add_label( std::string * );
+	std::list<std::string> *get_labels() const;
+
+	void addDeclaration( DeclarationNode *newDecl ) { decl = newDecl; }
+	void setCatchRest( bool newVal ) { isCatchRest = newVal; }
+
+	std::string get_target() const;
+
+	StatementNode *add_controlexp( ExpressionNode * );
+	StatementNode *append_block( StatementNode * );
+	StatementNode *append_last_case( StatementNode * );
+
+	void print( std::ostream &, int indent = 0) const;
+
+	virtual StatementNode *clone() const;
+
+	virtual Statement *build() const;
+  private:
+	static const char *StType[];
+	Type type;
+	ExpressionNode *control;
+	StatementNode *block;
+	std::list<std::string> *labels;
+	std::string *target;				// target label for jump statements
+	DeclarationNode *decl;
+
+	bool isCatchRest;
 };
 
 class CompoundStmtNode : public StatementNode {
   public:
-    CompoundStmtNode( void );
-    CompoundStmtNode( std::string * );
-    CompoundStmtNode( StatementNode * );
-    ~CompoundStmtNode();
-
-    void add_statement( StatementNode * );
-
-    void print( std::ostream &, int indent = 0 ) const;
-
-    virtual Statement *build() const;
-  private:
-    StatementNode *first, *last;
+	CompoundStmtNode( void );
+	CompoundStmtNode( std::string * );
+	CompoundStmtNode( StatementNode * );
+	~CompoundStmtNode();
+
+	void add_statement( StatementNode * );
+
+	void print( std::ostream &, int indent = 0 ) const;
+
+	virtual Statement *build() const;
+  private:
+	StatementNode *first, *last;
 };
 
 class NullStmtNode : public CompoundStmtNode {
   public:
-    Statement *build() const;
-    void print( std::ostream &, int indent = 0) const;
+	Statement *build() const;
+	void print( std::ostream &, int indent = 0) const;
 };
 
 class InitializerNode : public ParseNode {
   public:
-    InitializerNode( ExpressionNode *, bool aggrp = false,  ExpressionNode *des = 0 );
-    InitializerNode( InitializerNode *, bool aggrp = false, ExpressionNode *des = 0 );
-    ~InitializerNode();
-
-    ExpressionNode *get_expression() const { return expr; }
-
-    InitializerNode *set_designators( ExpressionNode *des ) { designator = des; return this; }
-    ExpressionNode *get_designators() const { return designator; }
-
-    InitializerNode *next_init() const { return kids; }
-
-    void print( std::ostream &, int indent = 0 ) const;
-    void printOneLine( std::ostream & ) const;
-
-    virtual Initializer *build() const;
-  private:
-    ExpressionNode *expr;
-    bool aggregate;
-    ExpressionNode *designator; // may be list
-    InitializerNode *kids;
+	InitializerNode( ExpressionNode *, bool aggrp = false,  ExpressionNode *des = 0 );
+	InitializerNode( InitializerNode *, bool aggrp = false, ExpressionNode *des = 0 );
+	~InitializerNode();
+
+	ExpressionNode *get_expression() const { return expr; }
+
+	InitializerNode *set_designators( ExpressionNode *des ) { designator = des; return this; }
+	ExpressionNode *get_designators() const { return designator; }
+
+	InitializerNode *next_init() const { return kids; }
+
+	void print( std::ostream &, int indent = 0 ) const;
+	void printOneLine( std::ostream & ) const;
+
+	virtual Initializer *build() const;
+  private:
+	ExpressionNode *expr;
+	bool aggregate;
+	ExpressionNode *designator; // may be list
+	InitializerNode *kids;
 };
 
@@ -461,26 +476,24 @@
 
 template< typename SynTreeType, typename NodeType >
-void
-buildList( const NodeType *firstNode, std::list< SynTreeType *> &outputList )
-{
-    SemanticError errors;
-    std::back_insert_iterator< std::list< SynTreeType *> > out( outputList );
-    const NodeType *cur = firstNode;
-
-    while ( cur ) {
-	try {
-	    SynTreeType *result = dynamic_cast< SynTreeType *>( cur->build() );
-	    if ( result ) {
-		*out++ = result;
-	    } else {
-	    } // if
-	} catch( SemanticError &e ) {
-	    errors.append( e );
-	} // try
-	cur = dynamic_cast< NodeType *>( cur->get_link() );
-    } // while
-    if ( !errors.isEmpty() ) {
-	throw errors;
-    } // if
+void buildList( const NodeType *firstNode, std::list< SynTreeType *> &outputList ) {
+	SemanticError errors;
+	std::back_insert_iterator< std::list< SynTreeType *> > out( outputList );
+	const NodeType *cur = firstNode;
+
+	while ( cur ) {
+		try {
+			SynTreeType *result = dynamic_cast< SynTreeType *>( cur->build() );
+			if ( result ) {
+				*out++ = result;
+			} else {
+			} // if
+		} catch( SemanticError &e ) {
+			errors.append( e );
+		} // try
+		cur = dynamic_cast< NodeType *>( cur->get_link() );
+	} // while
+	if ( !errors.isEmpty() ) {
+		throw errors;
+	} // if
 }
 
@@ -497,5 +510,6 @@
 
 // Local Variables: //
-// mode: C++ //
-// compile-command: "gmake" //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
 // End: //
Index: translator/Parser/Parser.cc
===================================================================
--- translator/Parser/Parser.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/Parser.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,8 +1,16 @@
-/*
- * This file is part of the Cforall project
- *
- * $Id: Parser.cc,v 1.6 2002/11/15 20:07:18 rcbilson Exp $
- *
- */
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// Parser.cc -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 14:54:28 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 14:55:59 2015
+// Update Count     : 2
+// 
 
 #include "Parser.h"
@@ -11,13 +19,10 @@
 #include "cfa.tab.h"
 
-/* global variables in cfa.y */
+// global variables in cfa.y
 extern int yyparse(void);
-
 extern int yydebug;
 extern LinkageSpec::Type linkage;
-
 extern TypedefTable typedefTable;
 extern DeclarationNode *theTree;
-/* end of globals */
 
 Parser *Parser::theParser = 0;
@@ -25,49 +30,41 @@
 Parser::Parser(): parseTree( 0 ), parseStatus( 1 ) {}
 
-Parser::~Parser()
-{
-  delete parseTree;
+Parser::~Parser() {
+	delete parseTree;
 }
 
-/* static class method */
-Parser &
-Parser::get_parser()
-{
-  if( theParser == 0 ) {
-    theParser = new Parser;
-  }
-  return *theParser;
+Parser &Parser::get_parser() {
+	if ( theParser == 0 ) {
+		theParser = new Parser;
+	} // if
+	return *theParser;
 }
 
-void 
-Parser::parse( FILE *input )
-{
-  extern FILE *yyin;
-  yyin = input;
-  extern int yylineno;
-  yylineno = 1;
-  typedefTable.enterScope();
-  parseStatus = yyparse();
-  parseTree = theTree;
+void Parser::parse( FILE *input ) {
+	extern FILE *yyin;
+	yyin = input;
+	extern int yylineno;
+	yylineno = 1;
+	typedefTable.enterScope();
+	parseStatus = yyparse();
+	parseTree = theTree;
 }
 
-void
-Parser::set_debug( bool debug )
-{
-  yydebug = debug;
+void Parser::set_debug( bool debug ) {
+	yydebug = debug;
 }
 
-void 
-Parser::set_linkage( LinkageSpec::Type linkage )
-{
-  ::linkage = linkage;
+void Parser::set_linkage( LinkageSpec::Type linkage ) {
+	::linkage = linkage;
 }
 
-
-void 
-Parser::freeTree()
-{
-  delete parseTree;
-  parseTree = 0;
+void Parser::freeTree() {
+	delete parseTree;
+	parseTree = 0;
 }
 
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/Parser.h
===================================================================
--- translator/Parser/Parser.h	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/Parser.h	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,10 +1,16 @@
-/*
- * This file is part of the Cforall project
- *
- * A singleton class to encapsulate the bison-generated parser
- *
- * $Id: Parser.h,v 1.4 2002/09/09 16:47:14 rcbilson Exp $
- *
- */
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// Parser.h -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 14:56:50 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 14:58:56 2015
+// Update Count     : 2
+//
 
 #ifndef PARSER_H
@@ -16,31 +22,35 @@
 #include "LinkageSpec.h"
 
-class Parser
-{
-public:
-  static Parser &get_parser();
+class Parser {
+  public:
+	static Parser &get_parser();
 
-  /* do the actual parse */
-  void parse( FILE *input );
+	// do the actual parse
+	void parse( FILE *input );
 
-  /* accessors to return the result of the parse */
-  DeclarationNode *get_parseTree() const { return parseTree; }
-  int get_parseStatus() const { return parseStatus; }
+	// accessors to return the result of the parse
+	DeclarationNode *get_parseTree() const { return parseTree; }
+	int get_parseStatus() const { return parseStatus; }
 
-  /* mutators to control parse options */
-  void set_debug( bool debug );
-  void set_linkage( LinkageSpec::Type linkage );
+	// mutators to control parse options
+	void set_debug( bool debug );
+	void set_linkage( LinkageSpec::Type linkage );
 
-  /* free the parse tree without actually destroying the parser */
-  void freeTree();
+	// free the parse tree without actually destroying the parser
+	void freeTree();
 
-  ~Parser();
-
-private:
-  Parser();
-  static Parser *theParser;
-  DeclarationNode *parseTree;
-  int parseStatus;
+	~Parser();
+  private:
+	Parser();
+	static Parser *theParser;
+	DeclarationNode *parseTree;
+	int parseStatus;
 };
 
-#endif /* #ifndef PARSER_H */
+#endif // PARSER_H
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/StatementNode.cc
===================================================================
--- translator/Parser/StatementNode.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/StatementNode.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,3 +1,17 @@
-/* -*- C++ -*- */
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// StatementNode.cc -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 14:59:41 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 15:10:45 2015
+// Update Count     : 7
+//
+
 #include <list>
 #include <algorithm>
@@ -12,426 +26,379 @@
 using namespace std;
 
-const char *StatementNode::StType[] =
-  { "Exp",   "If",       "Switch", "Case",    "Default",  "Choose",   "Fallthru", 
-    "While", "Do",       "For", 
-    "Goto",  "Continue", "Break",  "Return",  "Throw",
-    "Try",   "Catch",    "Finally", "Asm",
-    "Decl"
-  };
-
-StatementNode::StatementNode(void) : 
-  ParseNode(), control( 0 ), block( 0 ), labels( 0 ), target( 0 ), decl( 0 ), isCatchRest ( false ) {}
-
-StatementNode::StatementNode(string name_) : 
-  ParseNode(name_), control( 0 ), block( 0 ), labels( 0 ), target( 0 ), decl( 0 ), isCatchRest ( false ) {}
-
-StatementNode::StatementNode( DeclarationNode *decl ) :
-  type( Decl ), control( 0 ), block( 0 ), labels( 0 ), target( 0 ), isCatchRest ( false )
-{
-  if( decl ) {
-    if( DeclarationNode *agg = decl->extractAggregate() ) {
-      this->decl = agg;
-      StatementNode *nextStmt = new StatementNode;
-      nextStmt->type = Decl;
-      nextStmt->decl = decl;
-      next = nextStmt;
-      if( decl->get_link() ) {
-        next->set_next( new StatementNode( dynamic_cast< DeclarationNode* >( decl->get_link() ) ) );
-        decl->set_next( 0 );
-      }
-    } else {
-      if( decl->get_link() ) {
-        next = new StatementNode( dynamic_cast< DeclarationNode* >( decl->get_link() ) );
-        decl->set_next( 0 );
-      }
-      this->decl = decl;
-    }
-  }
-}
-
-StatementNode::StatementNode(Type t, ExpressionNode *ctrl_label, StatementNode *block_ ) :
-  type(t), control(ctrl_label), block(block_), labels( 0 ), target( 0 ), decl( 0 ), isCatchRest ( false )
-{
-  if (t == Default)
-    control = 0;
+const char *StatementNode::StType[] = {
+	"Exp",   "If",       "Switch", "Case",    "Default",  "Choose",   "Fallthru", 
+	"While", "Do",       "For", 
+	"Goto",  "Continue", "Break",  "Return",  "Throw",
+	"Try",   "Catch",    "Finally", "Asm",
+	"Decl"
+};
+
+StatementNode::StatementNode() : ParseNode(), control( 0 ), block( 0 ), labels( 0 ), target( 0 ), decl( 0 ), isCatchRest ( false ) {}
+
+StatementNode::StatementNode( string name_) : ParseNode( name_), control( 0 ), block( 0 ), labels( 0 ), target( 0 ), decl( 0 ), isCatchRest ( false ) {}
+
+StatementNode::StatementNode( DeclarationNode *decl ) : type( Decl ), control( 0 ), block( 0 ), labels( 0 ), target( 0 ), isCatchRest ( false ) {
+	if ( decl ) {
+		if ( DeclarationNode *agg = decl->extractAggregate() ) {
+			this->decl = agg;
+			StatementNode *nextStmt = new StatementNode;
+			nextStmt->type = Decl;
+			nextStmt->decl = decl;
+			next = nextStmt;
+			if ( decl->get_link() ) {
+				next->set_next( new StatementNode( dynamic_cast< DeclarationNode* >( decl->get_link() ) ) );
+				decl->set_next( 0 );
+			}
+		} else {
+			if ( decl->get_link() ) {
+				next = new StatementNode( dynamic_cast< DeclarationNode* >( decl->get_link() ) );
+				decl->set_next( 0 );
+			}
+			this->decl = decl;
+		}
+	}
+}
+
+StatementNode::StatementNode( Type t, ExpressionNode *ctrl_label, StatementNode *block_ ) :
+		type( t ), control( ctrl_label ), block( block_), labels( 0 ), target( 0 ), decl( 0 ), isCatchRest ( false ) {
+	if ( t == Default )
+		control = 0;
 } 
 
-StatementNode::StatementNode(Type t, string *_target) :
-  type(t), control(0), block(0),   labels( 0 ), target(_target), decl( 0 ), isCatchRest ( false ) {}
-
-StatementNode::~StatementNode(void){
-  delete control;
-  delete block;
-  delete labels;
-  delete target;
-  delete decl;
-}
-
-StatementNode * StatementNode::newCatchStmt(DeclarationNode *d, StatementNode *s, bool catchRestP ) {
-  StatementNode *ret = new StatementNode( StatementNode::Catch, 0, s ); 
-  ret->addDeclaration( d );
-  ret->setCatchRest( catchRestP );
-
-  return ret;
+StatementNode::StatementNode( Type t, string *_target ) :
+		type( t ), control( 0 ), block( 0 ),   labels( 0 ), target(_target ), decl( 0 ), isCatchRest ( false ) {}
+
+StatementNode::~StatementNode() {
+	delete control;
+	delete block;
+	delete labels;
+	delete target;
+	delete decl;
+}
+
+StatementNode * StatementNode::newCatchStmt( DeclarationNode *d, StatementNode *s, bool catchRestP ) {
+	StatementNode *ret = new StatementNode( StatementNode::Catch, 0, s ); 
+	ret->addDeclaration( d );
+	ret->setCatchRest( catchRestP );
+
+	return ret;
 }
 
 std::string StatementNode::get_target() const{
-  if(target)
-    return *target;
-
-  return string("");
-}
-
-StatementNode *
-StatementNode::clone() const
-{
-  StatementNode *newnode = new StatementNode( type, maybeClone( control ), maybeClone( block ) );
-  if( target ) {
-    newnode->target = new string( *target );
-  } else {
-    newnode->target = 0;
-  }
-  newnode->decl = maybeClone( decl );
-  return newnode;
-}
-
-void StatementNode::set_control(ExpressionNode *c){
-  control = c;
-}
-
-StatementNode * StatementNode::set_block(StatementNode *b){
-  block = b;
-
-  return this;
-}
-
-ExpressionNode *StatementNode::get_control(void) const {
-  return control;
-}
-
-StatementNode *StatementNode::get_block(void) const {
-  return block;
-}
-
-StatementNode::Type StatementNode::get_type(void) const {
-  return type;
-}
-
-StatementNode *StatementNode::add_label(std::string *l){
-  if(l != 0){
-    if(labels == 0)
-      labels = new std::list<std::string>();
-
-    labels->push_front(*l); 
-    delete l;
-  }
-
-  return this;
-}
-
-std::list<std::string> *StatementNode::get_labels() const
-{  return labels; }
-
-StatementNode *StatementNode::add_controlexp(ExpressionNode *e){
-
-  if(control && e)
-    control->add_to_list(e); // xxx - check this
-
-  return this;
-}
-
-StatementNode *StatementNode::append_block(StatementNode *stmt){
-  if( stmt != 0) {
-    if( block == 0 )
-      block = stmt;
-    else
-      block->set_link(stmt);
-  }
-  return this;
-}
-
-
-StatementNode *StatementNode::append_last_case(StatementNode *stmt){
-  if( stmt != 0 ) {
-    StatementNode *next = (StatementNode *)get_link();
-    if ( next && ( next->get_type() == StatementNode::Case || next->get_type() == StatementNode::Default) )
-      next->append_last_case ( stmt );
-    else
-      if( block == 0 )
-	block = stmt;
-      else
-	block->set_link(stmt);
-  }
-
-  return this;
+	if ( target )
+		return *target;
+
+	return string("");
+}
+
+StatementNode * StatementNode::clone() const {
+	StatementNode *newnode = new StatementNode( type, maybeClone( control ), maybeClone( block ) );
+	if ( target ) {
+		newnode->target = new string( *target );
+	} else {
+		newnode->target = 0;
+	}
+	newnode->decl = maybeClone( decl );
+	return newnode;
+}
+
+void StatementNode::set_control( ExpressionNode *c ) {
+	control = c;
+}
+
+StatementNode * StatementNode::set_block( StatementNode *b ) {
+	block = b;
+
+	return this;
+}
+
+ExpressionNode *StatementNode::get_control() const {
+	return control;
+}
+
+StatementNode *StatementNode::get_block() const {
+	return block;
+}
+
+StatementNode::Type StatementNode::get_type() const {
+	return type;
+}
+
+StatementNode *StatementNode::add_label( std::string *l ) {
+	if ( l != 0 ) {
+		if ( labels == 0 )
+			labels = new std::list<std::string>();
+
+		labels->push_front(*l ); 
+		delete l;
+	}
+	return this;
+}
+
+std::list<std::string> *StatementNode::get_labels() const { return labels; }
+
+StatementNode *StatementNode::add_controlexp( ExpressionNode *e ) {
+	if ( control && e )
+		control->add_to_list( e ); // xxx - check this
+
+	return this;
+}
+
+StatementNode *StatementNode::append_block( StatementNode *stmt ) {
+	if ( stmt != 0 ) {
+		if ( block == 0 )
+			block = stmt;
+		else
+			block->set_link( stmt );
+	}
+	return this;
+}
+
+StatementNode *StatementNode::append_last_case( StatementNode *stmt ) {
+	if ( stmt != 0 ) {
+		StatementNode *next = ( StatementNode *)get_link();
+		if ( next && ( next->get_type() == StatementNode::Case || next->get_type() == StatementNode::Default ) )
+			next->append_last_case ( stmt );
+		else
+			if ( block == 0 )
+				block = stmt;
+			else
+				block->set_link( stmt );
+	}
+	return this;
 }
 
 void StatementNode::print( std::ostream &os, int indent ) const {
-
-  if(labels != 0)
-    if(!labels->empty()){
-      std::list<std::string>::const_iterator i;
-
-      os << '\r' << string(indent, ' ');
-      for( i = labels->begin(); i != labels->end(); i++ )
-	os << *i << ":";
-      os << endl;
-    }
-
-  switch( type ) {
-  case Decl:
-    decl->print( os, indent );
-    break;
-  
-  case Exp:
-    if( control ) {
-      os << string( indent, ' ' );
-      control->print( os, indent );
-      os << endl;
-    } else 
-      os << string( indent, ' ' ) << "Null Statement" << endl;
-    break;
-
-  default:
-    os << '\r' << string(indent, ' ') << StatementNode::StType[type] << endl;
-
-    if   ( type == Catch ) {
-      if( decl ){
-	os << '\r' << string( indent + ParseNode::indent_by, ' ' ) << "Declaration: " << endl;
-	decl->print( os, indent + 2*ParseNode::indent_by);
-      } else if ( isCatchRest ) {
-	os << '\r' << string( indent + ParseNode::indent_by, ' ' ) << "Catches the rest " << endl;
-      } else {
-	; // should never reach here
-      }
-    }
-
-    if( control ){
-      os << '\r' << string( indent + ParseNode::indent_by, ' ' ) << "Expression: " << endl;
-      control->printList( os, indent + 2*ParseNode::indent_by);
-    }
-
-    if( block ){
-      os << '\r' << string( indent + ParseNode::indent_by, ' ' ) << "Branches of execution: " << endl;
-      block->printList( os, indent + 2*ParseNode::indent_by);  
-    }
-
-    if( target ){
-      os << '\r' << string( indent + ParseNode::indent_by, ' ' ) << "Target: " << get_target() << endl;
-    }
-
-    break;
-  }
+	if ( labels != 0 )
+		if (!labels->empty()) {
+			std::list<std::string>::const_iterator i;
+
+			os << '\r' << string( indent, ' ');
+			for( i = labels->begin(); i != labels->end(); i++ )
+				os << *i << ":";
+			os << endl;
+		}
+
+	switch( type ) {
+	  case Decl:
+		decl->print( os, indent );
+		break;
+	  case Exp:
+		if ( control ) {
+			os << string( indent, ' ' );
+			control->print( os, indent );
+			os << endl;
+		} else 
+			os << string( indent, ' ' ) << "Null Statement" << endl;
+		break;
+	  default:
+		os << '\r' << string( indent, ' ') << StatementNode::StType[type] << endl;
+		if ( type == Catch ) {
+			if ( decl ) {
+				os << '\r' << string( indent + ParseNode::indent_by, ' ' ) << "Declaration: " << endl;
+				decl->print( os, indent + 2*ParseNode::indent_by );
+			} else if ( isCatchRest ) {
+				os << '\r' << string( indent + ParseNode::indent_by, ' ' ) << "Catches the rest " << endl;
+			} else {
+				; // should never reach here
+			}
+		}
+		if ( control ) {
+			os << '\r' << string( indent + ParseNode::indent_by, ' ' ) << "Expression: " << endl;
+			control->printList( os, indent + 2*ParseNode::indent_by );
+		}
+		if ( block ) {
+			os << '\r' << string( indent + ParseNode::indent_by, ' ' ) << "Branches of execution: " << endl;
+			block->printList( os, indent + 2*ParseNode::indent_by );  
+		}
+		if ( target ) {
+			os << '\r' << string( indent + ParseNode::indent_by, ' ' ) << "Target: " << get_target() << endl;
+		}
+		break;
+	}
 }
 
 Statement *StatementNode::build() const {
-
-  std::list<Statement *> branches;
-  std::list<Expression *> exps;
-  std::list<Label> labs;
-
-  if(labels != 0){
-    std::back_insert_iterator< std::list<Label> > lab_it(labs);
-    copy(labels->begin(), labels->end(), lab_it);
-  }
-
-  // try {
-  buildList<Statement, StatementNode>(get_block(), branches);
-  
-  switch( type ) {
-  case Decl:
-    return new DeclStmt( labs, maybeBuild< Declaration >( decl ) );
-
-  case Exp:
-    {
-      Expression *e = maybeBuild< Expression >( get_control() );
-
-      if(e)
-        return new ExprStmt( labs, e );
-      else
-        return new NullStmt( labs );
-    }
-
-  case If:
-    {
-      Statement *thenb = 0, *elseb = 0;
-
-      assert( branches.size() >= 1 );
-
-      thenb = branches.front();  branches.pop_front();
-      if(!branches.empty())
-	{ elseb = branches.front();  branches.pop_front(); }
-
-      return new IfStmt( labs, notZeroExpr( get_control()->build() ), thenb, elseb);
-    }
-
-  case While:
-    assert(branches.size() == 1);
-    return new WhileStmt( labs, notZeroExpr( get_control()->build() ), branches.front() );
-
-  case Do:
-    assert(branches.size() == 1);
-    return new WhileStmt( labs, notZeroExpr( get_control()->build() ), branches.front(), true );
-    
-  case For:
-    {
-      assert(branches.size() == 1);
-
-      ForCtlExprNode *ctl = dynamic_cast<ForCtlExprNode *>(get_control());
-      assert(ctl != 0);
-
-      Statement *stmt = 0;
-      if(ctl->get_init() != 0)
-	stmt = ctl->get_init()->build();
-
-      Expression *cond = 0;
-      if(ctl->get_condition() != 0)
-	cond = notZeroExpr( ctl->get_condition()->build() );
-
-      Expression *incr = 0;
-      if(ctl->get_change() != 0)
-	incr = ctl->get_change()->build();
-
-      return new ForStmt( labs, stmt, cond, incr, branches.front() );
-    }
-
-  case Switch:
-    // try{
-    return new SwitchStmt( labs, get_control()->build(), branches );
-
-  case Choose:
-    return new ChooseStmt( labs, get_control()->build(), branches );
-
-  case Fallthru:
-    return new FallthruStmt( labs );
-
-  case Case: 
-    return new CaseStmt( labs, get_control()->build(), branches);
-
-  case Default:
-    return new CaseStmt( labs, 0, branches, true);
-
-  case Goto:
-    {
-      if (get_target() == "")  { // computed goto
-	assert( get_control() != 0 );
-	return new BranchStmt( labs, get_control()->build(), BranchStmt::Goto );
-      }
-
-      return new BranchStmt( labs, get_target(), BranchStmt::Goto);
-    }
-
-  case Break:
-    return new BranchStmt( labs, get_target(), BranchStmt::Break);
-
-  case Continue:
-    return new BranchStmt( labs, get_target(), BranchStmt::Continue);
-
-  case Return:
-  case Throw :
-    buildList( get_control(), exps );
-    if( exps.size() ==0 )
-      return new ReturnStmt( labs, 0, type == Throw );
-    if( exps.size() > 0 )
-      return new ReturnStmt( labs, exps.back(), type == Throw );
-
-  case Try:
-    {
-      assert( branches.size() >= 0 );
-      CompoundStmt *tryBlock = dynamic_cast<CompoundStmt *>(branches.front());
-      branches.pop_front();
-      FinallyStmt *finallyBlock = 0;
-      if( (finallyBlock = dynamic_cast<FinallyStmt *>(branches.back())) ) {
-	branches.pop_back();
-      }
-      return new TryStmt( labs, tryBlock, branches, finallyBlock );
-    }
-
-  case Catch:
-    {
-      assert( branches.size() == 1 );
-
-      return new CatchStmt( labs, maybeBuild< Declaration >( decl ), branches.front(), isCatchRest );
-    }
-
-  case Finally:
-    {
-      assert( branches.size() == 1 );
-      CompoundStmt *block = dynamic_cast<CompoundStmt *>( branches.front() );
-      assert( block != 0 );
-
-      return new FinallyStmt( labs, block );
-    }
-
-  default:
-    // shouldn't be here
-    return 0;
-  }
-
-  // shouldn't be here
-}
-
-CompoundStmtNode::CompoundStmtNode(void)
-  : first( 0 ), last( 0 )
-{
-}
-
-CompoundStmtNode::CompoundStmtNode(string *name_)
-  : StatementNode(*name_), first( 0 ), last( 0 )
-{
-}
-
-CompoundStmtNode::CompoundStmtNode(StatementNode *stmt): first(stmt)
-{
-  if( first ) {
-    last = (StatementNode *)(stmt->get_last());
-  } else {
-    last = 0;
-  }
-}
-
-CompoundStmtNode::~CompoundStmtNode()
-{
-  delete first;
-}
-
-void CompoundStmtNode::add_statement(StatementNode *stmt) {
-  if(stmt != 0){
-    last->set_link(stmt);
-    last = (StatementNode *)(stmt->get_link());
-  }
-}
-
-void CompoundStmtNode::print(ostream &os, int indent) const {
-  if( first ) {
-    first->printList( os, indent+2 );
-  }
+	std::list<Statement *> branches;
+	std::list<Expression *> exps;
+	std::list<Label> labs;
+
+	if ( labels != 0 ) {
+		std::back_insert_iterator< std::list<Label> > lab_it( labs );
+		copy( labels->begin(), labels->end(), lab_it );
+	}
+
+	// try {
+	buildList<Statement, StatementNode>( get_block(), branches );
+
+	switch( type ) {
+	  case Decl:
+		return new DeclStmt( labs, maybeBuild< Declaration >( decl ) );
+	  case Exp:
+		{
+			Expression *e = maybeBuild< Expression >( get_control() );
+
+			if ( e )
+				return new ExprStmt( labs, e );
+			else
+				return new NullStmt( labs );
+		}
+	  case If:
+		{
+			Statement *thenb = 0, *elseb = 0;
+			assert( branches.size() >= 1 );
+
+			thenb = branches.front();
+			branches.pop_front();
+			if ( !branches.empty() ) {
+				elseb = branches.front();
+				branches.pop_front();
+			}
+			return new IfStmt( labs, notZeroExpr( get_control()->build() ), thenb, elseb );
+		}
+	  case While:
+		assert( branches.size() == 1 );
+		return new WhileStmt( labs, notZeroExpr( get_control()->build() ), branches.front() );
+	  case Do:
+		assert( branches.size() == 1 );
+		return new WhileStmt( labs, notZeroExpr( get_control()->build() ), branches.front(), true );
+	  case For:
+		{
+			assert( branches.size() == 1 );
+
+			ForCtlExprNode *ctl = dynamic_cast<ForCtlExprNode *>( get_control() );
+			assert( ctl != 0 );
+
+			Statement *stmt = 0;
+			if ( ctl->get_init() != 0 )
+				stmt = ctl->get_init()->build();
+
+			Expression *cond = 0;
+			if ( ctl->get_condition() != 0 )
+				cond = notZeroExpr( ctl->get_condition()->build() );
+
+			Expression *incr = 0;
+			if ( ctl->get_change() != 0 )
+				incr = ctl->get_change()->build();
+
+			return new ForStmt( labs, stmt, cond, incr, branches.front() );
+		}
+	  case Switch:
+		return new SwitchStmt( labs, get_control()->build(), branches );
+	  case Choose:
+		return new ChooseStmt( labs, get_control()->build(), branches );
+	  case Fallthru:
+		return new FallthruStmt( labs );
+	  case Case: 
+		return new CaseStmt( labs, get_control()->build(), branches );
+	  case Default:
+		return new CaseStmt( labs, 0, branches, true );
+	  case Goto:
+		{
+			if ( get_target() == "" ) {					// computed goto
+				assert( get_control() != 0 );
+				return new BranchStmt( labs, get_control()->build(), BranchStmt::Goto );
+			}
+
+			return new BranchStmt( labs, get_target(), BranchStmt::Goto );
+		}
+	  case Break:
+		return new BranchStmt( labs, get_target(), BranchStmt::Break );
+	  case Continue:
+		return new BranchStmt( labs, get_target(), BranchStmt::Continue );
+	  case Return:
+	  case Throw :
+		buildList( get_control(), exps );
+		if ( exps.size() ==0 )
+			return new ReturnStmt( labs, 0, type == Throw );
+		if ( exps.size() > 0 )
+			return new ReturnStmt( labs, exps.back(), type == Throw );
+	  case Try:
+		{
+			assert( branches.size() >= 0 );
+			CompoundStmt *tryBlock = dynamic_cast<CompoundStmt *>( branches.front());
+			branches.pop_front();
+			FinallyStmt *finallyBlock = 0;
+			if ( ( finallyBlock = dynamic_cast<FinallyStmt *>( branches.back())) ) {
+				branches.pop_back();
+			}
+			return new TryStmt( labs, tryBlock, branches, finallyBlock );
+		}
+	  case Catch:
+		{
+			assert( branches.size() == 1 );
+
+			return new CatchStmt( labs, maybeBuild< Declaration >( decl ), branches.front(), isCatchRest );
+		}
+	  case Finally:
+		{
+			assert( branches.size() == 1 );
+			CompoundStmt *block = dynamic_cast<CompoundStmt *>( branches.front() );
+			assert( block != 0 );
+
+			return new FinallyStmt( labs, block );
+		}
+	  default:
+		// shouldn't be here
+		return 0;
+	}
+}
+
+CompoundStmtNode::CompoundStmtNode() : first( 0 ), last( 0 ) {
+}
+
+CompoundStmtNode::CompoundStmtNode( string *name_) : StatementNode(*name_), first( 0 ), last( 0 ) {
+}
+
+CompoundStmtNode::CompoundStmtNode( StatementNode *stmt ): first( stmt ) {
+	if ( first ) {
+		last = ( StatementNode *)( stmt->get_last());
+	} else {
+		last = 0;
+	}
+}
+
+CompoundStmtNode::~CompoundStmtNode() {
+	delete first;
+}
+
+void CompoundStmtNode::add_statement( StatementNode *stmt ) {
+	if ( stmt != 0 ) {
+		last->set_link( stmt );
+		last = ( StatementNode *)( stmt->get_link());
+	}
+}
+
+void CompoundStmtNode::print( ostream &os, int indent ) const {
+	if ( first ) {
+		first->printList( os, indent+2 );
+	}
 }
 
 Statement *CompoundStmtNode::build() const {
-
-  std::list<Label> labs;
-  std::list<std::string> *labels = get_labels();
-
-  if(labels != 0){
-    std::back_insert_iterator< std::list<Label> > lab_it(labs);
-    copy(labels->begin(), labels->end(), lab_it);
-  }
-
-  CompoundStmt *cs = new CompoundStmt( labs );
-  buildList( first, cs->get_kids() );
-  return cs;
-}
-
-void NullStmtNode::print(ostream &os, int indent) const {
-  os << "\r" << string(indent, ' ') << "Null Statement:" << endl;
+	std::list<Label> labs;
+	std::list<std::string> *labels = get_labels();
+
+	if ( labels != 0 ) {
+		std::back_insert_iterator< std::list<Label> > lab_it( labs );
+		copy( labels->begin(), labels->end(), lab_it );
+	}
+
+	CompoundStmt *cs = new CompoundStmt( labs );
+	buildList( first, cs->get_kids() );
+	return cs;
+}
+
+void NullStmtNode::print( ostream &os, int indent ) const {
+	os << "\r" << string( indent, ' ') << "Null Statement:" << endl;
 }
 
 Statement *NullStmtNode::build() const { 
-  return new NullStmt;
+	return new NullStmt;
 }
 
 // Local Variables: //
-// mode: C++                //
-// compile-command: "gmake -f ../Makefile" //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
 // End: //
Index: translator/Parser/TypeData.cc
===================================================================
--- translator/Parser/TypeData.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/TypeData.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// TypeData.cc -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 15:12:51 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 15:17:56 2015
+// Update Count     : 4
+//
+
 #include <cassert>
 #include <algorithm>
@@ -9,830 +24,802 @@
 #include "SynTree/Statement.h"
 
-
 TypeData::TypeData( Kind k ) : kind( k ), base( 0 ), forall( 0 ) {
-    switch ( kind ) {
-      case Unknown:
-      case Pointer:
-      case EnumConstant:
-	// nothing else to initialize
-	break;
-      case Basic:
-	basic = new Basic_t;
-	break;
-      case Array:
-	array = new Array_t;
-	array->dimension = 0;
-	array->isVarLen = false;
-	array->isStatic = false;
-	break;
-      case Function:
-	function = new Function_t;
-	function->params = 0;
-	function->idList = 0;
-	function->oldDeclList = 0;
-	function->body = 0;
-	function->hasBody = false;
-	function->newStyle = false;
-	break;
-      case Aggregate:
-	aggregate = new Aggregate_t;
-	aggregate->params = 0;
-	aggregate->actuals = 0;
-	aggregate->members = 0;
-	break;
-      case AggregateInst:
-	aggInst = new AggInst_t;
-	aggInst->aggregate = 0;
-	aggInst->params = 0;
-	break;
-      case Enum:
-	enumeration = new Enumeration_t;
-	enumeration->constants = 0;
-	break;
-      case Symbolic:
-      case SymbolicInst:
-	symbolic = new Symbolic_t;
-	symbolic->params = 0;
-	symbolic->actuals = 0;
-	symbolic->assertions = 0;
-	break;
-      case Variable:
-	variable = new Variable_t;
-	variable->tyClass = DeclarationNode::Type;
-	variable->assertions = 0;
-	break;
-      case Tuple:
-	tuple = new Tuple_t;
-	tuple->members = 0;
-	break;
-  
-      case Typeof:
-	typeexpr = new Typeof_t;
-	typeexpr->expr = 0;
-	break;
-  
-      case Attr:
-	attr = new Attr_t;
-	attr->expr = 0;
-	attr->type = 0;
-	break;
-    }
+	switch ( kind ) {
+	  case Unknown:
+	  case Pointer:
+	  case EnumConstant:
+		// nothing else to initialize
+		break;
+	  case Basic:
+		basic = new Basic_t;
+		break;
+	  case Array:
+		array = new Array_t;
+		array->dimension = 0;
+		array->isVarLen = false;
+		array->isStatic = false;
+		break;
+	  case Function:
+		function = new Function_t;
+		function->params = 0;
+		function->idList = 0;
+		function->oldDeclList = 0;
+		function->body = 0;
+		function->hasBody = false;
+		function->newStyle = false;
+		break;
+	  case Aggregate:
+		aggregate = new Aggregate_t;
+		aggregate->params = 0;
+		aggregate->actuals = 0;
+		aggregate->members = 0;
+		break;
+	  case AggregateInst:
+		aggInst = new AggInst_t;
+		aggInst->aggregate = 0;
+		aggInst->params = 0;
+		break;
+	  case Enum:
+		enumeration = new Enumeration_t;
+		enumeration->constants = 0;
+		break;
+	  case Symbolic:
+	  case SymbolicInst:
+		symbolic = new Symbolic_t;
+		symbolic->params = 0;
+		symbolic->actuals = 0;
+		symbolic->assertions = 0;
+		break;
+	  case Variable:
+		variable = new Variable_t;
+		variable->tyClass = DeclarationNode::Type;
+		variable->assertions = 0;
+		break;
+	  case Tuple:
+		tuple = new Tuple_t;
+		tuple->members = 0;
+		break;
+	  case Typeof:
+		typeexpr = new Typeof_t;
+		typeexpr->expr = 0;
+		break;
+	  case Attr:
+		attr = new Attr_t;
+		attr->expr = 0;
+		attr->type = 0;
+		break;
+	}
 }
 
 TypeData::~TypeData() {
-    delete base;
-    delete forall;
-
-    switch ( kind ) {
-      case Unknown:
-      case Pointer:
-      case EnumConstant:
-	// nothing to destroy
-	break;
-      case Basic:
-	delete basic;
-	break;
-      case Array:
-	delete array->dimension;
-	delete array;
-	break;
-      case Function:
-	delete function->params;
-	delete function->idList;
-	delete function->oldDeclList;
-	delete function->body;
-	delete function;
-	break;
-      case Aggregate:
-	delete aggregate->params;
-	delete aggregate->actuals;
-	delete aggregate->members;
-	delete aggregate;
-	break;
-      case AggregateInst:
-	delete aggInst->aggregate;
-	delete aggInst->params;
-	delete aggInst;
-	break;
-      case Enum:
-	delete enumeration->constants;
-	delete enumeration;
-	break;
-      case Symbolic:
-      case SymbolicInst:
-	delete symbolic->params;
-	delete symbolic->actuals;
-	delete symbolic->assertions;
-	delete symbolic;
-	break;
-      case Variable:
-	delete variable->assertions;
-	delete variable;
-	break;
-      case Tuple:
-	delete tuple->members;
-	delete tuple;
-	break;
-  
-      case Typeof:
-	delete typeexpr->expr;
-	delete typeexpr;
-	break;
-  
-      case Attr:
-	delete attr->expr;
-	delete attr->type;
-	delete attr;
-	break;
-    }
+	delete base;
+	delete forall;
+
+	switch ( kind ) {
+	  case Unknown:
+	  case Pointer:
+	  case EnumConstant:
+		// nothing to destroy
+		break;
+	  case Basic:
+		delete basic;
+		break;
+	  case Array:
+		delete array->dimension;
+		delete array;
+		break;
+	  case Function:
+		delete function->params;
+		delete function->idList;
+		delete function->oldDeclList;
+		delete function->body;
+		delete function;
+		break;
+	  case Aggregate:
+		delete aggregate->params;
+		delete aggregate->actuals;
+		delete aggregate->members;
+		delete aggregate;
+		break;
+	  case AggregateInst:
+		delete aggInst->aggregate;
+		delete aggInst->params;
+		delete aggInst;
+		break;
+	  case Enum:
+		delete enumeration->constants;
+		delete enumeration;
+		break;
+	  case Symbolic:
+	  case SymbolicInst:
+		delete symbolic->params;
+		delete symbolic->actuals;
+		delete symbolic->assertions;
+		delete symbolic;
+		break;
+	  case Variable:
+		delete variable->assertions;
+		delete variable;
+		break;
+	  case Tuple:
+		delete tuple->members;
+		delete tuple;
+		break;
+	  case Typeof:
+		delete typeexpr->expr;
+		delete typeexpr;
+		break;
+	  case Attr:
+		delete attr->expr;
+		delete attr->type;
+		delete attr;
+		break;
+	}
 }
 
 TypeData *TypeData::clone() const {
-    TypeData *newtype = new TypeData( kind );
-    newtype->qualifiers = qualifiers;
-    newtype->base = maybeClone( base );
-    newtype->forall = maybeClone( forall );
-
-    switch ( kind ) {
-      case Unknown:
-      case EnumConstant:
-      case Pointer:
-	// nothing else to copy
-	break;
-      case Basic:
-	newtype->basic->typeSpec = basic->typeSpec;
-	newtype->basic->modifiers = basic->modifiers;
-	break;
-      case Array:
-	newtype->array->dimension = maybeClone( array->dimension );
-	newtype->array->isVarLen = array->isVarLen;
-	newtype->array->isStatic = array->isStatic;
-	break;
-      case Function:
-	newtype->function->params = maybeClone( function->params );
-	newtype->function->idList = maybeClone( function->idList );
-	newtype->function->oldDeclList = maybeClone( function->oldDeclList );
-	newtype->function->body = maybeClone( function->body );
-	newtype->function->hasBody = function->hasBody;
-	newtype->function->newStyle = function->newStyle;
-	break;
-      case Aggregate:
-	newtype->aggregate->params = maybeClone( aggregate->params );
-	newtype->aggregate->actuals = maybeClone( aggregate->actuals );
-	newtype->aggregate->members = maybeClone( aggregate->members );
-	newtype->aggregate->name = aggregate->name;
-	newtype->aggregate->kind = aggregate->kind;
-	break;
-      case AggregateInst:
-	newtype->aggInst->aggregate = maybeClone( aggInst->aggregate );
-	newtype->aggInst->params = maybeClone( aggInst->params );
-	break;
-      case Enum:
-	newtype->enumeration->name = enumeration->name;
-	newtype->enumeration->constants = maybeClone( enumeration->constants );
-	break;
-      case Symbolic:
-      case SymbolicInst:
-	newtype->symbolic->params = maybeClone( symbolic->params );
-	newtype->symbolic->actuals = maybeClone( symbolic->actuals );
-	newtype->symbolic->assertions = maybeClone( symbolic->assertions );
-	newtype->symbolic->isTypedef = symbolic->isTypedef;
-	newtype->symbolic->name = symbolic->name;
-	break;
-      case Variable:
-	newtype->variable->assertions = maybeClone( variable->assertions );
-	newtype->variable->name = variable->name;
-	newtype->variable->tyClass = variable->tyClass;
-	break;
-      case Tuple:
-	newtype->tuple->members = maybeClone( tuple->members );
-	break;
-    
-      case Typeof:
-	newtype->typeexpr->expr = maybeClone( typeexpr->expr );
-	break;
-  
-      case Attr:
-	newtype->attr->expr = maybeClone( attr->expr );
-	newtype->attr->type = maybeClone( attr->type );
-	break;
-    }
-    return newtype;
+	TypeData *newtype = new TypeData( kind );
+	newtype->qualifiers = qualifiers;
+	newtype->base = maybeClone( base );
+	newtype->forall = maybeClone( forall );
+
+	switch ( kind ) {
+	  case Unknown:
+	  case EnumConstant:
+	  case Pointer:
+		// nothing else to copy
+		break;
+	  case Basic:
+		newtype->basic->typeSpec = basic->typeSpec;
+		newtype->basic->modifiers = basic->modifiers;
+		break;
+	  case Array:
+		newtype->array->dimension = maybeClone( array->dimension );
+		newtype->array->isVarLen = array->isVarLen;
+		newtype->array->isStatic = array->isStatic;
+		break;
+	  case Function:
+		newtype->function->params = maybeClone( function->params );
+		newtype->function->idList = maybeClone( function->idList );
+		newtype->function->oldDeclList = maybeClone( function->oldDeclList );
+		newtype->function->body = maybeClone( function->body );
+		newtype->function->hasBody = function->hasBody;
+		newtype->function->newStyle = function->newStyle;
+		break;
+	  case Aggregate:
+		newtype->aggregate->params = maybeClone( aggregate->params );
+		newtype->aggregate->actuals = maybeClone( aggregate->actuals );
+		newtype->aggregate->members = maybeClone( aggregate->members );
+		newtype->aggregate->name = aggregate->name;
+		newtype->aggregate->kind = aggregate->kind;
+		break;
+	  case AggregateInst:
+		newtype->aggInst->aggregate = maybeClone( aggInst->aggregate );
+		newtype->aggInst->params = maybeClone( aggInst->params );
+		break;
+	  case Enum:
+		newtype->enumeration->name = enumeration->name;
+		newtype->enumeration->constants = maybeClone( enumeration->constants );
+		break;
+	  case Symbolic:
+	  case SymbolicInst:
+		newtype->symbolic->params = maybeClone( symbolic->params );
+		newtype->symbolic->actuals = maybeClone( symbolic->actuals );
+		newtype->symbolic->assertions = maybeClone( symbolic->assertions );
+		newtype->symbolic->isTypedef = symbolic->isTypedef;
+		newtype->symbolic->name = symbolic->name;
+		break;
+	  case Variable:
+		newtype->variable->assertions = maybeClone( variable->assertions );
+		newtype->variable->name = variable->name;
+		newtype->variable->tyClass = variable->tyClass;
+		break;
+	  case Tuple:
+		newtype->tuple->members = maybeClone( tuple->members );
+		break;
+	  case Typeof:
+		newtype->typeexpr->expr = maybeClone( typeexpr->expr );
+		break;
+	  case Attr:
+		newtype->attr->expr = maybeClone( attr->expr );
+		newtype->attr->type = maybeClone( attr->type );
+		break;
+	}
+	return newtype;
 }
 
 void TypeData::print( std::ostream &os, int indent ) const {
-    using std::endl;
-    using std::string;
-
-    printEnums( qualifiers.begin(), qualifiers.end(), DeclarationNode::qualifierName, os );
-
-    if ( forall ) {
-	os << "forall " << endl;
-	forall->printList( os, indent+4 );
-    }
-
-    switch ( kind ) {
-      case Unknown:
-	os << "entity of unknown type ";
-	break;
-      case Pointer:
-	os << "pointer ";
-	if ( base ) {
-	    os << "to ";
-	    base->print( os, indent );
-	}
-	break;
-      case EnumConstant:
-	os << "enumeration constant ";
-	break;
-      case Basic:
-	printEnums( basic->modifiers.begin(), basic->modifiers.end(), DeclarationNode::modifierName, os );
-	printEnums( basic->typeSpec.begin(), basic->typeSpec.end(), DeclarationNode::basicTypeName, os );
-	break;
-      case Array:
-	if ( array->isStatic ) {
-	    os << "static ";
-	}
-	if ( array->dimension ) {
-	    os << "array of ";
-	    array->dimension->printOneLine( os, indent );
-	} else if ( array->isVarLen ) {
-	    os << "variable-length array of ";
-	} else {
-	    os << "open array of ";
-	}
-	if ( base ) {
-	    base->print( os, indent );
-	}
-	break;
-      case Function:
-	os << "function" << endl;
-	if ( function->params ) {
-	    os << string( indent+2, ' ' ) << "with parameters " << endl;
-	    function->params->printList( os, indent+4 );
-	} else {
-	    os << string( indent+2, ' ' ) << "with no parameters " << endl;
-	}
-	if ( function->idList ) {
-	    os << string( indent+2, ' ' ) << "with old-style identifier list " << endl;
-	    function->idList->printList( os, indent+4 );
-	}
-	if ( function->oldDeclList ) {
-	    os << string( indent+2, ' ' ) << "with old-style declaration list " << endl;
-	    function->oldDeclList->printList( os, indent+4 );
-	}
-	os << string( indent+2, ' ' ) << "returning ";
-	if ( base ) {
-	    base->print( os, indent+4 );
-	} else {
-	    os << "nothing ";
-	}
-	os << endl;
-	if ( function->hasBody ) {
-	    os << string( indent+2, ' ' ) << "with body " << endl;
-	}
-	if ( function->body ) {
-	    function->body->printList( os, indent+2 );
-	}
-	break;
-      case Aggregate:
-	os << DeclarationNode::tyConName[ aggregate->kind ] << ' ' << aggregate->name << endl;
-	if ( aggregate->params ) {
-	    os << string( indent+2, ' ' ) << "with type parameters " << endl;
-	    aggregate->params->printList( os, indent+4 );
-	}
-	if ( aggregate->actuals ) {
-	    os << string( indent+2, ' ' ) << "instantiated with actual parameters " << endl;
-	    aggregate->actuals->printList( os, indent+4 );
-	}
-	if ( aggregate->members ) {
-	    os << string( indent+2, ' ' ) << "with members " << endl;
-	    aggregate->members->printList( os, indent+4 );
+	using std::endl;
+	using std::string;
+
+	printEnums( qualifiers.begin(), qualifiers.end(), DeclarationNode::qualifierName, os );
+
+	if ( forall ) {
+		os << "forall " << endl;
+		forall->printList( os, indent+4 );
+	}
+
+	switch ( kind ) {
+	  case Unknown:
+		os << "entity of unknown type ";
+		break;
+	  case Pointer:
+		os << "pointer ";
+		if ( base ) {
+			os << "to ";
+			base->print( os, indent );
+		}
+		break;
+	  case EnumConstant:
+		os << "enumeration constant ";
+		break;
+	  case Basic:
+		printEnums( basic->modifiers.begin(), basic->modifiers.end(), DeclarationNode::modifierName, os );
+		printEnums( basic->typeSpec.begin(), basic->typeSpec.end(), DeclarationNode::basicTypeName, os );
+		break;
+	  case Array:
+		if ( array->isStatic ) {
+			os << "static ";
+		}
+		if ( array->dimension ) {
+			os << "array of ";
+			array->dimension->printOneLine( os, indent );
+		} else if ( array->isVarLen ) {
+			os << "variable-length array of ";
+		} else {
+			os << "open array of ";
+		}
+		if ( base ) {
+			base->print( os, indent );
+		}
+		break;
+	  case Function:
+		os << "function" << endl;
+		if ( function->params ) {
+			os << string( indent+2, ' ' ) << "with parameters " << endl;
+			function->params->printList( os, indent+4 );
+		} else {
+			os << string( indent+2, ' ' ) << "with no parameters " << endl;
+		}
+		if ( function->idList ) {
+			os << string( indent+2, ' ' ) << "with old-style identifier list " << endl;
+			function->idList->printList( os, indent+4 );
+		}
+		if ( function->oldDeclList ) {
+			os << string( indent+2, ' ' ) << "with old-style declaration list " << endl;
+			function->oldDeclList->printList( os, indent+4 );
+		}
+		os << string( indent+2, ' ' ) << "returning ";
+		if ( base ) {
+			base->print( os, indent+4 );
+		} else {
+			os << "nothing ";
+		}
+		os << endl;
+		if ( function->hasBody ) {
+			os << string( indent+2, ' ' ) << "with body " << endl;
+		}
+		if ( function->body ) {
+			function->body->printList( os, indent+2 );
+		}
+		break;
+	  case Aggregate:
+		os << DeclarationNode::tyConName[ aggregate->kind ] << ' ' << aggregate->name << endl;
+		if ( aggregate->params ) {
+			os << string( indent+2, ' ' ) << "with type parameters " << endl;
+			aggregate->params->printList( os, indent+4 );
+		}
+		if ( aggregate->actuals ) {
+			os << string( indent+2, ' ' ) << "instantiated with actual parameters " << endl;
+			aggregate->actuals->printList( os, indent+4 );
+		}
+		if ( aggregate->members ) {
+			os << string( indent+2, ' ' ) << "with members " << endl;
+			aggregate->members->printList( os, indent+4 );
 ///     } else {
 ///       os << string( indent+2, ' ' ) << "with no members " << endl;
-	}
-	break;
-      case AggregateInst:
-	if ( aggInst->aggregate ) {
-	    os << "instance of " ;
-	    aggInst->aggregate->print( os, indent );
+		}
+		break;
+	  case AggregateInst:
+		if ( aggInst->aggregate ) {
+			os << "instance of " ;
+			aggInst->aggregate->print( os, indent );
+		} else {
+			os << "instance of an unspecified aggregate ";
+		}
+		if ( aggInst->params ) {
+			os << string( indent+2, ' ' ) << "with parameters " << endl;
+			aggInst->params->printList( os, indent+2 );
+		}
+		break;
+	  case Enum:
+		os << "enumeration ";
+		if ( enumeration->constants ) {
+			os << "with constants" << endl;
+			enumeration->constants->printList( os, indent+2 );
+		}
+		break;
+	  case SymbolicInst:
+		os << "instance of type " << symbolic->name;
+		if ( symbolic->actuals ) {
+			os << " with parameters" << endl;
+			symbolic->actuals->printList( os, indent + 2 );
+		}
+		break;
+	  case Symbolic:
+		if ( symbolic->isTypedef ) {
+			os << "typedef definition ";
+		} else {
+			os << "type definition ";
+		}
+		if ( symbolic->params ) {
+			os << endl << string( indent+2, ' ' ) << "with parameters" << endl;
+			symbolic->params->printList( os, indent + 2 );
+		}
+		if ( symbolic->assertions ) {
+			os << endl << string( indent+2, ' ' ) << "with assertions" << endl;
+			symbolic->assertions->printList( os, indent + 4 );
+			os << string( indent+2, ' ' );
+		}
+		if ( base ) {
+			os << "for ";
+			base->print( os, indent + 2 );
+		}
+		break;
+	  case Variable:
+		os << DeclarationNode::typeClassName[ variable->tyClass ] << " variable ";
+		if ( variable->assertions ) {
+			os << endl << string( indent+2, ' ' ) << "with assertions" << endl;
+			variable->assertions->printList( os, indent + 4 );
+			os << string( indent+2, ' ' );
+		}
+		break;
+	  case Tuple:
+		os << "tuple ";
+		if ( tuple->members ) {
+			os << "with members " << endl;
+			tuple->members->printList( os, indent + 2 );
+		}
+		break;
+	  case Typeof:
+		os << "type-of expression ";
+		if ( typeexpr->expr ) {
+			typeexpr->expr->print( os, indent + 2 );
+		}
+		break;
+	  case Attr:
+		os << "attribute type decl " << attr->name << " applied to ";
+		if ( attr->expr ) {
+			attr->expr->print( os, indent + 2 );
+		}
+		if ( attr->type ) {
+			attr->type->print( os, indent + 2 );
+		}
+		break;
+	}
+}
+
+TypeData *TypeData::extractAggregate( bool toplevel ) const {
+	TypeData *ret = 0;
+
+	switch ( kind ) {
+	  case Aggregate:
+		if ( !toplevel && aggregate->members ) {
+			ret = clone();
+			ret->qualifiers.clear();
+		}
+		break;
+	  case Enum:
+		if ( !toplevel && enumeration->constants ) {
+			ret = clone();
+			ret->qualifiers.clear();
+		}
+		break;
+	  case AggregateInst:
+		if ( aggInst->aggregate ) {
+			ret = aggInst->aggregate->extractAggregate( false );
+		}
+		break;
+	  default:
+		if ( base ) {
+			ret = base->extractAggregate( false );
+		}
+	}
+	return ret;
+}
+
+void buildForall( const DeclarationNode *firstNode, std::list< TypeDecl* > &outputList ) {
+	buildList( firstNode, outputList );
+	for ( std::list< TypeDecl* >::iterator i = outputList.begin(); i != outputList.end(); ++i ) {
+		if ( (*i)->get_kind() == TypeDecl::Any ) {
+			FunctionType *assignType = new FunctionType( Type::Qualifiers(), false );
+			assignType->get_parameters().push_back( new ObjectDecl( "", Declaration::NoStorageClass, LinkageSpec::Cforall, 0, new PointerType( Type::Qualifiers(), new TypeInstType( Type::Qualifiers(), (*i)->get_name(), *i ) ), 0 ) );
+			assignType->get_parameters().push_back( new ObjectDecl( "", Declaration::NoStorageClass, LinkageSpec::Cforall, 0, new TypeInstType( Type::Qualifiers(), (*i)->get_name(), *i ), 0 ) );
+			assignType->get_returnVals().push_back( new ObjectDecl( "", Declaration::NoStorageClass, LinkageSpec::Cforall, 0, new TypeInstType( Type::Qualifiers(), (*i)->get_name(), *i ), 0 ) );
+			(*i)->get_assertions().push_front( new FunctionDecl( "?=?", Declaration::NoStorageClass, LinkageSpec::Cforall, assignType, 0, false ) );
+		}
+	}
+}
+
+Declaration *TypeData::buildDecl( std::string name, Declaration::StorageClass sc, Expression *bitfieldWidth, bool isInline, LinkageSpec::Type linkage, Initializer *init ) const {
+	if ( kind == TypeData::Function ) {
+		FunctionDecl *decl;
+		if ( function->hasBody ) {
+			if ( function->body ) {
+				Statement *stmt = function->body->build();
+				CompoundStmt *body = dynamic_cast< CompoundStmt* >( stmt );
+				assert( body );
+				decl = new FunctionDecl( name, sc, linkage, buildFunction(), body, isInline );
+			} else {
+				// std::list<Label> ls;
+				decl = new FunctionDecl( name, sc, linkage, buildFunction(), new CompoundStmt( std::list<Label>() ), isInline );
+			}
+		} else {
+			decl = new FunctionDecl( name, sc, linkage, buildFunction(), 0, isInline );
+		}
+		for ( DeclarationNode *cur = function->idList; cur != 0; cur = dynamic_cast< DeclarationNode* >( cur->get_link() ) ) {
+			if ( cur->get_name() != "" ) {
+				decl->get_oldIdents().insert( decl->get_oldIdents().end(), cur->get_name() );
+			}
+		}
+		buildList( function->oldDeclList, decl->get_oldDecls() );
+		return decl;
+	} else if ( kind == TypeData::Aggregate ) {
+		return buildAggregate();
+	} else if ( kind == TypeData::Enum ) {
+		return buildEnum();
+	} else if ( kind == TypeData::Symbolic ) {
+		return buildSymbolic( name, sc );
+	} else if ( kind == TypeData::Variable ) {
+		return buildVariable();
 	} else {
-	    os << "instance of an unspecified aggregate ";
-	}
-	if ( aggInst->params ) {
-	    os << string( indent+2, ' ' ) << "with parameters " << endl;
-	    aggInst->params->printList( os, indent+2 );
-	}
-	break;
-      case Enum:
-	os << "enumeration ";
-	if ( enumeration->constants ) {
-	    os << "with constants" << endl;
-	    enumeration->constants->printList( os, indent+2 );
-	}
-	break;
-      case SymbolicInst:
-	os << "instance of type " << symbolic->name;
-	if ( symbolic->actuals ) {
-	    os << " with parameters" << endl;
-	    symbolic->actuals->printList( os, indent + 2 );
-	}
-	break;
-      case Symbolic:
-	if ( symbolic->isTypedef ) {
-	    os << "typedef definition ";
+		if ( isInline ) {
+			throw SemanticError( "invalid inline specification in declaration of ", this );
+		} else {
+			return new ObjectDecl( name, sc, linkage, bitfieldWidth, build(), init );
+		}
+	}
+	return 0;
+}
+
+Type *TypeData::build() const {
+	switch ( kind ) {
+	  case Unknown:
+		// fill in implicit int
+		return new BasicType( buildQualifiers(), BasicType::SignedInt );
+	  case Basic:
+		return buildBasicType();
+	  case Pointer:
+		return buildPointer();
+	  case Array:
+		return buildArray();
+	  case Function:
+		return buildFunction();
+	  case AggregateInst:
+		return buildAggInst();
+	  case EnumConstant:
+		// the name gets filled in later -- by SymTab::Validate
+		return new EnumInstType( buildQualifiers(), "" );
+	  case SymbolicInst:
+		return buildSymbolicInst();;
+	  case Tuple:
+		return buildTuple();
+	  case Typeof:
+		return buildTypeof();
+	  case Attr:
+		return buildAttr();
+	  case Symbolic:
+	  case Enum:
+	  case Aggregate:
+	  case Variable:
+		assert( false );
+	}
+
+	return 0;
+}
+
+Type::Qualifiers TypeData::buildQualifiers() const {
+	Type::Qualifiers q;
+	for ( std::list< DeclarationNode::Qualifier >::const_iterator i = qualifiers.begin(); i != qualifiers.end(); ++i ) {
+		switch ( *i ) {
+		  case DeclarationNode::Const:
+			q.isConst = true;
+			break;
+		  case DeclarationNode::Volatile:
+			q.isVolatile = true;
+			break;
+		  case DeclarationNode::Restrict:
+			q.isRestrict = true;
+			break;
+		  case DeclarationNode::Lvalue:
+			q.isLvalue = true;
+			break;
+		  case DeclarationNode::Atomic:
+			q.isAtomic = true;
+			break;
+		  case DeclarationNode::Attribute:
+			q.isAttribute = true;
+			break;
+		}
+	}
+	return q;
+}
+
+Type *TypeData::buildBasicType() const {
+	static const BasicType::Kind kindMap[] = { BasicType::Char, BasicType::SignedInt, BasicType::Float, BasicType::Double,
+											   BasicType::Char /* void */, BasicType::Bool, BasicType::DoubleComplex,
+											   BasicType::DoubleImaginary };
+	bool init = false;
+	bool sawDouble = false;
+	bool sawSigned = false;
+	BasicType::Kind ret;
+
+	for ( std::list< DeclarationNode::BasicType >::const_iterator i = basic->typeSpec.begin(); i != basic->typeSpec.end(); ++i ) {
+		if ( !init ) {
+			init = true;
+			if ( *i == DeclarationNode::Void ) {
+				if ( basic->typeSpec.size() != 1 || !basic->modifiers.empty() ) {
+					throw SemanticError( "invalid type specifier \"void\" in type: ", this );
+				} else {
+					return new VoidType( buildQualifiers() );
+				}
+			} else {
+				ret = kindMap[ *i ];
+			}
+		} else {
+			switch ( *i ) {
+			  case DeclarationNode::Float:
+				if ( sawDouble ) {
+					throw SemanticError( "invalid type specifier \"float\" in type: ", this );
+				} else {
+					switch ( ret ) {
+					  case BasicType::DoubleComplex:
+						ret = BasicType::FloatComplex;
+						break;
+					  case BasicType::DoubleImaginary:
+						ret = BasicType::FloatImaginary;
+						break;
+					  default:
+						throw SemanticError( "invalid type specifier \"float\" in type: ", this );
+					}
+				}
+				break;
+			  case DeclarationNode::Double:
+				if ( sawDouble ) {
+					throw SemanticError( "duplicate type specifier \"double\" in type: ", this );
+				} else {
+					switch ( ret ) {
+					  case BasicType::DoubleComplex:
+					  case BasicType::DoubleImaginary:
+						break;
+					  default:
+						throw SemanticError( "invalid type specifier \"double\" in type: ", this );
+					}
+				}
+				break;
+	
+			  case DeclarationNode::Complex:
+				switch ( ret ) {
+				  case BasicType::Float:
+					ret = BasicType::FloatComplex;
+					break;
+				  case BasicType::Double:
+					ret = BasicType::DoubleComplex;
+					break;
+				  default:
+					throw SemanticError( "invalid type specifier \"_Complex\" in type: ", this );
+				}
+				break;
+			  case DeclarationNode::Imaginary:
+				switch ( ret ) {
+				  case BasicType::Float:
+					ret = BasicType::FloatImaginary;
+					break;
+				  case BasicType::Double:
+					ret = BasicType::DoubleImaginary;
+					break;
+				  default:
+					throw SemanticError( "invalid type specifier \"_Imaginary\" in type: ", this );
+				}
+				break;
+			  default:
+				throw SemanticError( std::string( "invalid type specifier \"" ) + DeclarationNode::basicTypeName[ *i ] + "\" in type: ", this );
+			}
+		}
+		if ( *i == DeclarationNode::Double ) {
+			sawDouble = true;
+		}
+	}
+
+	for ( std::list< DeclarationNode::Modifier >::const_iterator i = basic->modifiers.begin(); i != basic->modifiers.end(); ++i ) {
+		switch ( *i ) {
+		  case DeclarationNode::Long:
+			if ( !init ) {
+				init = true;
+				ret = BasicType::LongSignedInt;
+			} else {
+				switch ( ret ) {
+				  case BasicType::SignedInt:
+					ret = BasicType::LongSignedInt;
+					break;
+				  case BasicType::UnsignedInt:
+					ret = BasicType::LongUnsignedInt;
+					break;
+				  case BasicType::LongSignedInt:
+					ret = BasicType::LongLongSignedInt;
+					break;
+				  case BasicType::LongUnsignedInt:
+					ret = BasicType::LongLongUnsignedInt;
+					break;
+				  case BasicType::Double:
+					ret = BasicType::LongDouble;
+					break;
+				  case BasicType::DoubleComplex:
+					ret = BasicType::LongDoubleComplex;
+					break;
+				  case BasicType::DoubleImaginary:
+					ret = BasicType::LongDoubleImaginary;
+					break;
+				  default:
+					throw SemanticError( "invalid type modifier \"long\" in type: ", this );
+				}
+			}
+			break;
+		  case DeclarationNode::Short:
+			if ( !init ) {
+				init = true;
+				ret = BasicType::ShortSignedInt;
+			} else {
+				switch ( ret ) {
+				  case BasicType::SignedInt:
+					ret = BasicType::ShortSignedInt;
+					break;
+				  case BasicType::UnsignedInt:
+					ret = BasicType::ShortUnsignedInt;
+					break;
+				  default:
+					throw SemanticError( "invalid type modifier \"short\" in type: ", this );
+				}
+			}
+			break;
+		  case DeclarationNode::Signed:
+			if ( !init ) {
+				init = true;
+				ret = BasicType::SignedInt;
+			} else if ( sawSigned ) {
+				throw SemanticError( "duplicate type modifer \"signed\" in type: ", this );
+			} else {
+				switch ( ret ) {
+				  case BasicType::LongLongSignedInt:	// PAB
+					ret = BasicType::LongLongUnsignedInt;
+					break;
+				  case BasicType::LongSignedInt:
+					ret = BasicType::LongUnsignedInt;
+					break;
+				  case BasicType::SignedInt:
+				  case BasicType::ShortSignedInt:
+					break;
+				  case BasicType::Char:
+					ret = BasicType::SignedChar;
+					break;
+				  default:
+					throw SemanticError( "invalid type modifer \"signed\" in type: ", this );
+				}
+			}
+			break;
+		  case DeclarationNode::Unsigned:
+			if ( !init ) {
+				init = true;
+				ret = BasicType::UnsignedInt;
+			} else if ( sawSigned ) {
+				throw SemanticError( "invalid type modifer \"unsigned\" in type: ", this );
+			} else {
+				switch ( ret ) {
+				  case BasicType::LongLongSignedInt:	// PAB
+					ret = BasicType::LongLongUnsignedInt;
+					break;
+				  case BasicType::LongSignedInt:
+					ret = BasicType::LongUnsignedInt;
+					break;
+				  case BasicType::SignedInt:
+					ret = BasicType::UnsignedInt;
+					break;
+				  case BasicType::ShortSignedInt:
+					ret = BasicType::ShortUnsignedInt;
+					break;
+				  case BasicType::Char:
+					ret = BasicType::UnsignedChar;
+					break;
+				  default:
+					throw SemanticError( "invalid type modifer \"unsigned\" in type: ", this );
+				}
+			}
+			break;
+		}
+
+		if ( *i == DeclarationNode::Signed ) {
+			sawSigned = true;
+		}
+	}
+
+	BasicType *bt;
+	if ( !init ) {
+		bt = new BasicType( buildQualifiers(), BasicType::SignedInt );
 	} else {
-	    os << "type definition ";
-	}
-	if ( symbolic->params ) {
-	    os << endl << string( indent+2, ' ' ) << "with parameters" << endl;
-	    symbolic->params->printList( os, indent + 2 );
-	}
-	if ( symbolic->assertions ) {
-	    os << endl << string( indent+2, ' ' ) << "with assertions" << endl;
-	    symbolic->assertions->printList( os, indent + 4 );
-	    os << string( indent+2, ' ' );
-	}
+		bt = new BasicType( buildQualifiers(), ret );
+	}
+	buildForall( forall, bt->get_forall() );
+	return bt;
+}
+
+
+PointerType *TypeData::buildPointer() const {
+	PointerType *pt;
 	if ( base ) {
-	    os << "for ";
-	    base->print( os, indent + 2 );
-	}
-	break;
-      case Variable:
-	os << DeclarationNode::typeClassName[ variable->tyClass ] << " variable ";
-	if ( variable->assertions ) {
-	    os << endl << string( indent+2, ' ' ) << "with assertions" << endl;
-	    variable->assertions->printList( os, indent + 4 );
-	    os << string( indent+2, ' ' );
-	}
-	break;
-      case Tuple:
-	os << "tuple ";
-	if ( tuple->members ) {
-	    os << "with members " << endl;
-	    tuple->members->printList( os, indent + 2 );
-	}
-	break;
-    
-      case Typeof:
-	os << "type-of expression ";
-	if ( typeexpr->expr ) {
-	    typeexpr->expr->print( os, indent + 2 );
-	}
-	break;
-    
-      case Attr:
-	os << "attribute type decl " << attr->name << " applied to ";
-	if ( attr->expr ) {
-	    attr->expr->print( os, indent + 2 );
-	}
-	if ( attr->type ) {
-	    attr->type->print( os, indent + 2 );
-	}
-	break;
-    }
-}
-
-TypeData *TypeData::extractAggregate( bool toplevel ) const {
-    TypeData *ret = 0;
-
-    switch ( kind ) {
-      case Aggregate:
-	if ( !toplevel && aggregate->members ) {
-	    ret = clone();
-	    ret->qualifiers.clear();
-	}
-	break;
-      case Enum:
-	if ( !toplevel && enumeration->constants ) {
-	    ret = clone();
-	    ret->qualifiers.clear();
-	}
-	break;
-      case AggregateInst:
-	if ( aggInst->aggregate ) {
-	    ret = aggInst->aggregate->extractAggregate( false );
-	}
-	break;
-      default:
+		pt = new PointerType( buildQualifiers(), base->build() );
+	} else {
+		pt = new PointerType( buildQualifiers(), new BasicType( Type::Qualifiers(), BasicType::SignedInt ) );
+	}
+	buildForall( forall, pt->get_forall() );
+	return pt;
+}
+
+ArrayType *TypeData::buildArray() const {
+	ArrayType *at;
 	if ( base ) {
-	    ret = base->extractAggregate( false );
-	}
-    }
-    return ret;
-}
-
-void buildForall( const DeclarationNode *firstNode, std::list< TypeDecl* > &outputList ) {
-  
-    buildList( firstNode, outputList );
-    for ( std::list< TypeDecl* >::iterator i = outputList.begin(); i != outputList.end(); ++i ) {
-	if ( (*i)->get_kind() == TypeDecl::Any ) {
-	    FunctionType *assignType = new FunctionType( Type::Qualifiers(), false );
-	    assignType->get_parameters().push_back( new ObjectDecl( "", Declaration::NoStorageClass, LinkageSpec::Cforall, 0, new PointerType( Type::Qualifiers(), new TypeInstType( Type::Qualifiers(), (*i)->get_name(), *i ) ), 0 ) );
-	    assignType->get_parameters().push_back( new ObjectDecl( "", Declaration::NoStorageClass, LinkageSpec::Cforall, 0, new TypeInstType( Type::Qualifiers(), (*i)->get_name(), *i ), 0 ) );
-	    assignType->get_returnVals().push_back( new ObjectDecl( "", Declaration::NoStorageClass, LinkageSpec::Cforall, 0, new TypeInstType( Type::Qualifiers(), (*i)->get_name(), *i ), 0 ) );
-	    (*i)->get_assertions().push_front( new FunctionDecl( "?=?", Declaration::NoStorageClass, LinkageSpec::Cforall,  assignType, 0, false ) );
-	}
-    }
-}
-
-Declaration *TypeData::buildDecl( std::string name, Declaration::StorageClass sc, Expression *bitfieldWidth, bool isInline, LinkageSpec::Type linkage, Initializer *init ) const {
-    if ( kind == TypeData::Function ) {
-	FunctionDecl *decl;
-	if ( function->hasBody ) {
-	    if ( function->body ) {
-		Statement *stmt = function->body->build();
-		CompoundStmt *body = dynamic_cast< CompoundStmt* >( stmt );
-		assert( body );
-		decl = new FunctionDecl( name, sc, linkage, buildFunction(), body, isInline );
-	    } else {
-		// std::list<Label> ls;
-		decl = new FunctionDecl( name, sc, linkage, buildFunction(), new CompoundStmt( std::list<Label>() ), isInline );
-	    }
+		at = new ArrayType( buildQualifiers(), base->build(), maybeBuild< Expression >( array->dimension ),
+							array->isVarLen, array->isStatic );
 	} else {
-	    decl = new FunctionDecl( name, sc, linkage, buildFunction(), 0, isInline );
-	}
-	for ( DeclarationNode *cur = function->idList; cur != 0; cur = dynamic_cast< DeclarationNode* >( cur->get_link() ) ) {
-	    if ( cur->get_name() != "" ) {
-		decl->get_oldIdents().insert( decl->get_oldIdents().end(), cur->get_name() );
-	    }
-	}
-	buildList( function->oldDeclList, decl->get_oldDecls() );
-	return decl;
-    } else if ( kind == TypeData::Aggregate ) {
-	return buildAggregate();
-    } else if ( kind == TypeData::Enum ) {
-	return buildEnum();
-    } else if ( kind == TypeData::Symbolic ) {
-	return buildSymbolic( name, sc );
-    } else if ( kind == TypeData::Variable ) {
-	return buildVariable();
-    } else {
-	if ( isInline ) {
-	    throw SemanticError( "invalid inline specification in declaration of ", this );
+		at = new ArrayType( buildQualifiers(), new BasicType( Type::Qualifiers(), BasicType::SignedInt ),
+							maybeBuild< Expression >( array->dimension ), array->isVarLen, array->isStatic );
+	}
+	buildForall( forall, at->get_forall() );
+	return at;
+}
+
+FunctionType *TypeData::buildFunction() const {
+	assert( kind == Function );
+	bool hasEllipsis = function->params ? function->params->get_hasEllipsis() : true;
+	if ( !function->params ) hasEllipsis = !function->newStyle;
+	FunctionType *ft = new FunctionType( buildQualifiers(), hasEllipsis );
+	buildList( function->params, ft->get_parameters() );
+	buildForall( forall, ft->get_forall() );
+	if ( base ) {
+		switch ( base->kind ) {
+		  case Tuple:
+			buildList( base->tuple->members, ft->get_returnVals() );
+			break;
+		  default:
+			ft->get_returnVals().push_back( dynamic_cast< DeclarationWithType* >( base->buildDecl( "", Declaration::NoStorageClass, 0, false, LinkageSpec::Cforall ) ) );
+		}
 	} else {
-	    return new ObjectDecl( name, sc, linkage, bitfieldWidth, build(), init );
-	}
-    }
-    return 0;
-}
-
-Type *TypeData::build() const {
-
-    switch ( kind ) {
-      case Unknown:
-	// fill in implicit int
-	return new BasicType( buildQualifiers(), BasicType::SignedInt );
-
-      case Basic:
-	return buildBasicType();
-
-      case Pointer:
-	return buildPointer();
-
-      case Array:
-	return buildArray();
-
-      case Function:
-	return buildFunction();
-
-      case AggregateInst:
-	return buildAggInst();
-
-      case EnumConstant:
-	// the name gets filled in later -- by SymTab::Validate
-	return new EnumInstType( buildQualifiers(), "" );
-
-      case SymbolicInst:
-	return buildSymbolicInst();;
-
-      case Tuple:
-	return buildTuple();
-  
-      case Typeof:
-	return buildTypeof();
-
-      case Attr:
-	return buildAttr();
-
-      case Symbolic:
-      case Enum:
-      case Aggregate:
-      case Variable:
-	assert( false );
-    }
-
-    return 0;
-}
-
-Type::Qualifiers TypeData::buildQualifiers() const {
-    Type::Qualifiers q;
-    for ( std::list< DeclarationNode::Qualifier >::const_iterator i = qualifiers.begin(); i != qualifiers.end(); ++i ) {
-	switch ( *i ) {
-	  case DeclarationNode::Const:
-	    q.isConst = true;
-	    break;
-	  case DeclarationNode::Volatile:
-	    q.isVolatile = true;
-	    break;
-	  case DeclarationNode::Restrict:
-	    q.isRestrict = true;
-	    break;
-	  case DeclarationNode::Lvalue:
-	    q.isLvalue = true;
-	    break;
-	  case DeclarationNode::Atomic:
-	    q.isAtomic = true;
-	    break;
-	  case DeclarationNode::Attribute:
-	    q.isAttribute = true;
-	    break;
-	}
-    }
-    return q;
-}
-
-Type *TypeData::buildBasicType() const {
-    static const BasicType::Kind kindMap[] = { BasicType::Char, BasicType::SignedInt, BasicType::Float, BasicType::Double,
-					       BasicType::Char /* void */, BasicType::Bool, BasicType::DoubleComplex,
-					       BasicType::DoubleImaginary };
-    bool init = false;
-    bool sawDouble = false;
-    bool sawSigned = false;
-    BasicType::Kind ret;
-
-    for ( std::list< DeclarationNode::BasicType >::const_iterator i = basic->typeSpec.begin(); i != basic->typeSpec.end(); ++i ) {
-	if ( !init ) {
-	    init = true;
-	    if ( *i == DeclarationNode::Void ) {
-		if ( basic->typeSpec.size() != 1 || !basic->modifiers.empty() ) {
-		    throw SemanticError( "invalid type specifier \"void\" in type: ", this );
-		} else {
-		    return new VoidType( buildQualifiers() );
-		}
-	    } else {
-		ret = kindMap[ *i ];
-	    }
-	} else {
-	    switch ( *i ) {
-	      case DeclarationNode::Float:
-		if ( sawDouble ) {
-		    throw SemanticError( "invalid type specifier \"float\" in type: ", this );
-		} else {
-		    switch ( ret ) {
-		      case BasicType::DoubleComplex:
-			ret = BasicType::FloatComplex;
-			break;
-		      case BasicType::DoubleImaginary:
-			ret = BasicType::FloatImaginary;
-			break;
-		      default:
-			throw SemanticError( "invalid type specifier \"float\" in type: ", this );
-		    }
-		}
-		break;
-	      case DeclarationNode::Double:
-		if ( sawDouble ) {
-		    throw SemanticError( "duplicate type specifier \"double\" in type: ", this );
-		} else {
-		    switch ( ret ) {
-		      case BasicType::DoubleComplex:
-		      case BasicType::DoubleImaginary:
-			break;
-		      default:
-			throw SemanticError( "invalid type specifier \"double\" in type: ", this );
-		    }
-		}
+		ft->get_returnVals().push_back( new ObjectDecl( "", Declaration::NoStorageClass, LinkageSpec::Cforall, 0, new BasicType( Type::Qualifiers(), BasicType::SignedInt ), 0 ) );
+	}
+	return ft;
+}
+
+AggregateDecl *TypeData::buildAggregate() const {
+	assert( kind == Aggregate );
+	AggregateDecl *at;
+	switch ( aggregate->kind ) {
+	  case DeclarationNode::Struct:
+		at = new StructDecl( aggregate->name );
 		break;
 	
-	      case DeclarationNode::Complex:
-		switch ( ret ) {
-		  case BasicType::Float:
-		    ret = BasicType::FloatComplex;
-		    break;
-          
-		  case BasicType::Double:
-		    ret = BasicType::DoubleComplex;
-		    break;
-		  default:
-		    throw SemanticError( "invalid type specifier \"_Complex\" in type: ", this );
-		}
-		break;
-        
-	      case DeclarationNode::Imaginary:
-		switch ( ret ) {
-		  case BasicType::Float:
-		    ret = BasicType::FloatImaginary;
-		    break;
-          
-		  case BasicType::Double:
-		    ret = BasicType::DoubleImaginary;
-		    break;
-		  default:
-		    throw SemanticError( "invalid type specifier \"_Imaginary\" in type: ", this );
-		}
-		break;
-        
-	      default:
-		throw SemanticError( std::string( "invalid type specifier \"" ) + DeclarationNode::basicTypeName[ *i ] + "\" in type: ", this );
-	    }
-	}
-	if ( *i == DeclarationNode::Double ) {
-	    sawDouble = true;
-	}
-    }
-
-    for ( std::list< DeclarationNode::Modifier >::const_iterator i = basic->modifiers.begin(); i != basic->modifiers.end(); ++i ) {
-	switch ( *i ) {
-	  case DeclarationNode::Long:
-	    if ( !init ) {
-		init = true;
-		ret = BasicType::LongSignedInt;
-	    } else {
-		switch ( ret ) {
-		  case BasicType::SignedInt:
-		    ret = BasicType::LongSignedInt;
-		    break;
-		  case BasicType::UnsignedInt:
-		    ret = BasicType::LongUnsignedInt;
-		    break;
-		  case BasicType::LongSignedInt:
-		    ret = BasicType::LongLongSignedInt;
-		    break;
-		  case BasicType::LongUnsignedInt:
-		    ret = BasicType::LongLongUnsignedInt;
-		    break;
-		  case BasicType::Double:
-		    ret = BasicType::LongDouble;
-		    break;
-		  case BasicType::DoubleComplex:
-		    ret = BasicType::LongDoubleComplex;
-		    break;
-		  case BasicType::DoubleImaginary:
-		    ret = BasicType::LongDoubleImaginary;
-		    break;
-		  default:
-		    throw SemanticError( "invalid type modifier \"long\" in type: ", this );
-		}
-	    }
-	    break;
-	  case DeclarationNode::Short:
-	    if ( !init ) {
-		init = true;
-		ret = BasicType::ShortSignedInt;
-	    } else {
-		switch ( ret ) {
-		  case BasicType::SignedInt:
-		    ret = BasicType::ShortSignedInt;
-		    break;
-		  case BasicType::UnsignedInt:
-		    ret = BasicType::ShortUnsignedInt;
-		    break;
-		  default:
-		    throw SemanticError( "invalid type modifier \"short\" in type: ", this );
-		}
-	    }
-	    break;
-	  case DeclarationNode::Signed:
-	    if ( !init ) {
-		init = true;
-		ret = BasicType::SignedInt;
-	    } else if ( sawSigned ) {
-		throw SemanticError( "duplicate type modifer \"signed\" in type: ", this );
-	    } else {
-		switch ( ret ) {
-		  case BasicType::LongLongSignedInt:	// PAB
-		    ret = BasicType::LongLongUnsignedInt;
-		    break;
-		  case BasicType::LongSignedInt:
-		    ret = BasicType::LongUnsignedInt;
-		    break;
-		  case BasicType::SignedInt:
-		  case BasicType::ShortSignedInt:
-		    break;
-		  case BasicType::Char:
-		    ret = BasicType::SignedChar;
-		    break;
-		  default:
-		    throw SemanticError( "invalid type modifer \"signed\" in type: ", this );
-		}
-	    }
-	    break;
-	  case DeclarationNode::Unsigned:
-	    if ( !init ) {
-		init = true;
-		ret = BasicType::UnsignedInt;
-	    } else if ( sawSigned ) {
-		throw SemanticError( "invalid type modifer \"unsigned\" in type: ", this );
-	    } else {
-		switch ( ret ) {
-		  case BasicType::LongLongSignedInt:	// PAB
-		    ret = BasicType::LongLongUnsignedInt;
-		    break;
-		  case BasicType::LongSignedInt:
-		    ret = BasicType::LongUnsignedInt;
-		    break;
-		  case BasicType::SignedInt:
-		    ret = BasicType::UnsignedInt;
-		    break;
-		  case BasicType::ShortSignedInt:
-		    ret = BasicType::ShortUnsignedInt;
-		    break;
-		  case BasicType::Char:
-		    ret = BasicType::UnsignedChar;
-		    break;
-		  default:
-		    throw SemanticError( "invalid type modifer \"unsigned\" in type: ", this );
-		}
-	    }
-	    break;
-	}
-
-	if ( *i == DeclarationNode::Signed ) {
-	    sawSigned = true;
-	}
-    }
-
-    BasicType *bt;
-    if ( !init ) {
-	bt = new BasicType( buildQualifiers(), BasicType::SignedInt );
-    } else {
-	bt = new BasicType( buildQualifiers(), ret );
-    }
-    buildForall( forall, bt->get_forall() );
-    return bt;
-}
-
-
-PointerType *TypeData::buildPointer() const {
-    PointerType *pt;
-    if ( base ) {
-	pt = new PointerType( buildQualifiers(), base->build() );
-    } else {
-	pt = new PointerType( buildQualifiers(), new BasicType( Type::Qualifiers(), BasicType::SignedInt ) );
-    }
-    buildForall( forall, pt->get_forall() );
-    return pt;
-}
-
-ArrayType *TypeData::buildArray() const {
-  
-    ArrayType *at;
-    if ( base ) {
-	at = new ArrayType( buildQualifiers(), base->build(), maybeBuild< Expression >( array->dimension ),
-			    array->isVarLen, array->isStatic );
-    } else {
-	at = new ArrayType( buildQualifiers(), new BasicType( Type::Qualifiers(), BasicType::SignedInt ),
-			    maybeBuild< Expression >( array->dimension ), array->isVarLen, array->isStatic );
-    }
-    buildForall( forall, at->get_forall() );
-    return at;
-}
-
-FunctionType *TypeData::buildFunction() const {
-    assert( kind == Function );
-    bool hasEllipsis = function->params ? function->params->get_hasEllipsis() : true;
-    if ( !function->params ) hasEllipsis = !function->newStyle;
-    FunctionType *ft = new FunctionType( buildQualifiers(), hasEllipsis );
-    buildList( function->params, ft->get_parameters() );
-    buildForall( forall, ft->get_forall() );
-    if ( base ) {
-	switch ( base->kind ) {
-	  case Tuple:
-	    buildList( base->tuple->members, ft->get_returnVals() );
-	    break;
+	  case DeclarationNode::Union:
+		at = new UnionDecl( aggregate->name );
+		break;
+	
+	  case DeclarationNode::Context:
+		at = new ContextDecl( aggregate->name );
+		break;
+	
 	  default:
-	    ft->get_returnVals().push_back( dynamic_cast< DeclarationWithType* >( base->buildDecl( "", Declaration::NoStorageClass, 0, false, LinkageSpec::Cforall ) ) );
-	}
-    } else {
-	ft->get_returnVals().push_back( new ObjectDecl( "", Declaration::NoStorageClass, LinkageSpec::Cforall, 0, new BasicType( Type::Qualifiers(), BasicType::SignedInt ), 0 ) );
-    }
-    return ft;
-}
-
-AggregateDecl *TypeData::buildAggregate() const {
-    assert( kind == Aggregate );
-    AggregateDecl *at;
-    switch ( aggregate->kind ) {
-      case DeclarationNode::Struct:
-	at = new StructDecl( aggregate->name );
-	break;
-    
-      case DeclarationNode::Union:
-	at = new UnionDecl( aggregate->name );
-	break;
-    
-      case DeclarationNode::Context:
-	at = new ContextDecl( aggregate->name );
-	break;
-    
-      default:
-	assert( false );
-    }
-  
-    buildList( aggregate->params, at->get_parameters() );
-    buildList( aggregate->members, at->get_members() );
-
-    return at;
+		assert( false );
+	}
+	buildList( aggregate->params, at->get_parameters() );
+	buildList( aggregate->members, at->get_members() );
+
+	return at;
 }
 
@@ -850,104 +837,106 @@
 
 ReferenceToType *TypeData::buildAggInst() const {
-    assert( kind == AggregateInst );
-    std::string name;
-
-    ReferenceToType *ret;
-    if ( aggInst->aggregate->kind == Enum ) {
-	ret = new EnumInstType( buildQualifiers(), aggInst->aggregate->enumeration->name );
-    } else {
-	assert( aggInst->aggregate->kind == Aggregate );
-	switch ( aggInst->aggregate->aggregate->kind ) {
-	  case DeclarationNode::Struct:
-	    ret = new StructInstType( buildQualifiers(), aggInst->aggregate->aggregate->name );
-	    break;
-	  case DeclarationNode::Union:
-	    ret = new UnionInstType( buildQualifiers(), aggInst->aggregate->aggregate->name );
-	    break;
-	  case DeclarationNode::Context:
-	    ret = new ContextInstType( buildQualifiers(), aggInst->aggregate->aggregate->name );
-	    break;
-	  default:
-	    assert( false );
-	}
-    }
-    buildList( aggInst->params, ret->get_parameters() );
-    buildForall( forall, ret->get_forall() );
-    return ret;
+	assert( kind == AggregateInst );
+	std::string name;
+
+	ReferenceToType *ret;
+	if ( aggInst->aggregate->kind == Enum ) {
+		ret = new EnumInstType( buildQualifiers(), aggInst->aggregate->enumeration->name );
+	} else {
+		assert( aggInst->aggregate->kind == Aggregate );
+		switch ( aggInst->aggregate->aggregate->kind ) {
+		  case DeclarationNode::Struct:
+			ret = new StructInstType( buildQualifiers(), aggInst->aggregate->aggregate->name );
+			break;
+		  case DeclarationNode::Union:
+			ret = new UnionInstType( buildQualifiers(), aggInst->aggregate->aggregate->name );
+			break;
+		  case DeclarationNode::Context:
+			ret = new ContextInstType( buildQualifiers(), aggInst->aggregate->aggregate->name );
+			break;
+		  default:
+			assert( false );
+		}
+	}
+	buildList( aggInst->params, ret->get_parameters() );
+	buildForall( forall, ret->get_forall() );
+	return ret;
 }
 
 NamedTypeDecl *TypeData::buildSymbolic( const std::string &name, Declaration::StorageClass sc ) const {
-    assert( kind == Symbolic );
-    NamedTypeDecl *ret;
-    if ( symbolic->isTypedef ) {
-	ret = new TypedefDecl( name, sc, maybeBuild< Type >( base ) );
-    } else {
-	ret = new TypeDecl( name, sc, maybeBuild< Type >( base ), TypeDecl::Any );
-    }
-    buildList( symbolic->params, ret->get_parameters() );
-    buildList( symbolic->assertions, ret->get_assertions() );
-    return ret;
+	assert( kind == Symbolic );
+	NamedTypeDecl *ret;
+	if ( symbolic->isTypedef ) {
+		ret = new TypedefDecl( name, sc, maybeBuild< Type >( base ) );
+	} else {
+		ret = new TypeDecl( name, sc, maybeBuild< Type >( base ), TypeDecl::Any );
+	}
+	buildList( symbolic->params, ret->get_parameters() );
+	buildList( symbolic->assertions, ret->get_assertions() );
+	return ret;
 }
 
 TypeDecl *TypeData::buildVariable() const {
-    assert( kind == Variable );
-    static const TypeDecl::Kind kindMap[] = { TypeDecl::Any, TypeDecl::Ftype, TypeDecl::Dtype };
-
-    TypeDecl *ret = new TypeDecl( variable->name, Declaration::NoStorageClass, 0, kindMap[ variable->tyClass ] );
-    buildList( variable->assertions, ret->get_assertions() );
-    
-    return ret;
+	assert( kind == Variable );
+	static const TypeDecl::Kind kindMap[] = { TypeDecl::Any, TypeDecl::Ftype, TypeDecl::Dtype };
+
+	TypeDecl *ret = new TypeDecl( variable->name, Declaration::NoStorageClass, 0, kindMap[ variable->tyClass ] );
+	buildList( variable->assertions, ret->get_assertions() );
+	
+	return ret;
 }
 
 EnumDecl *TypeData::buildEnum() const {
-    assert( kind == Enum );
-    EnumDecl *ret = new EnumDecl( enumeration->name );
-    buildList( enumeration->constants, ret->get_members() );
-
-    return ret;
+	assert( kind == Enum );
+	EnumDecl *ret = new EnumDecl( enumeration->name );
+	buildList( enumeration->constants, ret->get_members() );
+
+	return ret;
 }
 
 TypeInstType *TypeData::buildSymbolicInst() const {
-    assert( kind == SymbolicInst );
-
-
-    TypeInstType *ret = new TypeInstType( buildQualifiers(), symbolic->name, false );
-    buildList( symbolic->actuals, ret->get_parameters() );
-    buildForall( forall, ret->get_forall() );
-
-    return ret;
+	assert( kind == SymbolicInst );
+	TypeInstType *ret = new TypeInstType( buildQualifiers(), symbolic->name, false );
+	buildList( symbolic->actuals, ret->get_parameters() );
+	buildForall( forall, ret->get_forall() );
+
+	return ret;
 }
 
 TupleType *TypeData::buildTuple() const {
-    assert( kind == Tuple );
-
-
-    TupleType *ret = new TupleType( buildQualifiers() );
-    buildTypeList( tuple->members, ret->get_types() );
-    buildForall( forall, ret->get_forall() );
-
-    return ret;
+	assert( kind == Tuple );
+	TupleType *ret = new TupleType( buildQualifiers() );
+	buildTypeList( tuple->members, ret->get_types() );
+	buildForall( forall, ret->get_forall() );
+
+	return ret;
 }
 
 TypeofType *TypeData::buildTypeof() const {
-    assert( kind == Typeof );
-    assert( typeexpr );
-    assert( typeexpr->expr );
-    TypeofType *ret = new TypeofType( buildQualifiers(), typeexpr->expr->build() );
-
-    return ret;
+	assert( kind == Typeof );
+	assert( typeexpr );
+	assert( typeexpr->expr );
+	TypeofType *ret = new TypeofType( buildQualifiers(), typeexpr->expr->build() );
+
+	return ret;
 }
 
 AttrType *TypeData::buildAttr() const {
-    assert( kind == Attr );
-    assert( attr );
-    AttrType *ret;
-    if ( attr->expr ) {
-	ret = new AttrType( buildQualifiers(), attr->name, attr->expr->build() );
-    } else {
-	assert( attr->type );
-	ret = new AttrType( buildQualifiers(), attr->name, attr->type->buildType() );
-    }
-
-    return ret;
-}
+	assert( kind == Attr );
+	assert( attr );
+	AttrType *ret;
+	if ( attr->expr ) {
+		ret = new AttrType( buildQualifiers(), attr->name, attr->expr->build() );
+	} else {
+		assert( attr->type );
+		ret = new AttrType( buildQualifiers(), attr->name, attr->type->buildType() );
+	}
+
+	return ret;
+}
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/TypeData.h
===================================================================
--- translator/Parser/TypeData.h	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/TypeData.h	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// TypeData.h -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 15:18:36 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 15:20:00 2015
+// Update Count     : 2
+//
+
 #ifndef TYPEDATA_H
 #define TYPEDATA_H
@@ -8,117 +23,123 @@
 
 struct TypeData {
-    enum Kind { Unknown, Basic, Pointer, Array, Function, Aggregate, AggregateInst,
-		Enum, EnumConstant, Symbolic, SymbolicInst, Variable, Tuple, Typeof, Attr } kind;
+	enum Kind { Unknown, Basic, Pointer, Array, Function, Aggregate, AggregateInst,
+				Enum, EnumConstant, Symbolic, SymbolicInst, Variable, Tuple, Typeof, Attr } kind;
 
-    TypeData( Kind k = Unknown );
-    ~TypeData();
-    void print( std::ostream &, int indent = 0 ) const;
-    TypeData *clone() const;
+	TypeData( Kind k = Unknown );
+	~TypeData();
+	void print( std::ostream &, int indent = 0 ) const;
+	TypeData *clone() const;
 
-    Type *build() const;
-    FunctionType *buildFunction() const;
+	Type *build() const;
+	FunctionType *buildFunction() const;
 
-    TypeData *base;
-    std::list< DeclarationNode::Qualifier > qualifiers;
-    DeclarationNode *forall;
+	TypeData *base;
+	std::list< DeclarationNode::Qualifier > qualifiers;
+	DeclarationNode *forall;
 
-    struct Basic_t {
-	std::list< DeclarationNode::BasicType > typeSpec;
-	std::list< DeclarationNode::Modifier > modifiers;
-    };
+	struct Basic_t {
+		std::list< DeclarationNode::BasicType > typeSpec;
+		std::list< DeclarationNode::Modifier > modifiers;
+	};
 
-    struct Aggregate_t {
-	DeclarationNode::TyCon kind;
-	std::string name;
-	DeclarationNode *params;
-	ExpressionNode *actuals;			// holds actual parameters later applied to AggInst
-	DeclarationNode *members;
-    };
+	struct Aggregate_t {
+		DeclarationNode::TyCon kind;
+		std::string name;
+		DeclarationNode *params;
+		ExpressionNode *actuals;						// holds actual parameters later applied to AggInst
+		DeclarationNode *members;
+	};
 
-    struct AggInst_t {
-	TypeData *aggregate;
-	ExpressionNode *params;
-    };
+	struct AggInst_t {
+		TypeData *aggregate;
+		ExpressionNode *params;
+	};
 
-    struct Array_t {
-	ExpressionNode *dimension;
-	bool isVarLen;
-	bool isStatic;
-    };
+	struct Array_t {
+		ExpressionNode *dimension;
+		bool isVarLen;
+		bool isStatic;
+	};
 
-    struct Enumeration_t {
-	std::string name;
-	DeclarationNode *constants;
-    };
+	struct Enumeration_t {
+		std::string name;
+		DeclarationNode *constants;
+	};
 
-    struct Function_t {
-	DeclarationNode *params;
-	DeclarationNode *idList;			// old-style
-	DeclarationNode *oldDeclList;
-	StatementNode *body;
-	bool hasBody;
-	bool newStyle;
-    };
+	struct Function_t {
+		DeclarationNode *params;
+		DeclarationNode *idList;						// old-style
+		DeclarationNode *oldDeclList;
+		StatementNode *body;
+		bool hasBody;
+		bool newStyle;
+	};
 
-    struct Symbolic_t {
-	std::string name;
-	bool isTypedef;
-	DeclarationNode *params;
-	ExpressionNode *actuals;
-	DeclarationNode *assertions;
-    };
+	struct Symbolic_t {
+		std::string name;
+		bool isTypedef;
+		DeclarationNode *params;
+		ExpressionNode *actuals;
+		DeclarationNode *assertions;
+	};
 
-    struct Variable_t {
-	DeclarationNode::TypeClass tyClass;
-	std::string name;
-	DeclarationNode *assertions;
-    };
+	struct Variable_t {
+		DeclarationNode::TypeClass tyClass;
+		std::string name;
+		DeclarationNode *assertions;
+	};
 
-    struct Tuple_t {
-	DeclarationNode *members;
-    };
+	struct Tuple_t {
+		DeclarationNode *members;
+	};
   
-    struct Typeof_t {
-	ExpressionNode *expr;
-    };
+	struct Typeof_t {
+		ExpressionNode *expr;
+	};
 
-    struct Attr_t {
-	std::string name;
-	ExpressionNode *expr;
-	DeclarationNode *type;
-    };
+	struct Attr_t {
+		std::string name;
+		ExpressionNode *expr;
+		DeclarationNode *type;
+	};
 
-    union {
-	Basic_t *basic;
-	Aggregate_t *aggregate;
-	AggInst_t *aggInst;
-	Array_t *array;
-	Enumeration_t *enumeration;
-	Function_t *function;
-	Symbolic_t *symbolic;
-	Variable_t *variable;
-	Tuple_t *tuple;
-	Typeof_t *typeexpr;
-	Attr_t *attr;
-    };
+	union {
+		Basic_t *basic;
+		Aggregate_t *aggregate;
+		AggInst_t *aggInst;
+		Array_t *array;
+		Enumeration_t *enumeration;
+		Function_t *function;
+		Symbolic_t *symbolic;
+		Variable_t *variable;
+		Tuple_t *tuple;
+		Typeof_t *typeexpr;
+		Attr_t *attr;
+	};
 
-    TypeData *extractAggregate( bool toplevel = true ) const;
-    // helper function for DeclNodeImpl::build
-    Declaration * buildDecl( std::string name, Declaration::StorageClass sc, Expression *bitfieldWidth, bool isInline, LinkageSpec::Type linkage, Initializer *init = 0 ) const;
-    // helper functions for build()
-    Type::Qualifiers buildQualifiers() const;
-    Type *buildBasicType() const;
-    PointerType * buildPointer() const;
-    ArrayType * buildArray() const;
-    AggregateDecl * buildAggregate() const;
-    ReferenceToType * buildAggInst() const;
-    NamedTypeDecl * buildSymbolic( const std::string &name, Declaration::StorageClass sc ) const;
-    TypeDecl* buildVariable() const;
-    EnumDecl* buildEnum() const;
-    TypeInstType * buildSymbolicInst() const;
-    TupleType * buildTuple() const;
-    TypeofType * buildTypeof() const;
-    AttrType * buildAttr() const;
+	TypeData *extractAggregate( bool toplevel = true ) const;
+	// helper function for DeclNodeImpl::build
+	Declaration * buildDecl( std::string name, Declaration::StorageClass sc, Expression *bitfieldWidth, bool isInline, LinkageSpec::Type linkage, Initializer *init = 0 ) const;
+	// helper functions for build()
+	Type::Qualifiers buildQualifiers() const;
+	Type *buildBasicType() const;
+	PointerType * buildPointer() const;
+	ArrayType * buildArray() const;
+	AggregateDecl * buildAggregate() const;
+	ReferenceToType * buildAggInst() const;
+	NamedTypeDecl * buildSymbolic( const std::string &name, Declaration::StorageClass sc ) const;
+	TypeDecl* buildVariable() const;
+	EnumDecl* buildEnum() const;
+	TypeInstType * buildSymbolicInst() const;
+	TupleType * buildTuple() const;
+	TypeofType * buildTypeof() const;
+	AttrType * buildAttr() const;
 };
 
 #endif // TYPEDATA_H
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/TypedefTable.cc
===================================================================
--- translator/Parser/TypedefTable.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/TypedefTable.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// TypedefTable.cc -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 15:20:13 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 15:24:03 2015
+// Update Count     : 2
+//
+
 #include <map>
 #include <list>
@@ -7,138 +22,144 @@
 #if 0
 #include <iostream>
-#  define debugPrint(x) cerr << x
+#define debugPrint(x ) cerr << x
 #else
-#  define debugPrint(x)
+#define debugPrint( x )
 #endif
 
-TypedefTable::TypedefTable() : currentScope(0) {}
+TypedefTable::TypedefTable() : currentScope( 0 ) {}
 
-bool TypedefTable::isKind(string identifier, kind_t kind) const {
-    tableType::const_iterator id_pos = table.find(identifier);
-    if (id_pos == table.end()) {
-	return true;
-    } else {
-	return (*((*id_pos).second.begin())).kind == kind;
-    }
+bool TypedefTable::isKind( string identifier, kind_t kind ) const {
+	tableType::const_iterator id_pos = table.find( identifier );
+	if ( id_pos == table.end()) {
+		return true;
+	} else {
+		return (*((*id_pos ).second.begin())).kind == kind;
+	}
 }
 
-bool TypedefTable::isIdentifier(string identifier) const {
-    return isKind(identifier, ID);
+bool TypedefTable::isIdentifier( string identifier ) const {
+	return isKind( identifier, ID );
 }
 
-bool TypedefTable::isTypedef(string identifier) const {
-    return isKind(identifier, TD);
+bool TypedefTable::isTypedef( string identifier ) const {
+	return isKind( identifier, TD );
 }
 
-bool TypedefTable::isTypegen(string identifier) const {
-    return isKind(identifier, TG);
+bool TypedefTable::isTypegen( string identifier ) const {
+	return isKind( identifier, TG );
 }
 
-void TypedefTable::addToScope(const std::string &identifier, kind_t kind, int scope) {
-    if ( currentContext != "" && scope == contextScope ) {
-	DeferredEntry entry = { identifier, kind };
-	contexts[currentContext].push_back( entry );
-    } else {
-	debugPrint( "Adding " << identifier << " as type " << kind << " scope " << scope << " from scope " << currentScope << endl );
-	Entry newEntry = { scope, kind };
-	tableType::iterator curPos = table.find(identifier);
-	if (curPos == table.end()) {
-	    list<Entry> newList;
-	    newList.push_front(newEntry);
-	    table[identifier] = newList;
+void TypedefTable::addToScope( const std::string &identifier, kind_t kind, int scope ) {
+	if ( currentContext != "" && scope == contextScope ) {
+		DeferredEntry entry = { identifier, kind };
+		contexts[currentContext].push_back( entry );
 	} else {
-	    list<Entry>::iterator listPos = (*curPos).second.begin();
-	    while( listPos != (*curPos).second.end() && listPos->scope > scope ) {
-		listPos++;
-	    }
-	    (*curPos).second.insert(listPos, newEntry);
+		debugPrint( "Adding " << identifier << " as type " << kind << " scope " << scope << " from scope " << currentScope << endl );
+		Entry newEntry = { scope, kind };
+		tableType::iterator curPos = table.find( identifier );
+		if ( curPos == table.end()) {
+			list<Entry> newList;
+			newList.push_front( newEntry );
+			table[identifier] = newList;
+		} else {
+			list<Entry>::iterator listPos = (*curPos ).second.begin();
+			while( listPos != (*curPos ).second.end() && listPos->scope > scope ) {
+				listPos++;
+			}
+			(*curPos ).second.insert( listPos, newEntry );
+		}
 	}
-    }
 }
 
-void TypedefTable::addToCurrentScope(const std::string &identifier, kind_t kind) {
-    addToScope( identifier, kind, currentScope );
+void TypedefTable::addToCurrentScope( const std::string &identifier, kind_t kind ) {
+	addToScope( identifier, kind, currentScope );
 }
 
-void TypedefTable::addToCurrentScope(kind_t kind) {
-    addToCurrentScope( nextIdentifiers.top(), kind );
+void TypedefTable::addToCurrentScope( kind_t kind ) {
+	addToCurrentScope( nextIdentifiers.top(), kind );
 }
 
-void TypedefTable::addToEnclosingScope(const std::string &identifier, kind_t kind) {
-    assert( currentScope >= 1 );
-    addToScope( identifier, kind, currentScope - 1 );
+void TypedefTable::addToEnclosingScope( const std::string &identifier, kind_t kind ) {
+	assert( currentScope >= 1 );
+	addToScope( identifier, kind, currentScope - 1 );
 }
 
-void TypedefTable::addToEnclosingScope(kind_t kind) {
-    addToEnclosingScope( nextIdentifiers.top(), kind );
+void TypedefTable::addToEnclosingScope( kind_t kind ) {
+	addToEnclosingScope( nextIdentifiers.top(), kind );
 }
 
-void TypedefTable::addToEnclosingScope2(const std::string &identifier, kind_t kind) {
-    assert( currentScope >= 2 );
-    addToScope( identifier, kind, currentScope - 2 );
+void TypedefTable::addToEnclosingScope2( const std::string &identifier, kind_t kind ) {
+	assert( currentScope >= 2 );
+	addToScope( identifier, kind, currentScope - 2 );
 }
 
-void TypedefTable::addToEnclosingScope2(kind_t kind) {
-    addToEnclosingScope2( nextIdentifiers.top(), kind );
+void TypedefTable::addToEnclosingScope2( kind_t kind ) {
+	addToEnclosingScope2( nextIdentifiers.top(), kind );
 }
 
 void TypedefTable::setNextIdentifier( const std::string &identifier ) {
-    nextIdentifiers.top() = identifier;
+	nextIdentifiers.top() = identifier;
 }
 
 void TypedefTable::openContext( std::string contextName ) {
-    map< string, deferListType >::iterator i = contexts.find( contextName );
-    if ( i != contexts.end() ) {
-	deferListType &entries = i->second;
-	for (deferListType::iterator i = entries.begin(); i != entries.end(); i++) {
-	    addToEnclosingScope( i->identifier, i->kind );
+	map< string, deferListType >::iterator i = contexts.find( contextName );
+	if ( i != contexts.end() ) {
+		deferListType &entries = i->second;
+		for ( deferListType::iterator i = entries.begin(); i != entries.end(); i++) {
+			addToEnclosingScope( i->identifier, i->kind );
+		}
 	}
-    }
 }
 
-void TypedefTable::enterScope(void) {
-    currentScope += 1;
-    deferListStack.push( deferListType() );
-    nextIdentifiers.push( "" );
-    debugPrint( "Entering scope " << currentScope << ", nextIdentifiers size is " << nextIdentifiers.size() << endl );
+void TypedefTable::enterScope( void ) {
+	currentScope += 1;
+	deferListStack.push( deferListType() );
+	nextIdentifiers.push( "" );
+	debugPrint( "Entering scope " << currentScope << ", nextIdentifiers size is " << nextIdentifiers.size() << endl );
 }
 
-void TypedefTable::leaveScope(void) {
-    debugPrint( "Leaving scope " << currentScope << endl );
-    for (tableType::iterator i = table.begin(); i != table.end(); ) {
-	list<Entry> &declList = (*i).second;
-	while (!declList.empty() && declList.front().scope == currentScope) {
-	    declList.pop_front();
+void TypedefTable::leaveScope( void ) {
+	debugPrint( "Leaving scope " << currentScope << endl );
+	for ( tableType::iterator i = table.begin(); i != table.end(); ) {
+		list<Entry> &declList = (*i ).second;
+		while (!declList.empty() && declList.front().scope == currentScope ) {
+			declList.pop_front();
+		}
+		if ( declList.empty() ) {			// standard idom for erasing during traversal
+			table.erase( i++ );
+		} else ++i;
 	}
-	if ( declList.empty() ) {			// standard idom for erasing during traversal
-	    table.erase( i++ );
-	} else ++i;
-    }
-    currentScope -= 1;
-    for (deferListType::iterator i = deferListStack.top().begin(); i != deferListStack.top().end(); i++) {
-	addToCurrentScope( i->identifier, i->kind );
-    }
-    deferListStack.pop();
-    debugPrint( "nextIdentifiers size is " << nextIdentifiers.size() << " top is " << nextIdentifiers.top() << endl );
-    nextIdentifiers.pop();
+	currentScope -= 1;
+	for ( deferListType::iterator i = deferListStack.top().begin(); i != deferListStack.top().end(); i++) {
+		addToCurrentScope( i->identifier, i->kind );
+	}
+	deferListStack.pop();
+	debugPrint( "nextIdentifiers size is " << nextIdentifiers.size() << " top is " << nextIdentifiers.top() << endl );
+	nextIdentifiers.pop();
 }
 
 void TypedefTable::enterContext( std::string contextName ) {
-    currentContext = contextName;
-    contextScope = currentScope;
+	currentContext = contextName;
+	contextScope = currentScope;
 }
 
-void TypedefTable::leaveContext(void) {
-    currentContext = "";
+void TypedefTable::leaveContext( void ) {
+	currentContext = "";
 }
 
-void TypedefTable::print(void) const {
-    for (tableType::const_iterator i = table.begin(); i != table.end(); i++) {
-	debugPrint( (*i).first << ": " );
-	list<Entry> declList = (*i).second;
-	for (list<Entry>::const_iterator j = declList.begin(); j != declList.end(); j++) {
-	    debugPrint( "(" << (*j).scope << " " << (*j).kind << ") " );
+void TypedefTable::print( void ) const {
+	for ( tableType::const_iterator i = table.begin(); i != table.end(); i++) {
+		debugPrint( (*i ).first << ": " );
+		list<Entry> declList = (*i ).second;
+		for ( list<Entry>::const_iterator j = declList.begin(); j != declList.end(); j++ ) {
+			debugPrint( "(" << (*j ).scope << " " << (*j).kind << ") " );
+		}
+		debugPrint( endl );
 	}
-	debugPrint( endl );
-    }
 }
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/TypedefTable.h
===================================================================
--- translator/Parser/TypedefTable.h	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/TypedefTable.h	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,2 +1,17 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// TypedefTable.h -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 15:24:36 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 15:25:59 2015
+// Update Count     : 3
+//
+
 #ifndef TYPEDEFTABLE_H
 #define TYPEDEFTABLE_H
@@ -9,66 +24,72 @@
 class TypedefTable {
   public:
-    enum kind_t { ID, TD, TG };
+	enum kind_t { ID, TD, TG };
   private:
-    struct Entry {
-	int scope;
-	kind_t kind;
-    };
-    
-    struct DeferredEntry {
-	std::string identifier;
-	kind_t kind;
-    };
+	struct Entry {
+		int scope;
+		kind_t kind;
+	};
+	
+	struct DeferredEntry {
+		std::string identifier;
+		kind_t kind;
+	};
 
-    typedef std::map<std::string, std::list<Entry> > tableType;
-    tableType table;
+	typedef std::map<std::string, std::list<Entry> > tableType;
+	tableType table;
 
-    int currentScope;
-    std::string currentContext;
-    int contextScope;
-    
-    typedef std::list< DeferredEntry > deferListType;
-    std::stack< deferListType > deferListStack;
-    std::map< std::string, deferListType > contexts;
-    
-    std::stack< std::string > nextIdentifiers;
+	int currentScope;
+	std::string currentContext;
+	int contextScope;
+	
+	typedef std::list< DeferredEntry > deferListType;
+	std::stack< deferListType > deferListStack;
+	std::map< std::string, deferListType > contexts;
+	
+	std::stack< std::string > nextIdentifiers;
 
-    bool isKind( std::string identifier, kind_t kind ) const;
-    void addToScope( const std::string &identifier, kind_t kind, int scope );
+	bool isKind( std::string identifier, kind_t kind ) const;
+	void addToScope( const std::string &identifier, kind_t kind, int scope );
   public:
-    TypedefTable();
+	TypedefTable();
 
-    bool isIdentifier( std::string identifier ) const;
-    bool isTypedef( std::string identifier ) const;
-    bool isTypegen( std::string identifier ) const;
-    
-    // "addToCurrentScope" adds the identifier/type pair to the current scope This does less than you think it does,
-    // since each declaration is within its own scope.  Mostly useful for type parameters.
-    void addToCurrentScope( const std::string &identifier, kind_t kind );
-    void addToCurrentScope( kind_t kind );		// use nextIdentifiers.top()
+	bool isIdentifier( std::string identifier ) const;
+	bool isTypedef( std::string identifier ) const;
+	bool isTypegen( std::string identifier ) const;
+	
+	// "addToCurrentScope" adds the identifier/type pair to the current scope This does less than you think it does,
+	// since each declaration is within its own scope.  Mostly useful for type parameters.
+	void addToCurrentScope( const std::string &identifier, kind_t kind );
+	void addToCurrentScope( kind_t kind );		// use nextIdentifiers.top()
 
-    // "addToEnclosingScope" adds the identifier/type pair to the scope that encloses the current one.  This is the
-    // right way to handle type and typedef names
-    void addToEnclosingScope( const std::string &identifier, kind_t kind );
-    void addToEnclosingScope( kind_t kind );		// use nextIdentifiers.top()
-    
-    // "addToEnclosingScope2" adds the identifier/type pair to the scope that encloses the scope enclosing the the
-    // current one.  This is the right way to handle assertion names
-    void addToEnclosingScope2( const std::string &identifier, kind_t kind );
-    void addToEnclosingScope2( kind_t kind );		// use nextIdentifiers.top()
-    
-    // set the next identifier to be used by an "add" operation without an identifier parameter within the current scope
-    void setNextIdentifier( const std::string &identifier );
-    
-    // dump the definitions from a pre-defined context into the current scope
-    void openContext( std::string contextName );
-    
-    void enterScope( void );
-    void leaveScope( void );
-    void enterContext( std::string contextName );
-    void leaveContext( void );
+	// "addToEnclosingScope" adds the identifier/type pair to the scope that encloses the current one.  This is the
+	// right way to handle type and typedef names
+	void addToEnclosingScope( const std::string &identifier, kind_t kind );
+	void addToEnclosingScope( kind_t kind );		// use nextIdentifiers.top()
+	
+	// "addToEnclosingScope2" adds the identifier/type pair to the scope that encloses the scope enclosing the the
+	// current one.  This is the right way to handle assertion names
+	void addToEnclosingScope2( const std::string &identifier, kind_t kind );
+	void addToEnclosingScope2( kind_t kind );		// use nextIdentifiers.top()
+	
+	// set the next identifier to be used by an "add" operation without an identifier parameter within the current scope
+	void setNextIdentifier( const std::string &identifier );
+	
+	// dump the definitions from a pre-defined context into the current scope
+	void openContext( std::string contextName );
+	
+	void enterScope();
+	void leaveScope();
+	void enterContext( std::string contextName );
+	void leaveContext();
 
-    void print( void ) const;
+	void print() const;
 };
 
 #endif // TYPEDEFTABLE_H
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/cfa.y
===================================================================
--- translator/Parser/cfa.y	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/cfa.y	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,6 +1,8 @@
-//                              -*- Mode: C++ -*- 
-// 
-// CForall Grammar Version 1.0, Copyright (C) Peter A. Buhr 2001
-// 
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
 // cfa.y -- 
 // 
@@ -8,17 +10,18 @@
 // Created On       : Sat Sep  1 20:22:55 2001
 // Last Modified By : Peter A. Buhr
-// Last Modified On : Tue May 12 17:24:53 2015
-// Update Count     : 963
+// Last Modified On : Sat May 16 11:55:39 2015
+// Update Count     : 975
 // 
 
-// This grammar is based on the ANSI99/11 C grammar, specifically parts of EXPRESSION and STATEMENTS, and on the C
-// grammar by James A. Roskind, specifically parts of DECLARATIONS and EXTERNAL DEFINITIONS.  While parts have been
-// copied, important changes have been made in all sections; these changes are sufficient to constitute a new grammar.
-// In particular, this grammar attempts to be more syntactically precise, i.e., it parses less incorrect language syntax
-// that must be subsequently rejected by semantic checks.  Nevertheless, there are still several semantic checks
-// required and many are noted in the grammar. Finally, the grammar is extended with GCC and CFA language extensions.
-
-// Acknowledgments to Richard Bilson, Glen Ditchfield, and Rodolfo Gabriel Esteves who all helped when I got stuck with
-// the grammar.
+// This grammar is based on the ANSI99/11 C grammar, specifically parts of EXPRESSION and STATEMENTS, and on
+// the C grammar by James A. Roskind, specifically parts of DECLARATIONS and EXTERNAL DEFINITIONS.  While
+// parts have been copied, important changes have been made in all sections; these changes are sufficient to
+// constitute a new grammar.  In particular, this grammar attempts to be more syntactically precise, i.e., it
+// parses less incorrect language syntax that must be subsequently rejected by semantic checks.  Nevertheless,
+// there are still several semantic checks required and many are noted in the grammar. Finally, the grammar is
+// extended with GCC and CFA language extensions.
+
+// Acknowledgments to Richard Bilson, Glen Ditchfield, and Rodolfo Gabriel Esteves who all helped when I got
+// stuck with the grammar.
 
 // The root language for this grammar is ANSI99/11 C. All of ANSI99/11 is parsed, except for:
@@ -26,6 +29,6 @@
 // 1. designation with '=' (use ':' instead)
 //
-// Most of the syntactic extensions from ANSI90 to ANSI11 C are marked with the comment "C99/C11". This grammar also has
-// two levels of extensions. The first extensions cover most of the GCC C extensions, except for:
+// Most of the syntactic extensions from ANSI90 to ANSI11 C are marked with the comment "C99/C11". This
+// grammar also has two levels of extensions. The first extensions cover most of the GCC C extensions, except for:
 //
 // 1. nested functions
@@ -34,13 +37,13 @@
 // 4. attributes not allowed in parenthesis of declarator
 //
-// All of the syntactic extensions for GCC C are marked with the comment "GCC". The second extensions are for Cforall
-// (CFA), which fixes several of C's outstanding problems and extends C with many modern language concepts. All of the
-// syntactic extensions for CFA C are marked with the comment "CFA". As noted above, there is one unreconcileable
-// parsing problem between C99 and CFA with respect to designators; this is discussed in detail before the "designation"
-// grammar rule.
+// All of the syntactic extensions for GCC C are marked with the comment "GCC". The second extensions are for
+// Cforall (CFA), which fixes several of C's outstanding problems and extends C with many modern language
+// concepts. All of the syntactic extensions for CFA C are marked with the comment "CFA". As noted above,
+// there is one unreconcileable parsing problem between C99 and CFA with respect to designators; this is
+// discussed in detail before the "designation" grammar rule.
 
 %{
-#define YYDEBUG_LEXER_TEXT (yylval)			// lexer loads this up each time
-#define YYDEBUG 1					// get the pretty debugging code to compile
+#define YYDEBUG_LEXER_TEXT (yylval)						// lexer loads this up each time
+#define YYDEBUG 1										// get the pretty debugging code to compile
 
 #undef __GNUC_MINOR__
@@ -53,5 +56,5 @@
 #include "LinkageSpec.h"
 
-DeclarationNode *theTree = 0;				// the resulting parse tree
+DeclarationNode *theTree = 0;							// the resulting parse tree
 LinkageSpec::Type linkage = LinkageSpec::Cforall;
 std::stack< LinkageSpec::Type > linkageStack;
@@ -64,52 +67,52 @@
 %token TYPEDEF
 %token AUTO EXTERN REGISTER STATIC
-%token INLINE						// C99
-%token FORTRAN						// C99, extension ISO/IEC 9899:1999 Section J.5.9(1)
+%token INLINE											// C99
+%token FORTRAN											// C99, extension ISO/IEC 9899:1999 Section J.5.9(1)
 %token CONST VOLATILE
-%token RESTRICT						// C99
-%token FORALL LVALUE					// CFA
+%token RESTRICT											// C99
+%token FORALL LVALUE									// CFA
 %token VOID CHAR SHORT INT LONG FLOAT DOUBLE SIGNED UNSIGNED
-%token BOOL COMPLEX IMAGINARY				// C99
-%token TYPEOF LABEL					// GCC
+%token BOOL COMPLEX IMAGINARY							// C99
+%token TYPEOF LABEL										// GCC
 %token ENUM STRUCT UNION
-%token TYPE FTYPE DTYPE CONTEXT				// CFA
+%token TYPE FTYPE DTYPE CONTEXT							// CFA
 %token SIZEOF
-%token ATTRIBUTE EXTENSION				// GCC
+%token ATTRIBUTE EXTENSION								// GCC
 %token IF ELSE SWITCH CASE DEFAULT DO WHILE FOR BREAK CONTINUE GOTO RETURN
-%token CHOOSE FALLTHRU TRY CATCH FINALLY THROW		// CFA
-%token ASM						// C99, extension ISO/IEC 9899:1999 Section J.5.10(1)
+%token CHOOSE FALLTHRU TRY CATCH FINALLY THROW			// CFA
+%token ASM												// C99, extension ISO/IEC 9899:1999 Section J.5.10(1)
 %token ALIGNAS ALIGNOF ATOMIC GENERIC NORETURN STATICASSERT THREADLOCAL // C11
 
 // names and constants: lexer differentiates between identifier and typedef names
-%token<tok> IDENTIFIER		QUOTED_IDENTIFIER	TYPEDEFname		TYPEGENname
-%token<tok> ATTR_IDENTIFIER	ATTR_TYPEDEFname	ATTR_TYPEGENname
-%token<tok> INTEGERconstant	FLOATINGconstant	CHARACTERconstant       STRINGliteral
-%token<tok> ZERO		ONE			// CFA
+%token<tok> IDENTIFIER			QUOTED_IDENTIFIER		TYPEDEFname				TYPEGENname
+%token<tok> ATTR_IDENTIFIER		ATTR_TYPEDEFname		ATTR_TYPEGENname
+%token<tok> INTEGERconstant		FLOATINGconstant		CHARACTERconstant		STRINGliteral
+%token<tok> ZERO				ONE						// CFA
 
 // multi-character operators
-%token ARROW			/* ->				*/
-%token ICR DECR			/* ++	--			*/
-%token LS RS			/* <<	>>			*/
-%token LE GE EQ NE		/* <=	>=	==	!=	*/
-%token ANDAND OROR		/* &&	||			*/
-%token ELLIPSIS			/* ...				*/
-
-%token MULTassign	DIVassign	MODassign	/* *=	/=	%=	*/
-%token PLUSassign	MINUSassign			/* +=	-=		*/
-%token LSassign		RSassign			/* <<=	>>=		*/
-%token ANDassign	ERassign	ORassign	/* &=	^=	|=	*/
+%token ARROW											// ->
+%token ICR DECR											// ++	--
+%token LS RS											// <<	>>
+%token LE GE EQ NE										// <=	>=	==	!=
+%token ANDAND OROR										// &&	||
+%token ELLIPSIS											// ...
+
+%token MULTassign	DIVassign	MODassign				// *=	/=	%=/
+%token PLUSassign	MINUSassign							// +=	-=
+%token LSassign		RSassign							// <<=	>>=
+%token ANDassign	ERassign	ORassign				// &=	^=	|=
 
 // Types declaration
 %union
 {
-    Token tok;
-    ParseNode *pn;
-    ExpressionNode *en;
-    DeclarationNode *decl;
-    DeclarationNode::TyCon aggKey;
-    DeclarationNode::TypeClass tclass;
-    StatementNode *sn;
-    ConstantNode *constant;
-    InitializerNode *in;
+	Token tok;
+	ParseNode *pn;
+	ExpressionNode *en;
+	DeclarationNode *decl;
+	DeclarationNode::TyCon aggKey;
+	DeclarationNode::TypeClass tclass;
+	StatementNode *sn;
+	ConstantNode *constant;
+	InitializerNode *in;
 }
 
@@ -120,26 +123,26 @@
 // expressions
 %type<constant> constant
-%type<en> tuple				tuple_expression_list
-%type<en> unary_operator                assignment_operator
-%type<en> primary_expression		postfix_expression		unary_expression
-%type<en> cast_expression		multiplicative_expression	additive_expression	shift_expression
-%type<en> relational_expression		equality_expression		AND_expression		exclusive_OR_expression
-%type<en> inclusive_OR_expression	logical_AND_expression		logical_OR_expression	conditional_expression
-%type<en> constant_expression		assignment_expression		assignment_expression_opt
-%type<en> comma_expression		comma_expression_opt
-%type<en> argument_expression_list	argument_expression		for_control_expression	assignment_opt
+%type<en> tuple							tuple_expression_list
+%type<en> unary_operator				assignment_operator
+%type<en> primary_expression			postfix_expression			unary_expression
+%type<en> cast_expression				multiplicative_expression	additive_expression			shift_expression
+%type<en> relational_expression			equality_expression			AND_expression				exclusive_OR_expression
+%type<en> inclusive_OR_expression		logical_AND_expression		logical_OR_expression		conditional_expression
+%type<en> constant_expression			assignment_expression		assignment_expression_opt
+%type<en> comma_expression				comma_expression_opt
+%type<en> argument_expression_list		argument_expression			for_control_expression		assignment_opt
 %type<en> subrange
 
 // statements
-%type<sn> labeled_statement	compound_statement      expression_statement	selection_statement
-%type<sn> iteration_statement	jump_statement		exception_statement	asm_statement
-%type<sn> fall_through_opt	fall_through
-%type<sn> statement		statement_list
-%type<sn> block_item_list	block_item
+%type<sn> labeled_statement				compound_statement			expression_statement		selection_statement
+%type<sn> iteration_statement			jump_statement				exception_statement			asm_statement
+%type<sn> fall_through_opt				fall_through
+%type<sn> statement						statement_list
+%type<sn> block_item_list				block_item
 %type<sn> case_clause
-%type<en> case_value		case_value_list
-%type<sn> case_label		case_label_list
-%type<sn> switch_clause_list_opt switch_clause_list	choose_clause_list_opt	choose_clause_list
-%type<pn> handler_list		handler_clause		finally_clause
+%type<en> case_value					case_value_list
+%type<sn> case_label					case_label_list
+%type<sn> switch_clause_list_opt		switch_clause_list			choose_clause_list_opt		choose_clause_list
+%type<pn> handler_list					handler_clause				finally_clause
 
 // declarations
@@ -232,1301 +235,1300 @@
 
 
-// Handle single shift/reduce conflict for dangling else by shifting the ELSE token. For example, this string is
-// ambiguous:
-// .---------.			matches IF '(' comma_expression ')' statement
+// Handle single shift/reduce conflict for dangling else by shifting the ELSE token. For example, this string
+// is ambiguous:
+// .---------.				matches IF '(' comma_expression ')' statement
 // if ( C ) S1 else S2
-// `-----------------'	matches IF '(' comma_expression ')' statement ELSE statement */
+// `-----------------'		matches IF '(' comma_expression ')' statement ELSE statement */
 
 %nonassoc THEN	// rule precedence for IF '(' comma_expression ')' statement
 %nonassoc ELSE	// token precedence for start of else clause in IF statement
 
-%start translation_unit					// parse-tree root
+%start translation_unit									// parse-tree root
 
 %%
 //************************* Namespace Management ********************************
 
-// The grammar in the ANSI C standard is not strictly context-free, since it relies upon the distinct terminal symbols
-// "identifier" and "TYPEDEFname" that are lexically identical.  While it is possible to write a purely context-free
-// grammar, such a grammar would obscure the relationship between syntactic and semantic constructs.  Hence, this
-// grammar uses the ANSI style.
-//
-// Cforall compounds this problem by introducing type names local to the scope of a declaration (for instance, those
-// introduced through "forall" qualifiers), and by introducing "type generators" -- parametrized types.  This latter
-// type name creates a third class of identifiers that must be distinguished by the scanner.
-//
-// Since the scanner cannot distinguish among the different classes of identifiers without some context information, it
-// accesses a data structure (the TypedefTable) to allow classification of an identifier that it has just read.
-// Semantic actions during the parser update this data structure when the class of identifiers change.
-//
-// Because the Cforall language is block-scoped, there is the possibility that an identifier can change its class in a
-// local scope; it must revert to its original class at the end of the block.  Since type names can be local to a
-// particular declaration, each declaration is itself a scope.  This requires distinguishing between type names that are
-// local to the current declaration scope and those that persist past the end of the declaration (i.e., names defined in
-// "typedef" or "type" declarations).
-//
-// The non-terminals "push" and "pop" derive the empty string; their only use is to denote the opening and closing of
-// scopes.  Every push must have a matching pop, although it is regrettable the matching pairs do not always occur
-// within the same rule.  These non-terminals may appear in more contexts than strictly necessary from a semantic point
-// of view.  Unfortunately, these extra rules are necessary to prevent parsing conflicts -- the parser may not have
-// enough context and look-ahead information to decide whether a new scope is necessary, so the effect of these extra
-// rules is to open a new scope unconditionally.  As the grammar evolves, it may be neccesary to add or move around
-// "push" and "pop" nonterminals to resolve conflicts of this sort.
+// The grammar in the ANSI C standard is not strictly context-free, since it relies upon the distinct terminal
+// symbols "identifier" and "TYPEDEFname" that are lexically identical.  While it is possible to write a
+// purely context-free grammar, such a grammar would obscure the relationship between syntactic and semantic
+// constructs.  Hence, this grammar uses the ANSI style.
+//
+// Cforall compounds this problem by introducing type names local to the scope of a declaration (for instance,
+// those introduced through "forall" qualifiers), and by introducing "type generators" -- parametrized types.
+// This latter type name creates a third class of identifiers that must be distinguished by the scanner.
+//
+// Since the scanner cannot distinguish among the different classes of identifiers without some context
+// information, it accesses a data structure (the TypedefTable) to allow classification of an identifier that
+// it has just read.  Semantic actions during the parser update this data structure when the class of
+// identifiers change.
+//
+// Because the Cforall language is block-scoped, there is the possibility that an identifier can change its
+// class in a local scope; it must revert to its original class at the end of the block.  Since type names can
+// be local to a particular declaration, each declaration is itself a scope.  This requires distinguishing
+// between type names that are local to the current declaration scope and those that persist past the end of
+// the declaration (i.e., names defined in "typedef" or "type" declarations).
+//
+// The non-terminals "push" and "pop" derive the empty string; their only use is to denote the opening and
+// closing of scopes.  Every push must have a matching pop, although it is regrettable the matching pairs do
+// not always occur within the same rule.  These non-terminals may appear in more contexts than strictly
+// necessary from a semantic point of view.  Unfortunately, these extra rules are necessary to prevent parsing
+// conflicts -- the parser may not have enough context and look-ahead information to decide whether a new
+// scope is necessary, so the effect of these extra rules is to open a new scope unconditionally.  As the
+// grammar evolves, it may be neccesary to add or move around "push" and "pop" nonterminals to resolve
+// conflicts of this sort.
 
 push:
-		{
-		    typedefTable.enterScope();
-		}
-	;
+				{
+					typedefTable.enterScope();
+				}
+		;
 
 pop:
-		{
-		    typedefTable.leaveScope();
-		}
-	;
+				{
+					typedefTable.leaveScope();
+				}
+		;
 
 //************************* CONSTANTS ********************************
 
 constant:
-		// ENUMERATIONconstant is not included here; it is treated as a variable with type "enumeration
-		// constant".
-	INTEGERconstant					{ $$ = new ConstantNode(ConstantNode::Integer,   $1); }
-	| FLOATINGconstant				{ $$ = new ConstantNode(ConstantNode::Float,     $1); }
-	| CHARACTERconstant				{ $$ = new ConstantNode(ConstantNode::Character, $1); }
-	;
+				// ENUMERATIONconstant is not included here; it is treated as a variable with type
+				// "enumeration constant".
+		INTEGERconstant									{ $$ = new ConstantNode(ConstantNode::Integer, $1); }
+		| FLOATINGconstant								{ $$ = new ConstantNode(ConstantNode::Float, $1); }
+		| CHARACTERconstant								{ $$ = new ConstantNode(ConstantNode::Character, $1); }
+		;
 
 identifier:
-	IDENTIFIER
-	| ATTR_IDENTIFIER				// CFA
-	| zero_one					// CFA
-	;
+		IDENTIFIER
+		| ATTR_IDENTIFIER								// CFA
+		| zero_one										// CFA
+		;
 
 no_01_identifier:
-	IDENTIFIER
-	| ATTR_IDENTIFIER				// CFA
-	;
+		IDENTIFIER
+		| ATTR_IDENTIFIER								// CFA
+		;
 
 no_attr_identifier:
-	IDENTIFIER
-	;
-
-zero_one:						// CFA
-	ZERO
-	| ONE
-	;
-
-string_literal_list:					// juxtaposed strings are concatenated
-	STRINGliteral					{ $$ = new ConstantNode(ConstantNode::String, $1); }
-	| string_literal_list STRINGliteral		{ $$ = $1->append( $2 ); }
-	;
+		IDENTIFIER
+		;
+
+zero_one:												// CFA
+		ZERO
+		| ONE
+		;
+
+string_literal_list:									// juxtaposed strings are concatenated
+		STRINGliteral									{ $$ = new ConstantNode(ConstantNode::String, $1); }
+		| string_literal_list STRINGliteral				{ $$ = $1->append( $2 ); }
+		;
 
 //************************* EXPRESSIONS ********************************
 
 primary_expression:
-	IDENTIFIER					// typedef name cannot be used as a variable name
-		{ $$ = new VarRefNode($1); }
-	| zero_one
-		{ $$ = new VarRefNode($1); }
-	| constant
-		{ $$ = $1; }
-	| string_literal_list
-		{ $$ = $1; }
-	| '(' comma_expression ')'
-		{ $$ = $2; }
-	| '(' compound_statement ')'			// GCC, lambda expression
-		{ $$ = new ValofExprNode($2); }
-	;
+		IDENTIFIER										// typedef name cannot be used as a variable name
+				{ $$ = new VarRefNode($1); }
+		| zero_one
+				{ $$ = new VarRefNode($1); }
+		| constant
+				{ $$ = $1; }
+		| string_literal_list
+				{ $$ = $1; }
+		| '(' comma_expression ')'
+				{ $$ = $2; }
+		| '(' compound_statement ')'					// GCC, lambda expression
+				{ $$ = new ValofExprNode($2); }
+		;
 
 postfix_expression:
-	primary_expression
-	| postfix_expression '[' push assignment_expression pop ']'
-		// CFA, comma_expression disallowed in the context because it results in a commom user error:
-		// subscripting a matrix with x[i,j] instead of x[i][j]. While this change is not backwards
-		// compatible, there seems to be little advantage to this feature and many disadvantages. It is
-		// possible to write x[(i,j)] in CFA, which is equivalent to the old x[i,j].
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Index), $1, $4); }
-	| postfix_expression '(' argument_expression_list ')'
-		{ $$ = new CompositeExprNode($1, $3); }
-	| postfix_expression '.' no_attr_identifier
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::FieldSel), $1, new VarRefNode($3)); }
-	| postfix_expression '.' '[' push field_list pop ']' // CFA, tuple field selector
-	| postfix_expression ARROW no_attr_identifier
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::PFieldSel), $1, new VarRefNode($3)); }
-	| postfix_expression ARROW '[' push field_list pop ']' // CFA, tuple field selector
-	| postfix_expression ICR
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::IncrPost), $1); }
-	| postfix_expression DECR
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::DecrPost), $1); }
-		// GCC has priority: cast_expression
-	| '(' type_name_no_function ')' '{' initializer_list comma_opt '}' // C99
-		{ $$ = 0; }
-	;
+		primary_expression
+		| postfix_expression '[' push assignment_expression pop ']'
+				// CFA, comma_expression disallowed in the context because it results in a commom user error:
+				// subscripting a matrix with x[i,j] instead of x[i][j]. While this change is not backwards
+				// compatible, there seems to be little advantage to this feature and many disadvantages. It
+				// is possible to write x[(i,j)] in CFA, which is equivalent to the old x[i,j].
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Index), $1, $4); }
+		| postfix_expression '(' argument_expression_list ')'
+				{ $$ = new CompositeExprNode($1, $3); }
+		| postfix_expression '.' no_attr_identifier
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::FieldSel), $1, new VarRefNode($3)); }
+		| postfix_expression '.' '[' push field_list pop ']' // CFA, tuple field selector
+		| postfix_expression ARROW no_attr_identifier
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::PFieldSel), $1, new VarRefNode($3)); }
+		| postfix_expression ARROW '[' push field_list pop ']' // CFA, tuple field selector
+		| postfix_expression ICR
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::IncrPost), $1); }
+		| postfix_expression DECR
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::DecrPost), $1); }
+				// GCC has priority: cast_expression
+		| '(' type_name_no_function ')' '{' initializer_list comma_opt '}' // C99
+				{ $$ = 0; }
+		;
 
 argument_expression_list:
-	argument_expression
-	| argument_expression_list ',' argument_expression
-							{ $$ = (ExpressionNode *)($1->set_link($3)); }
-	;
+		argument_expression
+		| argument_expression_list ',' argument_expression
+				{ $$ = (ExpressionNode *)($1->set_link($3)); }
+		;
 
 argument_expression:
-	// empty
-		{ $$ = 0; }				// use default argument
-	| assignment_expression
-	| no_attr_identifier ':' assignment_expression
-							{ $$ = $3->set_asArgName($1); }
-		// Only a list of no_attr_identifier_or_typedef_name is allowed in this context. However, there is
-		// insufficient look ahead to distinguish between this list of parameter names and a tuple, so the
-		// tuple form must be used with an appropriate semantic check.
-	| '[' push assignment_expression pop ']' ':' assignment_expression
-							{ $$ = $7->set_asArgName($3); }
-	| '[' push assignment_expression ',' tuple_expression_list pop ']' ':' assignment_expression
-							{ $$ = $9->set_asArgName(new CompositeExprNode( new OperatorNode( OperatorNode::TupleC ), (ExpressionNode *)$3->set_link( flattenCommas( $5 )))); }
-	;
-
-field_list:						// CFA, tuple field selector
-	field
-	| field_list ',' field				{ $$ = (ExpressionNode *)$1->set_link( $3 ); }
-	;
-
-field:							// CFA, tuple field selector
-	no_attr_identifier
-							{ $$ = new VarRefNode( $1 ); }
-	| no_attr_identifier '.' field
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::FieldSel), new VarRefNode( $1 ), $3); }
-	| no_attr_identifier '.' '[' push field_list pop ']'
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::FieldSel), new VarRefNode( $1 ), $5); }
-	| no_attr_identifier ARROW field
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::PFieldSel), new VarRefNode( $1 ), $3); }
-	| no_attr_identifier ARROW '[' push field_list pop ']'
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::PFieldSel), new VarRefNode( $1 ), $5); }
-	;
+		// empty
+				{ $$ = 0; }								// use default argument
+		| assignment_expression
+		| no_attr_identifier ':' assignment_expression
+				{ $$ = $3->set_asArgName($1); }
+				// Only a list of no_attr_identifier_or_typedef_name is allowed in this context. However,
+				// there is insufficient look ahead to distinguish between this list of parameter names and a
+				// tuple, so the tuple form must be used with an appropriate semantic check.
+		| '[' push assignment_expression pop ']' ':' assignment_expression
+				{ $$ = $7->set_asArgName($3); }
+		| '[' push assignment_expression ',' tuple_expression_list pop ']' ':' assignment_expression
+				{ $$ = $9->set_asArgName(new CompositeExprNode( new OperatorNode( OperatorNode::TupleC ), (ExpressionNode *)$3->set_link( flattenCommas( $5 )))); }
+		;
+
+field_list:												// CFA, tuple field selector
+		field
+		| field_list ',' field							{ $$ = (ExpressionNode *)$1->set_link( $3 ); }
+		;
+
+field:													// CFA, tuple field selector
+		no_attr_identifier
+				{ $$ = new VarRefNode( $1 ); }
+		| no_attr_identifier '.' field
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::FieldSel), new VarRefNode( $1 ), $3); }
+		| no_attr_identifier '.' '[' push field_list pop ']'
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::FieldSel), new VarRefNode( $1 ), $5); }
+		| no_attr_identifier ARROW field
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::PFieldSel), new VarRefNode( $1 ), $3); }
+		| no_attr_identifier ARROW '[' push field_list pop ']'
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::PFieldSel), new VarRefNode( $1 ), $5); }
+		;
 
 unary_expression:
-	postfix_expression
-	| ICR unary_expression
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Incr), $2); }
-	| DECR unary_expression
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Decr), $2); }
-	| EXTENSION cast_expression			// GCC
-		{ $$ = $2; }
-	| unary_operator cast_expression
-		{ $$ = new CompositeExprNode($1, $2); }
-	| '!' cast_expression
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Neg), $2); }
-	| '*' cast_expression				// CFA
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::PointTo), $2); }
-		// '*' is is separated from unary_operator because of shift/reduce conflict in:
-		//	{ * X; } // dereference X
-		//	{ * int X; } // CFA declaration of pointer to int
-		// '&' must be moved here if C++ reference variables are supported.
-	| SIZEOF unary_expression
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::SizeOf), $2); }
-	| SIZEOF '(' type_name_no_function ')'
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::SizeOf), new TypeValueNode($3)); }
-	| ATTR_IDENTIFIER
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Attr), new VarRefNode($1)); }
-	| ATTR_IDENTIFIER '(' type_name ')'
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Attr), new VarRefNode($1), new TypeValueNode($3)); }
-	| ATTR_IDENTIFIER '(' argument_expression ')'
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Attr), new VarRefNode($1), $3); }
-	| ALIGNOF unary_expression			// GCC, variable alignment
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::AlignOf), $2); }
-	| ALIGNOF '(' type_name_no_function ')'		// GCC, type alignment
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::AlignOf), new TypeValueNode($3)); }
-	| ANDAND no_attr_identifier			// GCC, address of label
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::LabelAddress), new VarRefNode($2, true)); }
-	;
+		postfix_expression
+		| ICR unary_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Incr), $2); }
+		| DECR unary_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Decr), $2); }
+		| EXTENSION cast_expression						// GCC
+				{ $$ = $2; }
+		| unary_operator cast_expression
+				{ $$ = new CompositeExprNode($1, $2); }
+		| '!' cast_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Neg), $2); }
+		| '*' cast_expression							// CFA
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::PointTo), $2); }
+				// '*' is is separated from unary_operator because of shift/reduce conflict in:
+				//		{ * X; } // dereference X
+				//		{ * int X; } // CFA declaration of pointer to int
+				// '&' must be moved here if C++ reference variables are supported.
+		| SIZEOF unary_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::SizeOf), $2); }
+		| SIZEOF '(' type_name_no_function ')'
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::SizeOf), new TypeValueNode($3)); }
+		| ATTR_IDENTIFIER
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Attr), new VarRefNode($1)); }
+		| ATTR_IDENTIFIER '(' type_name ')'
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Attr), new VarRefNode($1), new TypeValueNode($3)); }
+		| ATTR_IDENTIFIER '(' argument_expression ')'
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Attr), new VarRefNode($1), $3); }
+		| ALIGNOF unary_expression						// GCC, variable alignment
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::AlignOf), $2); }
+		| ALIGNOF '(' type_name_no_function ')'			// GCC, type alignment
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::AlignOf), new TypeValueNode($3)); }
+		| ANDAND no_attr_identifier						// GCC, address of label
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::LabelAddress), new VarRefNode($2, true)); }
+		;
 
 unary_operator:
-	'&'						{ $$ = new OperatorNode(OperatorNode::AddressOf); }
-	| '+'						{ $$ = new OperatorNode(OperatorNode::UnPlus); }
-	| '-'						{ $$ = new OperatorNode(OperatorNode::UnMinus); }
-	| '~'						{ $$ = new OperatorNode(OperatorNode::BitNeg); }
-	;
+		'&'												{ $$ = new OperatorNode(OperatorNode::AddressOf); }
+		| '+'											{ $$ = new OperatorNode(OperatorNode::UnPlus); }
+		| '-'											{ $$ = new OperatorNode(OperatorNode::UnMinus); }
+		| '~'											{ $$ = new OperatorNode(OperatorNode::BitNeg); }
+		;
 
 cast_expression:
-	unary_expression
-	| '(' type_name_no_function ')' cast_expression
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Cast), new TypeValueNode($2), $4); }
-	| '(' type_name_no_function ')' tuple
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Cast), new TypeValueNode($2), $4); }
-	;
+		unary_expression
+		| '(' type_name_no_function ')' cast_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Cast), new TypeValueNode($2), $4); }
+		| '(' type_name_no_function ')' tuple
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Cast), new TypeValueNode($2), $4); }
+		;
 
 multiplicative_expression:
-	cast_expression
-	| multiplicative_expression '*' cast_expression
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Mul),$1,$3); }
-	| multiplicative_expression '/' cast_expression
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Div),$1,$3); }
-	| multiplicative_expression '%' cast_expression
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Mod),$1,$3); }
-	;
+		cast_expression
+		| multiplicative_expression '*' cast_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Mul),$1,$3); }
+		| multiplicative_expression '/' cast_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Div),$1,$3); }
+		| multiplicative_expression '%' cast_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Mod),$1,$3); }
+		;
 
 additive_expression:
-	multiplicative_expression
-	| additive_expression '+' multiplicative_expression
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Plus),$1,$3); }
-	| additive_expression '-' multiplicative_expression
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Minus),$1,$3); }
-	;
+		multiplicative_expression
+		| additive_expression '+' multiplicative_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Plus),$1,$3); }
+		| additive_expression '-' multiplicative_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Minus),$1,$3); }
+		;
 
 shift_expression:
-	additive_expression
-	| shift_expression LS additive_expression
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::LShift),$1,$3); }
-	| shift_expression RS additive_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::RShift),$1,$3); }
-	;
+		additive_expression
+		| shift_expression LS additive_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::LShift),$1,$3); }
+		| shift_expression RS additive_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::RShift),$1,$3); }
+		;
 
 relational_expression:
-	shift_expression
-	| relational_expression '<' shift_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::LThan),$1,$3); }
-	| relational_expression '>' shift_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::GThan),$1,$3); }
-	| relational_expression LE shift_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::LEThan),$1,$3); }
-	| relational_expression GE shift_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::GEThan),$1,$3); }
-	;
+		shift_expression
+		| relational_expression '<' shift_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::LThan),$1,$3); }
+		| relational_expression '>' shift_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::GThan),$1,$3); }
+		| relational_expression LE shift_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::LEThan),$1,$3); }
+		| relational_expression GE shift_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::GEThan),$1,$3); }
+		;
 
 equality_expression:
-	relational_expression
-	| equality_expression EQ relational_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Eq), $1, $3); }
-	| equality_expression NE relational_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Neq), $1, $3); }
-	;
+		relational_expression
+		| equality_expression EQ relational_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Eq), $1, $3); }
+		| equality_expression NE relational_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Neq), $1, $3); }
+		;
 
 AND_expression:
-	equality_expression
-	| AND_expression '&' equality_expression
-						{ $$ =new CompositeExprNode(new OperatorNode(OperatorNode::BitAnd), $1, $3); }
-	;
+		equality_expression
+		| AND_expression '&' equality_expression
+				{ $$ =new CompositeExprNode(new OperatorNode(OperatorNode::BitAnd), $1, $3); }
+		;
 
 exclusive_OR_expression:
-	AND_expression
-	| exclusive_OR_expression '^' AND_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Xor), $1, $3); }
-	;
+		AND_expression
+		| exclusive_OR_expression '^' AND_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Xor), $1, $3); }
+		;
 
 inclusive_OR_expression:
-	exclusive_OR_expression
-	| inclusive_OR_expression '|' exclusive_OR_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::BitOr), $1, $3); }
-	;
+		exclusive_OR_expression
+		| inclusive_OR_expression '|' exclusive_OR_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::BitOr), $1, $3); }
+		;
 
 logical_AND_expression:
-	inclusive_OR_expression
-	| logical_AND_expression ANDAND inclusive_OR_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::And), $1, $3); }
-	;
+		inclusive_OR_expression
+		| logical_AND_expression ANDAND inclusive_OR_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::And), $1, $3); }
+		;
 
 logical_OR_expression:
-	logical_AND_expression
-	| logical_OR_expression OROR logical_AND_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Or), $1, $3); }
-	;
+		logical_AND_expression
+		| logical_OR_expression OROR logical_AND_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Or), $1, $3); }
+		;
 
 conditional_expression:
-	logical_OR_expression
-	| logical_OR_expression '?' comma_expression ':' conditional_expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Cond),
-								       (ExpressionNode *)mkList((*$1,*$3,*$5))); }
-	| logical_OR_expression '?' /* empty */ ':' conditional_expression // GCC, omitted first operand
-						{ $$=new CompositeExprNode(new OperatorNode(OperatorNode::NCond),$1,$4); }
-	| logical_OR_expression '?' comma_expression ':' tuple // CFA, tuple expression
-						{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Cond),
-								       (ExpressionNode *)mkList(( *$1, *$3, *$5 ))); }
-	;
+		logical_OR_expression
+		| logical_OR_expression '?' comma_expression ':' conditional_expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Cond), (ExpressionNode *)mkList((*$1,*$3,*$5))); }
+		| logical_OR_expression '?' /* empty */ ':' conditional_expression // GCC, omitted first operand
+				{ $$=new CompositeExprNode(new OperatorNode(OperatorNode::NCond),$1,$4); }
+		| logical_OR_expression '?' comma_expression ':' tuple // CFA, tuple expression
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Cond), (ExpressionNode *)mkList(( *$1, *$3, *$5 ))); }
+		;
 
 constant_expression:
-	conditional_expression
-	;
+		conditional_expression
+		;
 
 assignment_expression:
-		// CFA, assignment is separated from assignment_operator to ensure no assignment operations for tuples
-	conditional_expression
-	| unary_expression '=' assignment_expression
-							{ $$ =new CompositeExprNode(new OperatorNode(OperatorNode::Assign), $1, $3); }
-	| unary_expression assignment_operator assignment_expression
-							{ $$ =new CompositeExprNode($2, $1, $3); }
-	| tuple assignment_opt				// CFA, tuple expression
-		{
-		  if ( $2 == 0 ) {
-		    $$ = $1;
-		  } else {
-		    $$ = new CompositeExprNode( new OperatorNode( OperatorNode::Assign ), $1, $2 );
-		  }
-		}
-	;
+				// CFA, assignment is separated from assignment_operator to ensure no assignment operations
+				// for tuples
+		conditional_expression
+		| unary_expression '=' assignment_expression
+				{ $$ =new CompositeExprNode(new OperatorNode(OperatorNode::Assign), $1, $3); }
+		| unary_expression assignment_operator assignment_expression
+				{ $$ =new CompositeExprNode($2, $1, $3); }
+		| tuple assignment_opt							// CFA, tuple expression
+				{ $$ = ($2 == 0) ? $1 : new CompositeExprNode( new OperatorNode( OperatorNode::Assign ), $1, $2 ); }
+		;
 
 assignment_expression_opt:
-	// empty
-		{ $$ = new NullExprNode; }
-	| assignment_expression
-	;
-
-tuple:							// CFA, tuple
-		// CFA, one assignment_expression is factored out of comma_expression to eliminate a shift/reduce
-		// conflict with comma_expression in new_identifier_parameter_array and new_abstract_array
-	'[' push pop ']'
-		{ $$ = new CompositeExprNode( new OperatorNode( OperatorNode::TupleC ) ); }
-	| '[' push assignment_expression pop ']'
-		{ $$ = new CompositeExprNode( new OperatorNode( OperatorNode::TupleC ), $3 ); }
-	| '[' push ',' tuple_expression_list pop ']'
-		{ $$ = new CompositeExprNode( new OperatorNode( OperatorNode::TupleC ), (ExpressionNode *)(new NullExprNode)->set_link( $4 ) ); }
-	| '[' push assignment_expression ',' tuple_expression_list pop ']'
-		{ $$ = new CompositeExprNode( new OperatorNode( OperatorNode::TupleC ), (ExpressionNode *)$3->set_link( flattenCommas( $5 ) ) ); }
-	;
+		// empty
+				{ $$ = new NullExprNode; }
+		| assignment_expression
+		;
+
+tuple:													// CFA, tuple
+				// CFA, one assignment_expression is factored out of comma_expression to eliminate a
+				// shift/reduce conflict with comma_expression in new_identifier_parameter_array and
+				// new_abstract_array
+		'[' push pop ']'
+				{ $$ = new CompositeExprNode( new OperatorNode( OperatorNode::TupleC ) ); }
+		| '[' push assignment_expression pop ']'
+				{ $$ = new CompositeExprNode( new OperatorNode( OperatorNode::TupleC ), $3 ); }
+		| '[' push ',' tuple_expression_list pop ']'
+				{ $$ = new CompositeExprNode( new OperatorNode( OperatorNode::TupleC ), (ExpressionNode *)(new NullExprNode)->set_link( $4 ) ); }
+		| '[' push assignment_expression ',' tuple_expression_list pop ']'
+				{ $$ = new CompositeExprNode( new OperatorNode( OperatorNode::TupleC ), (ExpressionNode *)$3->set_link( flattenCommas( $5 ) ) ); }
+		;
 
 tuple_expression_list:
-	assignment_expression_opt
-	| tuple_expression_list ',' assignment_expression_opt
-		{ $$ = (ExpressionNode *)$1->set_link( $3 ); }
-	;
+		assignment_expression_opt
+		| tuple_expression_list ',' assignment_expression_opt
+				{ $$ = (ExpressionNode *)$1->set_link( $3 ); }
+		;
 
 assignment_operator:
-	MULTassign					{ $$ = new OperatorNode(OperatorNode::MulAssn);   }
-	| DIVassign					{ $$ = new OperatorNode(OperatorNode::DivAssn);   }
-	| MODassign					{ $$ = new OperatorNode(OperatorNode::ModAssn);   }
-	| PLUSassign					{ $$ = new OperatorNode(OperatorNode::PlusAssn);  }
-	| MINUSassign					{ $$ = new OperatorNode(OperatorNode::MinusAssn); }
-	| LSassign					{ $$ = new OperatorNode(OperatorNode::LSAssn);    }
-	| RSassign					{ $$ = new OperatorNode(OperatorNode::RSAssn);    }
-	| ANDassign					{ $$ = new OperatorNode(OperatorNode::AndAssn);   }
-	| ERassign					{ $$ = new OperatorNode(OperatorNode::ERAssn);    }
-	| ORassign					{ $$ = new OperatorNode(OperatorNode::OrAssn);    }
-	;
+		MULTassign										{ $$ = new OperatorNode(OperatorNode::MulAssn); }
+		| DIVassign										{ $$ = new OperatorNode(OperatorNode::DivAssn); }
+		| MODassign										{ $$ = new OperatorNode(OperatorNode::ModAssn); }
+		| PLUSassign									{ $$ = new OperatorNode(OperatorNode::PlusAssn); }
+		| MINUSassign									{ $$ = new OperatorNode(OperatorNode::MinusAssn); }
+		| LSassign										{ $$ = new OperatorNode(OperatorNode::LSAssn); }
+		| RSassign										{ $$ = new OperatorNode(OperatorNode::RSAssn); }
+		| ANDassign										{ $$ = new OperatorNode(OperatorNode::AndAssn); }
+		| ERassign										{ $$ = new OperatorNode(OperatorNode::ERAssn); }
+		| ORassign										{ $$ = new OperatorNode(OperatorNode::OrAssn); }
+		;
 
 comma_expression:
-	assignment_expression
-	| comma_expression ',' assignment_expression	// { $$ = (ExpressionNode *)$1->add_to_list($3); }
-			       { $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Comma),$1,$3); }
-	;
+		assignment_expression
+		| comma_expression ',' assignment_expression	// { $$ = (ExpressionNode *)$1->add_to_list($3); }
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Comma),$1,$3); }
+		;
 
 comma_expression_opt:
-	// empty
-		{ $$ = 0; }
-	| comma_expression
-	;
+		// empty
+				{ $$ = 0; }
+		| comma_expression
+		;
 
 //*************************** STATEMENTS *******************************
 
 statement:
-	labeled_statement
-	| compound_statement
-	| expression_statement                          { $$ = $1; }
-	| selection_statement
-	| iteration_statement
-	| jump_statement
-	| exception_statement
-	| asm_statement
-	;
+		labeled_statement
+		| compound_statement
+		| expression_statement							{ $$ = $1; }
+		| selection_statement
+		| iteration_statement
+		| jump_statement
+		| exception_statement
+		| asm_statement
+		;
 
 labeled_statement:
-	no_attr_identifier ':' attribute_list_opt statement
-		{ $$ = $4->add_label($1);}
-	;
+		no_attr_identifier ':' attribute_list_opt statement
+				{ $$ = $4->add_label($1);}
+		;
 
 compound_statement:
-	'{' '}'
-		{ $$ = new CompoundStmtNode( (StatementNode *)0 ); }
-	| '{'
-		// Two scopes are necessary because the block itself has a scope, but every declaration within the block
-		// also requires its own scope
-	  push push
-	  label_declaration_opt				// GCC, local labels
-	  block_item_list pop '}'			// C99, intermix declarations and statements
-		{ $$ = new CompoundStmtNode( $5 ); }
-	;
-
-block_item_list:					// C99
-	block_item
-	| block_item_list push block_item
-		{ if ($1 != 0) { $1->set_link($3); $$ = $1; } }
-	;
+		'{' '}'
+				{ $$ = new CompoundStmtNode( (StatementNode *)0 ); }
+		| '{'
+				// Two scopes are necessary because the block itself has a scope, but every declaration within
+				// the block also requires its own scope
+		  push push
+		  label_declaration_opt							// GCC, local labels
+		  block_item_list pop '}'						// C99, intermix declarations and statements
+				{ $$ = new CompoundStmtNode( $5 ); }
+		;
+
+block_item_list:										// C99
+		block_item
+		| block_item_list push block_item
+				{ if ($1 != 0) { $1->set_link($3); $$ = $1; } }
+		;
 
 block_item:
-	declaration					// CFA, new & old style declarations
-		{ $$ = new StatementNode( $1 ); }
-	| EXTENSION declaration				// GCC
-		{ $$ = new StatementNode( $2 ); }
-	| statement pop
-	;
+		declaration										// CFA, new & old style declarations
+				{ $$ = new StatementNode( $1 ); }
+		| EXTENSION declaration							// GCC
+				{ $$ = new StatementNode( $2 ); }
+		| statement pop
+		;
 
 statement_list:
-	statement
-	| statement_list statement
-		{ if ($1 != 0) { $1->set_link($2); $$ = $1; } }
-	;
+		statement
+		| statement_list statement
+				{ if ($1 != 0) { $1->set_link($2); $$ = $1; } }
+		;
 
 expression_statement:
-	comma_expression_opt ';'
-		{ $$ = new StatementNode(StatementNode::Exp, $1, 0); }
-	;
+		comma_expression_opt ';'
+				{ $$ = new StatementNode(StatementNode::Exp, $1, 0); }
+		;
 
 selection_statement:
-	IF '(' comma_expression ')' statement		%prec THEN
-		// explicitly deal with the shift/reduce conflict on if/else
-		{ $$ = new StatementNode(StatementNode::If, $3, $5); }
-	| IF '(' comma_expression ')' statement ELSE statement
-		{ $$ = new StatementNode(StatementNode::If, $3, (StatementNode *)mkList((*$5, *$7)) ); }
-	| SWITCH '(' comma_expression ')' case_clause	// CFA
-		{ $$ = new StatementNode(StatementNode::Switch, $3, $5); }
-	| SWITCH '(' comma_expression ')' '{' push declaration_list_opt switch_clause_list_opt '}' // CFA
-		{ $$ = new StatementNode(StatementNode::Switch, $3, $8); /* xxx */ }
-		// The semantics of the declaration list is changed to include any associated initialization, which is
-		// performed *before* the transfer to the appropriate case clause.  Statements after the initial
-		// declaration list can never be executed, and therefore, are removed from the grammar even though C
-		// allows it.
-	| CHOOSE '(' comma_expression ')' case_clause	// CFA
-		{ $$ = new StatementNode(StatementNode::Choose, $3, $5); }
-	| CHOOSE '(' comma_expression ')' '{' push declaration_list_opt choose_clause_list_opt '}' // CFA
-		{ $$ = new StatementNode(StatementNode::Choose, $3, $8); }
-	;
-
-// CASE and DEFAULT clauses are only allowed in the SWITCH statement, precluding Duff's device. In addition, a case
-// clause allows a list of values and subranges.
-
-case_value:						// CFA
-	constant_expression			{ $$ = $1; }
-	| constant_expression ELLIPSIS constant_expression // GCC, subrange
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Range),$1,$3); }
-	| subrange					// CFA, subrange
-	;
-
-case_value_list:					// CFA
-	case_value
-	| case_value_list ',' case_value
-                {  $$ = new CompositeExprNode(new OperatorNode( OperatorNode::TupleC ), (ExpressionNode *)(tupleContents($1))->set_link($3) ); }
-	;
-
-case_label:						// CFA
-	CASE case_value_list ':'		{  $$ = new StatementNode(StatementNode::Case, $2, 0); }
-	| DEFAULT ':'			        {  $$ = new StatementNode(StatementNode::Default);     }
-		// A semantic check is required to ensure only one default clause per switch/choose statement.
-	;
-
-case_label_list:					// CFA
-	case_label
-	| case_label_list case_label            { $$ = (StatementNode *)($1->set_link($2)); }
-	;
-
-case_clause:						// CFA
-	case_label_list statement		{  $$ = $1->append_last_case($2); }
-	;
-
-switch_clause_list_opt:					// CFA
-	// empty
-		{ $$ = 0; }
-	| switch_clause_list
-	;
-
-switch_clause_list:					// CFA
-	case_label_list statement_list
-						{ $$ = $1->append_last_case($2); }
-	| switch_clause_list case_label_list statement_list
-						{ $$ = (StatementNode *)($1->set_link($2->append_last_case($3))); }
-	;
-
-choose_clause_list_opt:					// CFA
-	// empty
-		{ $$ = 0; }
-	| choose_clause_list
-	;
-
-choose_clause_list:					// CFA
-	case_label_list fall_through
-		{ $$ = $1->append_last_case($2); }
-	| case_label_list statement_list fall_through_opt
-		{ $$ = $1->append_last_case((StatementNode *)mkList((*$2,*$3))); }
-	| choose_clause_list case_label_list fall_through
-		{ $$ = (StatementNode *)($1->set_link($2->append_last_case($3))); }
-	| choose_clause_list case_label_list statement_list fall_through_opt
-		{ $$ = (StatementNode *)($1->set_link($2->append_last_case((StatementNode *)mkList((*$3,*$4))))); }
-	;
-
-fall_through_opt:					// CFA
-	// empty
-		{ $$ = 0; }
-	| fall_through
-	;
-
-fall_through:						// CFA
-	FALLTHRU				{ $$ = new StatementNode(StatementNode::Fallthru, 0, 0); }
-	| FALLTHRU ';'			        { $$ = new StatementNode(StatementNode::Fallthru, 0, 0); }
-	;
+		IF '(' comma_expression ')' statement				%prec THEN
+				// explicitly deal with the shift/reduce conflict on if/else
+				{ $$ = new StatementNode(StatementNode::If, $3, $5); }
+		| IF '(' comma_expression ')' statement ELSE statement
+				{ $$ = new StatementNode(StatementNode::If, $3, (StatementNode *)mkList((*$5, *$7)) ); }
+		| SWITCH '(' comma_expression ')' case_clause	// CFA
+				{ $$ = new StatementNode(StatementNode::Switch, $3, $5); }
+		| SWITCH '(' comma_expression ')' '{' push declaration_list_opt switch_clause_list_opt '}' // CFA
+				{ $$ = new StatementNode(StatementNode::Switch, $3, $8); /* xxx */ }
+				// The semantics of the declaration list is changed to include any associated initialization,
+				// which is performed *before* the transfer to the appropriate case clause.  Statements after
+				// the initial declaration list can never be executed, and therefore, are removed from the
+				// grammar even though C allows it.
+		| CHOOSE '(' comma_expression ')' case_clause	// CFA
+				{ $$ = new StatementNode(StatementNode::Choose, $3, $5); }
+		| CHOOSE '(' comma_expression ')' '{' push declaration_list_opt choose_clause_list_opt '}' // CFA
+				{ $$ = new StatementNode(StatementNode::Choose, $3, $8); }
+		;
+
+// CASE and DEFAULT clauses are only allowed in the SWITCH statement, precluding Duff's device. In addition, a
+// case clause allows a list of values and subranges.
+
+case_value:												// CFA
+		constant_expression								{ $$ = $1; }
+		| constant_expression ELLIPSIS constant_expression // GCC, subrange
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Range),$1,$3); }
+		| subrange										// CFA, subrange
+		;
+
+case_value_list:										// CFA
+		case_value
+		| case_value_list ',' case_value
+				{ $$ = new CompositeExprNode(new OperatorNode( OperatorNode::TupleC ), (ExpressionNode *)(tupleContents($1))->set_link($3) ); }
+		;
+
+case_label:												// CFA
+		CASE case_value_list ':'						{ $$ = new StatementNode(StatementNode::Case, $2, 0); }
+		| DEFAULT ':'								    { $$ = new StatementNode(StatementNode::Default); }
+				// A semantic check is required to ensure only one default clause per switch/choose statement.
+		;
+
+case_label_list:										// CFA
+		case_label
+		| case_label_list case_label					{ $$ = (StatementNode *)($1->set_link($2)); }
+		;
+
+case_clause:											// CFA
+		case_label_list statement						{ $$ = $1->append_last_case($2); }
+		;
+
+switch_clause_list_opt:									// CFA
+		// empty
+				{ $$ = 0; }
+		| switch_clause_list
+		;
+
+switch_clause_list:										// CFA
+		case_label_list statement_list
+				{ $$ = $1->append_last_case($2); }
+		| switch_clause_list case_label_list statement_list
+				{ $$ = (StatementNode *)($1->set_link($2->append_last_case($3))); }
+		;
+
+choose_clause_list_opt:									// CFA
+		// empty
+				{ $$ = 0; }
+		| choose_clause_list
+		;
+
+choose_clause_list:										// CFA
+		case_label_list fall_through
+				{ $$ = $1->append_last_case($2); }
+		| case_label_list statement_list fall_through_opt
+				{ $$ = $1->append_last_case((StatementNode *)mkList((*$2,*$3))); }
+		| choose_clause_list case_label_list fall_through
+				{ $$ = (StatementNode *)($1->set_link($2->append_last_case($3))); }
+		| choose_clause_list case_label_list statement_list fall_through_opt
+				{ $$ = (StatementNode *)($1->set_link($2->append_last_case((StatementNode *)mkList((*$3,*$4))))); }
+		;
+
+fall_through_opt:										// CFA
+		// empty
+				{ $$ = 0; }
+		| fall_through
+		;
+
+fall_through:											// CFA
+		FALLTHRU										{ $$ = new StatementNode(StatementNode::Fallthru, 0, 0); }
+		| FALLTHRU ';'									{ $$ = new StatementNode(StatementNode::Fallthru, 0, 0); }
+		;
 
 iteration_statement:
-	WHILE '(' comma_expression ')' statement
-						{ $$ = new StatementNode(StatementNode::While, $3, $5); }
-	| DO statement WHILE '(' comma_expression ')' ';'
-						{ $$ = new StatementNode(StatementNode::Do, $5, $2); }
-	| FOR '(' push for_control_expression ')' statement
-						{ $$ = new StatementNode(StatementNode::For, $4, $6); }
-	;
+		WHILE '(' comma_expression ')' statement
+				{ $$ = new StatementNode(StatementNode::While, $3, $5); }
+		| DO statement WHILE '(' comma_expression ')' ';'
+				{ $$ = new StatementNode(StatementNode::Do, $5, $2); }
+		| FOR '(' push for_control_expression ')' statement
+				{ $$ = new StatementNode(StatementNode::For, $4, $6); }
+		;
 
 for_control_expression:
-	comma_expression_opt pop ';' comma_expression_opt ';' comma_expression_opt
-						{ $$ = new ForCtlExprNode($1, $4, $6); }
-	| declaration comma_expression_opt ';' comma_expression_opt // C99
-		// Like C++, the loop index can be declared local to the loop.
-						{ $$ = new ForCtlExprNode($1, $2, $4); }
-	;
+		comma_expression_opt pop ';' comma_expression_opt ';' comma_expression_opt
+				{ $$ = new ForCtlExprNode($1, $4, $6); }
+		| declaration comma_expression_opt ';' comma_expression_opt // C99
+				// Like C++, the loop index can be declared local to the loop.
+				{ $$ = new ForCtlExprNode($1, $2, $4); }
+		;
 
 jump_statement:
-	GOTO no_attr_identifier ';'
-						{ $$ = new StatementNode(StatementNode::Goto, $2); }
-	| GOTO '*' comma_expression ';'		// GCC, computed goto
-		// The syntax for the GCC computed goto violates normal expression precedence, e.g., goto *i+3; =>
-		// goto *(i+3); whereas normal operator precedence yields goto (*i)+3;
-						{ $$ = new StatementNode(StatementNode::Goto, $3); }
-	| CONTINUE ';'
-		// A semantic check is required to ensure this statement appears only in the body of an iteration
-		// statement.
-						{ $$ = new StatementNode(StatementNode::Continue, 0, 0); }
-	| CONTINUE no_attr_identifier ';'	// CFA, multi-level continue
-		// A semantic check is required to ensure this statement appears only in the body of an iteration
-		// statement, and the target of the transfer appears only at the start of an iteration statement.
-						{ $$ = new StatementNode(StatementNode::Continue, $2); }
-	| BREAK ';'
-		// A semantic check is required to ensure this statement appears only in the body of an iteration
-		// statement.
-						{ $$ = new StatementNode(StatementNode::Break, 0, 0); }
-	| BREAK no_attr_identifier ';'		// CFA, multi-level exit
-		// A semantic check is required to ensure this statement appears only in the body of an iteration
-		// statement, and the target of the transfer appears only at the start of an iteration statement.
-						{ $$ = new StatementNode(StatementNode::Break, $2 ); }
-	| RETURN comma_expression_opt ';'
-						{ $$ = new StatementNode(StatementNode::Return, $2, 0); }
-	| THROW assignment_expression ';'
-						{ $$ = new StatementNode(StatementNode::Throw, $2, 0); }
-	| THROW ';'
-                                                { $$ = new StatementNode(StatementNode::Throw, 0, 0); }
-	;
+		GOTO no_attr_identifier ';'
+				{ $$ = new StatementNode(StatementNode::Goto, $2); }
+		| GOTO '*' comma_expression ';'				// GCC, computed goto
+				// The syntax for the GCC computed goto violates normal expression precedence, e.g., goto
+				// *i+3; => goto *(i+3); whereas normal operator precedence yields goto (*i)+3;
+				{ $$ = new StatementNode(StatementNode::Goto, $3); }
+		| CONTINUE ';'
+				// A semantic check is required to ensure this statement appears only in the body of an
+				// iteration statement.
+				{ $$ = new StatementNode(StatementNode::Continue, 0, 0); }
+		| CONTINUE no_attr_identifier ';'		// CFA, multi-level continue
+				// A semantic check is required to ensure this statement appears only in the body of an
+				// iteration statement, and the target of the transfer appears only at the start of an
+				// iteration statement.
+				{ $$ = new StatementNode(StatementNode::Continue, $2); }
+		| BREAK ';'
+				// A semantic check is required to ensure this statement appears only in the body of an
+				// iteration statement.
+				{ $$ = new StatementNode(StatementNode::Break, 0, 0); }
+		| BREAK no_attr_identifier ';'				// CFA, multi-level exit
+				// A semantic check is required to ensure this statement appears only in the body of an
+				// iteration statement, and the target of the transfer appears only at the start of an
+				// iteration statement.
+				{ $$ = new StatementNode(StatementNode::Break, $2 ); }
+		| RETURN comma_expression_opt ';'
+				{ $$ = new StatementNode(StatementNode::Return, $2, 0); }
+		| THROW assignment_expression ';'
+				{ $$ = new StatementNode(StatementNode::Throw, $2, 0); }
+		| THROW ';'
+				{ $$ = new StatementNode(StatementNode::Throw, 0, 0); }
+		;
 
 exception_statement:
-	TRY compound_statement handler_list
-			     { $$ = new StatementNode(StatementNode::Try, 0,(StatementNode *)(mkList((*$2,*$3)))); }
-	| TRY compound_statement finally_clause
-			     { $$ = new StatementNode(StatementNode::Try, 0,(StatementNode *)(mkList((*$2,*$3)))); }
-	| TRY compound_statement handler_list finally_clause
-                             { 
-			       $3->set_link($4);
-			       $$ = new StatementNode(StatementNode::Try, 0,(StatementNode *)(mkList((*$2,*$3))));
-			     }
-	;
+		TRY compound_statement handler_list
+				{ $$ = new StatementNode(StatementNode::Try, 0,(StatementNode *)(mkList((*$2,*$3)))); }
+		| TRY compound_statement finally_clause
+				{ $$ = new StatementNode(StatementNode::Try, 0,(StatementNode *)(mkList((*$2,*$3)))); }
+		| TRY compound_statement handler_list finally_clause
+				{ 
+					$3->set_link($4);
+					$$ = new StatementNode(StatementNode::Try, 0,(StatementNode *)(mkList((*$2,*$3))));
+				}
+		;
 
 handler_list:
-		// There must be at least one catch clause
-	handler_clause
-		// ISO/IEC 9899:1999 Section 15.3(6) If present, a "..." handler shall be the last handler for its try
-		// block.
-	| CATCH '(' ELLIPSIS ')' compound_statement
-						{ $$ = StatementNode::newCatchStmt( 0, $5, true ); }
-	| handler_clause CATCH '(' ELLIPSIS ')' compound_statement
-						{ $$ = $1->set_link( StatementNode::newCatchStmt( 0, $6, true ) ); }
-	;
+				// There must be at least one catch clause
+		handler_clause
+				// ISO/IEC 9899:1999 Section 15.3(6) If present, a "..." handler shall be the last handler for
+				// its try block.
+		| CATCH '(' ELLIPSIS ')' compound_statement
+				{ $$ = StatementNode::newCatchStmt( 0, $5, true ); }
+		| handler_clause CATCH '(' ELLIPSIS ')' compound_statement
+				{ $$ = $1->set_link( StatementNode::newCatchStmt( 0, $6, true ) ); }
+		;
 
 handler_clause:
-	CATCH '(' push push exception_declaration pop ')' compound_statement pop
-						{ $$ = StatementNode::newCatchStmt($5, $8); }
-	| handler_clause CATCH '(' push push exception_declaration pop ')' compound_statement pop
-						{ $$ = $1->set_link( StatementNode::newCatchStmt($6, $9) );   }
-	;
+		CATCH '(' push push exception_declaration pop ')' compound_statement pop
+				{ $$ = StatementNode::newCatchStmt($5, $8); }
+		| handler_clause CATCH '(' push push exception_declaration pop ')' compound_statement pop
+				{ $$ = $1->set_link( StatementNode::newCatchStmt($6, $9) ); }
+		;
 
 finally_clause:
-	FINALLY compound_statement
-                                                { $$ = new StatementNode(StatementNode::Finally, 0, $2);
-						  std::cout << "Just created a finally node" << std::endl;
-						}
-	;
+		FINALLY compound_statement
+				{ $$ = new StatementNode(StatementNode::Finally, 0, $2);
+					std::cout << "Just created a finally node" << std::endl;
+				}
+		;
 
 exception_declaration:
-		// A semantic check is required to ensure type_specifier does not create a new type, e.g.:
-		//
-		//	catch ( struct { int i; } x ) ...
-		//
-		// This new type cannot catch any thrown type because of name equivalence among types.
-	type_specifier
-	| type_specifier declarator
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    $$ = $2->addType( $1 );
-		}
-	| type_specifier variable_abstract_declarator
-		{   $$ = $2->addType( $1 ); }
-	| new_abstract_declarator_tuple no_attr_identifier // CFA
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    $$ = $1->addName( $2 );
-		}
-	| new_abstract_declarator_tuple			// CFA
-	;
+				// A semantic check is required to ensure type_specifier does not create a new type, e.g.:
+				//
+				//		catch ( struct { int i; } x ) ...
+				//
+				// This new type cannot catch any thrown type because of name equivalence among types.
+		type_specifier
+		| type_specifier declarator
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					$$ = $2->addType( $1 );
+				}
+		| type_specifier variable_abstract_declarator
+				{ $$ = $2->addType( $1 ); }
+		| new_abstract_declarator_tuple no_attr_identifier // CFA
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					$$ = $1->addName( $2 );
+				}
+		| new_abstract_declarator_tuple					// CFA
+		;
 
 asm_statement:
-	ASM type_qualifier_list_opt '(' constant_expression ')' ';'
-						{ $$ = new StatementNode(StatementNode::Asm, 0, 0); }
-	| ASM type_qualifier_list_opt '(' constant_expression ':' asm_operands_opt ')' ';' // remaining GCC
-						{ $$ = new StatementNode(StatementNode::Asm, 0, 0); }
-	| ASM type_qualifier_list_opt '(' constant_expression ':' asm_operands_opt ':' asm_operands_opt ')' ';'
-						{ $$ = new StatementNode(StatementNode::Asm, 0, 0); }
-	| ASM type_qualifier_list_opt '(' constant_expression ':' asm_operands_opt ':' asm_operands_opt ':'
-			asm_clobbers_list ')' ';'
-						{ $$ = new StatementNode(StatementNode::Asm, 0, 0); }
-	;
-
-asm_operands_opt:					// GCC
-	// empty
-	| asm_operands_list
-	;
-
-asm_operands_list:					// GCC
-	asm_operand
-	| asm_operands_list ',' asm_operand
-	;
-
-asm_operand:						// GCC
-	STRINGliteral '(' constant_expression ')'	{}
-	;
-
-asm_clobbers_list:					// GCC
-	STRINGliteral				{}
-	| asm_clobbers_list ',' STRINGliteral
-	;
+		ASM type_qualifier_list_opt '(' constant_expression ')' ';'
+				{ $$ = new StatementNode(StatementNode::Asm, 0, 0); }
+		| ASM type_qualifier_list_opt '(' constant_expression ':' asm_operands_opt ')' ';' // remaining GCC
+				{ $$ = new StatementNode(StatementNode::Asm, 0, 0); }
+		| ASM type_qualifier_list_opt '(' constant_expression ':' asm_operands_opt ':' asm_operands_opt ')' ';'
+				{ $$ = new StatementNode(StatementNode::Asm, 0, 0); }
+		| ASM type_qualifier_list_opt '(' constant_expression ':' asm_operands_opt ':' asm_operands_opt ':'
+						asm_clobbers_list ')' ';'
+				{ $$ = new StatementNode(StatementNode::Asm, 0, 0); }
+		;
+
+asm_operands_opt:										// GCC
+		// empty
+		| asm_operands_list
+		;
+
+asm_operands_list:										// GCC
+		asm_operand
+		| asm_operands_list ',' asm_operand
+		;
+
+asm_operand:											// GCC
+		STRINGliteral '(' constant_expression ')'		{}
+		;
+
+asm_clobbers_list:										// GCC
+		STRINGliteral									{}
+		| asm_clobbers_list ',' STRINGliteral
+		;
 
 //******************************* DECLARATIONS *********************************
 
-declaration_list_opt:					// used at beginning of switch statement
-	pop
-		{ $$ = 0; }
-	| declaration_list
-	;
+declaration_list_opt:									// used at beginning of switch statement
+		pop
+				{ $$ = 0; }
+		| declaration_list
+		;
 
 declaration_list:
-	declaration
-	| declaration_list push declaration
-		{ $$ = $1->appendList( $3 ); }
-	;
-
-old_declaration_list_opt:				// used to declare parameter types in K&R style functions
-	pop
-		{ $$ = 0; }
-	| old_declaration_list
-	;
+		declaration
+		| declaration_list push declaration
+				{ $$ = $1->appendList( $3 ); }
+		;
+
+old_declaration_list_opt:								// used to declare parameter types in K&R style functions
+		pop
+				{ $$ = 0; }
+		| old_declaration_list
+		;
 
 old_declaration_list:
-	old_declaration
-	| old_declaration_list push old_declaration
-		{ $$ = $1->appendList( $3 ); }
-	;
-
-label_declaration_opt:					// GCC, local label
-	// empty
-	| label_declaration_list
-	;
-
-label_declaration_list:					// GCC, local label
-	LABEL label_list ';'
-	| label_declaration_list LABEL label_list ';'
-	;
-
-label_list:						// GCC, local label
-	no_attr_identifier_or_typedef_name		{}
-	| label_list ',' no_attr_identifier_or_typedef_name {}
-	;
-
-declaration:						// CFA, new & old style declarations
-	new_declaration
-	| old_declaration
-	;
-
-// C declaration syntax is notoriously confusing and error prone. Cforall provides its own type, variable and function
-// declarations. CFA declarations use the same declaration tokens as in C; however, CFA places declaration modifiers to
-// the left of the base type, while C declarations place modifiers to the right of the base type. CFA declaration
-// modifiers are interpreted from left to right and the entire type specification is distributed across all variables in
-// the declaration list (as in Pascal).  ANSI C and the new CFA declarations may appear together in the same program
-// block, but cannot be mixed within a specific declaration.
-//
-//	    CFA	    	    C
-//	[10] int x;	int x[10];	// array of 10 integers
-//	[10] * char y;	char *y[10];	// array of 10 pointers to char
-
-new_declaration:					// CFA
-	new_variable_declaration pop ';'
-	| new_typedef_declaration pop ';'
-	| new_function_declaration pop ';'
-	| type_declaring_list pop ';'
-	| context_specifier pop ';'
-	;
-
-new_variable_declaration:				// CFA
-	new_variable_specifier initializer_opt
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::ID );
-			$$ = $1;
-		}
-	| declaration_qualifier_list new_variable_specifier initializer_opt
-		// declaration_qualifier_list also includes type_qualifier_list, so a semantic check is necessary to
-		// preclude them as a type_qualifier cannot appear in that context.
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::ID );
-			$$ = $2->addQualifiers( $1 );
-		}
-	| new_variable_declaration pop ',' push identifier_or_typedef_name initializer_opt
-		{
-			typedefTable.addToEnclosingScope( *$5, TypedefTable::ID );
-			$$ = $1->appendList( $1->cloneType( $5 ) );
-		}
-	;
-
-new_variable_specifier:					// CFA
-		// A semantic check is required to ensure asm_name only appears on declarations with implicit or
-		// explicit static storage-class
-	new_abstract_declarator_no_tuple identifier_or_typedef_name asm_name_opt
-		{
-			typedefTable.setNextIdentifier( *$2 );
-			$$ = $1->addName( $2 );
-		}
-	| new_abstract_tuple identifier_or_typedef_name asm_name_opt
-		{
-			typedefTable.setNextIdentifier( *$2 );
-			$$ = $1->addName( $2 );
-		}
-	| type_qualifier_list new_abstract_tuple identifier_or_typedef_name asm_name_opt
-		{
-			typedefTable.setNextIdentifier( *$3 );
-			$$ = $2->addQualifiers( $1 )->addName( $3 );
-		}
-	;
-
-new_function_declaration:				// CFA
-	new_function_specifier
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::ID );
-			$$ = $1;
-		}
-	| declaration_qualifier_list new_function_specifier
-		// declaration_qualifier_list also includes type_qualifier_list, so a semantic check is necessary to
-		// preclude them as a type_qualifier cannot appear in this context.
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::ID );
-			$$ = $2->addQualifiers( $1 );
-		}
-	| new_function_declaration pop ',' push identifier_or_typedef_name
-		{
-			typedefTable.addToEnclosingScope( *$5, TypedefTable::ID );
-			$$ = $1->appendList( $1->cloneType( $5 ) );
-		}
-	;
-
-new_function_specifier:					// CFA
-	'[' push pop ']' identifier '(' push new_parameter_type_list_opt pop ')'
-		{
-			typedefTable.setNextIdentifier( *($5) );
-			$$ = DeclarationNode::newFunction( $5, DeclarationNode::newTuple( 0 ), $8, 0, true );
-		}
-	| '[' push pop ']' TYPEDEFname '(' push new_parameter_type_list_opt pop ')'
-		{
-			typedefTable.setNextIdentifier( *($5) );
-			$$ = DeclarationNode::newFunction( $5, DeclarationNode::newTuple( 0 ), $8, 0, true );
-		}
-		/* identifier_or_typedef_name must be broken apart because of the sequence:
-
-		   '[' ']' identifier_or_typedef_name '(' new_parameter_type_list_opt ')'
-		   '[' ']' type_specifier
-
-		   type_specifier can resolve to just TYPEDEFname (e.g. typedef int T; int f( T );). Therefore
-		   this must be flattened to allow lookahead to the '(' without having to reduce
-		   identifier_or_typedef_name. */
-	| new_abstract_tuple identifier_or_typedef_name '(' push new_parameter_type_list_opt pop ')'
-		/* To obtain LR(1), this rule must be factored out from function return type (see
-		   new_abstract_declarator). */
-		{
-			$$ = DeclarationNode::newFunction( $2, $1, $5, 0, true );
-		}
-	| new_function_return identifier_or_typedef_name '(' push new_parameter_type_list_opt pop ')'
-		{
-			$$ = DeclarationNode::newFunction( $2, $1, $5, 0, true );
-		}
-	;
-
-new_function_return:					// CFA
-	'[' push new_parameter_list pop ']'
-		{ $$ = DeclarationNode::newTuple( $3 ); }
-	| '[' push new_parameter_list pop ',' push new_abstract_parameter_list pop ']'
-		/* To obtain LR(1), the last new_abstract_parameter_list is added into this flattened rule to
-		   lookahead to the ']'. */
-		{ $$ = DeclarationNode::newTuple( $3->appendList( $7 ) ); }
-	;
-
-new_typedef_declaration:				// CFA
-	TYPEDEF new_variable_specifier
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::TD);
-			$$ = $2->addTypedef();
-		}
-	| TYPEDEF new_function_specifier
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::TD);
-			$$ = $2->addTypedef();
-		}
-	| new_typedef_declaration pop ',' push no_attr_identifier
-		{
-			typedefTable.addToEnclosingScope( *$5, TypedefTable::TD);
-			$$ = $1->appendList( $1->cloneType( $5 ) );
-		}
-	;
-
-/* Traditionally typedef is part of storage-class specifier for syntactic convenience only. Here, it is
-   factored out as a separate form of declaration, which syntactically precludes storage-class specifiers and
-   initialization. */
+		old_declaration
+		| old_declaration_list push old_declaration
+				{ $$ = $1->appendList( $3 ); }
+		;
+
+label_declaration_opt:									// GCC, local label
+		// empty
+		| label_declaration_list
+		;
+
+label_declaration_list:									// GCC, local label
+		LABEL label_list ';'
+		| label_declaration_list LABEL label_list ';'
+		;
+
+label_list:												// GCC, local label
+		no_attr_identifier_or_typedef_name				{}
+		| label_list ',' no_attr_identifier_or_typedef_name {}
+		;
+
+declaration:											// CFA, new & old style declarations
+		new_declaration
+		| old_declaration
+		;
+
+// C declaration syntax is notoriously confusing and error prone. Cforall provides its own type, variable and
+// function declarations. CFA declarations use the same declaration tokens as in C; however, CFA places
+// declaration modifiers to the left of the base type, while C declarations place modifiers to the right of
+// the base type. CFA declaration modifiers are interpreted from left to right and the entire type
+// specification is distributed across all variables in the declaration list (as in Pascal).  ANSI C and the
+// new CFA declarations may appear together in the same program block, but cannot be mixed within a specific
+// declaration.
+//
+//			CFA					C
+//		[10] int x;			int x[10];		// array of 10 integers
+//		[10] * char y;		char *y[10];	// array of 10 pointers to char
+
+new_declaration:										// CFA
+		new_variable_declaration pop ';'
+		| new_typedef_declaration pop ';'
+		| new_function_declaration pop ';'
+		| type_declaring_list pop ';'
+		| context_specifier pop ';'
+		;
+
+new_variable_declaration:								// CFA
+		new_variable_specifier initializer_opt
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					$$ = $1;
+				}
+		| declaration_qualifier_list new_variable_specifier initializer_opt
+				// declaration_qualifier_list also includes type_qualifier_list, so a semantic check is
+				// necessary to preclude them as a type_qualifier cannot appear in that context.
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					$$ = $2->addQualifiers( $1 );
+				}
+		| new_variable_declaration pop ',' push identifier_or_typedef_name initializer_opt
+				{
+					typedefTable.addToEnclosingScope( *$5, TypedefTable::ID );
+					$$ = $1->appendList( $1->cloneType( $5 ) );
+				}
+		;
+
+new_variable_specifier:									// CFA
+				// A semantic check is required to ensure asm_name only appears on declarations with implicit
+				// or explicit static storage-class
+		new_abstract_declarator_no_tuple identifier_or_typedef_name asm_name_opt
+				{
+					typedefTable.setNextIdentifier( *$2 );
+					$$ = $1->addName( $2 );
+				}
+		| new_abstract_tuple identifier_or_typedef_name asm_name_opt
+				{
+					typedefTable.setNextIdentifier( *$2 );
+					$$ = $1->addName( $2 );
+				}
+		| type_qualifier_list new_abstract_tuple identifier_or_typedef_name asm_name_opt
+				{
+					typedefTable.setNextIdentifier( *$3 );
+					$$ = $2->addQualifiers( $1 )->addName( $3 );
+				}
+		;
+
+new_function_declaration:								// CFA
+		new_function_specifier
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					$$ = $1;
+				}
+		| declaration_qualifier_list new_function_specifier
+				// declaration_qualifier_list also includes type_qualifier_list, so a semantic check is
+				// necessary to preclude them as a type_qualifier cannot appear in this context.
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					$$ = $2->addQualifiers( $1 );
+				}
+		| new_function_declaration pop ',' push identifier_or_typedef_name
+				{
+					typedefTable.addToEnclosingScope( *$5, TypedefTable::ID );
+					$$ = $1->appendList( $1->cloneType( $5 ) );
+				}
+		;
+
+new_function_specifier:									// CFA
+		'[' push pop ']' identifier '(' push new_parameter_type_list_opt pop ')'
+				{
+					typedefTable.setNextIdentifier( *($5) );
+					$$ = DeclarationNode::newFunction( $5, DeclarationNode::newTuple( 0 ), $8, 0, true );
+				}
+		| '[' push pop ']' TYPEDEFname '(' push new_parameter_type_list_opt pop ')'
+				{
+					typedefTable.setNextIdentifier( *($5) );
+					$$ = DeclarationNode::newFunction( $5, DeclarationNode::newTuple( 0 ), $8, 0, true );
+				}
+				// identifier_or_typedef_name must be broken apart because of the sequence:
+				//
+				//   '[' ']' identifier_or_typedef_name '(' new_parameter_type_list_opt ')'
+				//   '[' ']' type_specifier
+				//
+				// type_specifier can resolve to just TYPEDEFname (e.g. typedef int T; int f( T );). Therefore
+				// this must be flattened to allow lookahead to the '(' without having to reduce
+				// identifier_or_typedef_name.
+		| new_abstract_tuple identifier_or_typedef_name '(' push new_parameter_type_list_opt pop ')'
+				// To obtain LR(1), this rule must be factored out from function return type (see
+				//   new_abstract_declarator).
+				{
+					$$ = DeclarationNode::newFunction( $2, $1, $5, 0, true );
+				}
+		| new_function_return identifier_or_typedef_name '(' push new_parameter_type_list_opt pop ')'
+				{
+					$$ = DeclarationNode::newFunction( $2, $1, $5, 0, true );
+				}
+		;
+
+new_function_return:									// CFA
+		'[' push new_parameter_list pop ']'
+				{ $$ = DeclarationNode::newTuple( $3 ); }
+		| '[' push new_parameter_list pop ',' push new_abstract_parameter_list pop ']'
+				// To obtain LR(1), the last new_abstract_parameter_list is added into this flattened rule to
+				// lookahead to the ']'.
+				{ $$ = DeclarationNode::newTuple( $3->appendList( $7 ) ); }
+		;
+
+new_typedef_declaration:								// CFA
+		TYPEDEF new_variable_specifier
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::TD);
+					$$ = $2->addTypedef();
+				}
+		| TYPEDEF new_function_specifier
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::TD);
+					$$ = $2->addTypedef();
+				}
+		| new_typedef_declaration pop ',' push no_attr_identifier
+				{
+					typedefTable.addToEnclosingScope( *$5, TypedefTable::TD);
+					$$ = $1->appendList( $1->cloneType( $5 ) );
+				}
+		;
+
+// Traditionally typedef is part of storage-class specifier for syntactic convenience only. Here, it is
+// factored out as a separate form of declaration, which syntactically precludes storage-class specifiers and
+// initialization.
 
 typedef_declaration:
-	TYPEDEF type_specifier declarator
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::TD);
-			$$ = $3->addType( $2 )->addTypedef();
-		}
-	| typedef_declaration pop ',' push declarator
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::TD);
-			$$ = $1->appendList( $1->cloneBaseType( $5 )->addTypedef() );
-		}
-	| type_qualifier_list TYPEDEF type_specifier declarator // remaining OBSOLESCENT (see 2)
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::TD);
-			$$ = $4->addType( $3 )->addQualifiers( $1 )->addTypedef();
-		}
-	| type_specifier TYPEDEF declarator
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::TD);
-			$$ = $3->addType( $1 )->addTypedef();
-		}
-	| type_specifier TYPEDEF type_qualifier_list declarator
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::TD);
-			$$ = $4->addQualifiers($1)->addTypedef()->addType($1);
-		}
-	;
-
-typedef_expression:					// GCC, naming expression type
-	TYPEDEF no_attr_identifier '=' assignment_expression
-		{
-			typedefTable.addToEnclosingScope(*($2), TypedefTable::TD);
-			$$ = DeclarationNode::newName( 0 ); // XXX
-		}
-	| typedef_expression pop ',' push no_attr_identifier '=' assignment_expression
-		{
-			typedefTable.addToEnclosingScope(*($5), TypedefTable::TD);
-			$$ = DeclarationNode::newName( 0 ); // XXX
-		}
-	;
+		TYPEDEF type_specifier declarator
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::TD);
+					$$ = $3->addType( $2 )->addTypedef();
+				}
+		| typedef_declaration pop ',' push declarator
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::TD);
+					$$ = $1->appendList( $1->cloneBaseType( $5 )->addTypedef() );
+				}
+		| type_qualifier_list TYPEDEF type_specifier declarator // remaining OBSOLESCENT (see 2)
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::TD);
+					$$ = $4->addType( $3 )->addQualifiers( $1 )->addTypedef();
+				}
+		| type_specifier TYPEDEF declarator
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::TD);
+					$$ = $3->addType( $1 )->addTypedef();
+				}
+		| type_specifier TYPEDEF type_qualifier_list declarator
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::TD);
+					$$ = $4->addQualifiers($1)->addTypedef()->addType($1);
+				}
+		;
+
+typedef_expression:										// GCC, naming expression type
+		TYPEDEF no_attr_identifier '=' assignment_expression
+				{
+					typedefTable.addToEnclosingScope(*($2), TypedefTable::TD);
+					$$ = DeclarationNode::newName( 0 ); // XXX
+				}
+		| typedef_expression pop ',' push no_attr_identifier '=' assignment_expression
+				{
+					typedefTable.addToEnclosingScope(*($5), TypedefTable::TD);
+					$$ = DeclarationNode::newName( 0 ); // XXX
+				}
+		;
 
 old_declaration:
-	declaring_list pop ';'
-	| typedef_declaration pop ';'
-	| typedef_expression pop ';'			// GCC, naming expression type
-	| sue_declaration_specifier pop ';'
-	;
+		declaring_list pop ';'
+		| typedef_declaration pop ';'
+		| typedef_expression pop ';'					// GCC, naming expression type
+		| sue_declaration_specifier pop ';'
+		;
 
 declaring_list:
-		/* A semantic check is required to ensure asm_name only appears on declarations with implicit
-		   or explicit static storage-class */
-	declaration_specifier declarator asm_name_opt initializer_opt
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::ID );
-			$$ = ($2->addType( $1 ))->addInitializer($4);
-		}
-	| declaring_list ',' attribute_list_opt declarator asm_name_opt initializer_opt
-		{
-			typedefTable.addToEnclosingScope( TypedefTable::ID );
-			$$ = $1->appendList( $1->cloneBaseType( $4->addInitializer($6) ) );
-		}
-	;
-
-declaration_specifier:					// type specifier + storage class
-	basic_declaration_specifier
-	| sue_declaration_specifier
-	| typedef_declaration_specifier
-	| typegen_declaration_specifier
-	;
-
-type_specifier:						// declaration specifier - storage class
-	basic_type_specifier
-	| sue_type_specifier
-	| typedef_type_specifier
-	| typegen_type_specifier
-	;
-
-type_qualifier_list_opt:				// GCC, used in asm_statement
-	// empty
-		{ $$ = 0; }
-	| type_qualifier_list
-	;
+				// A semantic check is required to ensure asm_name only appears on declarations with implicit
+				// or explicit static storage-class
+		declaration_specifier declarator asm_name_opt initializer_opt
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					$$ = ($2->addType( $1 ))->addInitializer($4);
+				}
+		| declaring_list ',' attribute_list_opt declarator asm_name_opt initializer_opt
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					$$ = $1->appendList( $1->cloneBaseType( $4->addInitializer($6) ) );
+				}
+		;
+
+declaration_specifier:									// type specifier + storage class
+		basic_declaration_specifier
+		| sue_declaration_specifier
+		| typedef_declaration_specifier
+		| typegen_declaration_specifier
+		;
+
+type_specifier:											// declaration specifier - storage class
+		basic_type_specifier
+		| sue_type_specifier
+		| typedef_type_specifier
+		| typegen_type_specifier
+		;
+
+type_qualifier_list_opt:								// GCC, used in asm_statement
+		// empty
+				{ $$ = 0; }
+		| type_qualifier_list
+		;
 
 type_qualifier_list:
-		/* A semantic check is necessary to ensure a type qualifier is appropriate for the kind of
-		   declaration.
-
-		   ISO/IEC 9899:1999 Section 6.7.3(4) : If the same qualifier appears more than once in the
-		   same specifier-qualifier-list, either directly or via one or more typedefs, the behavior is
-		   the same as if it appeared only once. */
-	type_qualifier
-	| type_qualifier_list type_qualifier
-		{ $$ = $1->addQualifiers( $2 ); }
-	;
+				// A semantic check is necessary to ensure a type qualifier is appropriate for the kind of
+				// declaration.
+				//
+				// ISO/IEC 9899:1999 Section 6.7.3(4) : If the same qualifier appears more than once in the
+				// same specifier-qualifier-list, either directly or via one or more typedefs, the behavior is
+				// the same as if it appeared only once.
+		type_qualifier
+		| type_qualifier_list type_qualifier
+				{ $$ = $1->addQualifiers( $2 ); }
+		;
 
 type_qualifier:
-	type_qualifier_name
-	| attribute
-		{ $$ = DeclarationNode::newQualifier( DeclarationNode::Attribute ); }
-	;
+		type_qualifier_name
+		| attribute
+				{ $$ = DeclarationNode::newQualifier( DeclarationNode::Attribute ); }
+		;
 
 type_qualifier_name:
-	CONST
-		{ $$ = DeclarationNode::newQualifier( DeclarationNode::Const ); }
-	| RESTRICT
-		{ $$ = DeclarationNode::newQualifier( DeclarationNode::Restrict ); }
-	| VOLATILE
-		{ $$ = DeclarationNode::newQualifier( DeclarationNode::Volatile ); }
-	| LVALUE					// CFA
-		{ $$ = DeclarationNode::newQualifier( DeclarationNode::Lvalue ); }
-	| ATOMIC
-		{ $$ = DeclarationNode::newQualifier( DeclarationNode::Atomic ); }
-	| FORALL '('
-		{
-			typedefTable.enterScope();
-		}
-	  type_parameter_list ')'			// CFA
-		{
-			typedefTable.leaveScope();
-			$$ = DeclarationNode::newForall( $4 );
-		}
-	;
+		CONST
+				{ $$ = DeclarationNode::newQualifier( DeclarationNode::Const ); }
+		| RESTRICT
+				{ $$ = DeclarationNode::newQualifier( DeclarationNode::Restrict ); }
+		| VOLATILE
+				{ $$ = DeclarationNode::newQualifier( DeclarationNode::Volatile ); }
+		| LVALUE										// CFA
+				{ $$ = DeclarationNode::newQualifier( DeclarationNode::Lvalue ); }
+		| ATOMIC
+				{ $$ = DeclarationNode::newQualifier( DeclarationNode::Atomic ); }
+		| FORALL '('
+				{
+					typedefTable.enterScope();
+				}
+		  type_parameter_list ')'						// CFA
+				{
+					typedefTable.leaveScope();
+					$$ = DeclarationNode::newForall( $4 );
+				}
+		;
 
 declaration_qualifier_list:
-	storage_class_list
-	| type_qualifier_list storage_class_list	// remaining OBSOLESCENT (see 2)
-		{ $$ = $1->addQualifiers( $2 ); }
-	| declaration_qualifier_list type_qualifier_list storage_class_list
-		{ $$ = $1->addQualifiers( $2 )->addQualifiers( $3 ); }
-	;
+		storage_class_list
+		| type_qualifier_list storage_class_list		// remaining OBSOLESCENT (see 2)
+				{ $$ = $1->addQualifiers( $2 ); }
+		| declaration_qualifier_list type_qualifier_list storage_class_list
+				{ $$ = $1->addQualifiers( $2 )->addQualifiers( $3 ); }
+		;
 
 storage_class_list:
-		/* A semantic check is necessary to ensure a storage class is appropriate for the kind of
-		   declaration and that only one of each is specified, except for inline, which can appear
-		   with the others.
-
-		   ISO/IEC 9899:1999 Section 6.7.1(2) : At most, one storage-class specifier may be given in
-		   the declaration specifiers in a declaration. */
-	storage_class
-	| storage_class_list storage_class
-		{ $$ = $1->addQualifiers( $2 ); }
-	;
+				// A semantic check is necessary to ensure a storage class is appropriate for the kind of
+				// declaration and that only one of each is specified, except for inline, which can appear
+				// with the others.
+				//
+				// ISO/IEC 9899:1999 Section 6.7.1(2) : At most, one storage-class specifier may be given in
+				// the declaration specifiers in a declaration.
+		storage_class
+		| storage_class_list storage_class
+				{ $$ = $1->addQualifiers( $2 ); }
+		;
 
 storage_class:
-	storage_class_name
-	;
+		storage_class_name
+		;
 
 storage_class_name:
-	EXTERN
-		{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Extern ); }
-	| STATIC
-		{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Static ); }
-	| AUTO
-		{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Auto ); }
-	| REGISTER
-		{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Register ); }
-	| INLINE					// C99
-		// INLINE is essentially a storage class specifier for functions, and hence, belongs here.
-		{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Inline ); }
-	| FORTRAN					// C99
-		{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Fortran ); }
-	;
+		EXTERN
+				{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Extern ); }
+		| STATIC
+				{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Static ); }
+		| AUTO
+				{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Auto ); }
+		| REGISTER
+				{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Register ); }
+		| INLINE										// C99
+				// INLINE is essentially a storage class specifier for functions, and hence, belongs here.
+				{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Inline ); }
+		| FORTRAN										// C99
+				{ $$ = DeclarationNode::newStorageClass( DeclarationNode::Fortran ); }
+		;
 
 basic_type_name:
-	CHAR
-		{ $$ = DeclarationNode::newBasicType( DeclarationNode::Char ); }
-	| DOUBLE
-		{ $$ = DeclarationNode::newBasicType( DeclarationNode::Double ); }
-	| FLOAT
-		{ $$ = DeclarationNode::newBasicType( DeclarationNode::Float ); }
-	| INT
-		{ $$ = DeclarationNode::newBasicType( DeclarationNode::Int ); }
-	| LONG
-		{ $$ = DeclarationNode::newModifier( DeclarationNode::Long ); }
-	| SHORT
-		{ $$ = DeclarationNode::newModifier( DeclarationNode::Short ); }
-	| SIGNED
-		{ $$ = DeclarationNode::newModifier( DeclarationNode::Signed ); }
-	| UNSIGNED
-		{ $$ = DeclarationNode::newModifier( DeclarationNode::Unsigned ); }
-	| VOID
-		{ $$ = DeclarationNode::newBasicType( DeclarationNode::Void ); }
-	| BOOL						// C99
-		{ $$ = DeclarationNode::newBasicType( DeclarationNode::Bool ); }
-	| COMPLEX					// C99
-		{ $$ = DeclarationNode::newBasicType( DeclarationNode::Complex ); }
-	| IMAGINARY					// C99
-		{ $$ = DeclarationNode::newBasicType( DeclarationNode::Imaginary ); }
-	;
+		CHAR
+				{ $$ = DeclarationNode::newBasicType( DeclarationNode::Char ); }
+		| DOUBLE
+				{ $$ = DeclarationNode::newBasicType( DeclarationNode::Double ); }
+		| FLOAT
+				{ $$ = DeclarationNode::newBasicType( DeclarationNode::Float ); }
+		| INT
+				{ $$ = DeclarationNode::newBasicType( DeclarationNode::Int ); }
+		| LONG
+				{ $$ = DeclarationNode::newModifier( DeclarationNode::Long ); }
+		| SHORT
+				{ $$ = DeclarationNode::newModifier( DeclarationNode::Short ); }
+		| SIGNED
+				{ $$ = DeclarationNode::newModifier( DeclarationNode::Signed ); }
+		| UNSIGNED
+				{ $$ = DeclarationNode::newModifier( DeclarationNode::Unsigned ); }
+		| VOID
+				{ $$ = DeclarationNode::newBasicType( DeclarationNode::Void ); }
+		| BOOL											// C99
+				{ $$ = DeclarationNode::newBasicType( DeclarationNode::Bool ); }
+		| COMPLEX										// C99
+				{ $$ = DeclarationNode::newBasicType( DeclarationNode::Complex ); }
+		| IMAGINARY										// C99
+				{ $$ = DeclarationNode::newBasicType( DeclarationNode::Imaginary ); }
+		;
 
 basic_declaration_specifier:
-		// A semantic check is necessary for conflicting storage classes.
-	basic_type_specifier
-	| declaration_qualifier_list basic_type_specifier
-		{ $$ = $2->addQualifiers( $1 ); }
-	| basic_declaration_specifier storage_class	// remaining OBSOLESCENT (see 2)
-		{ $$ = $1->addQualifiers( $2 ); }
-	| basic_declaration_specifier storage_class type_qualifier_list
-		{ $$ = $1->addQualifiers( $2 )->addQualifiers( $3 ); }
-	| basic_declaration_specifier storage_class basic_type_specifier
-		{ $$ = $3->addQualifiers( $2 )->addType( $1 ); }
-	;
+				// A semantic check is necessary for conflicting storage classes.
+		basic_type_specifier
+		| declaration_qualifier_list basic_type_specifier
+				{ $$ = $2->addQualifiers( $1 ); }
+		| basic_declaration_specifier storage_class		// remaining OBSOLESCENT (see 2)
+				{ $$ = $1->addQualifiers( $2 ); }
+		| basic_declaration_specifier storage_class type_qualifier_list
+				{ $$ = $1->addQualifiers( $2 )->addQualifiers( $3 ); }
+		| basic_declaration_specifier storage_class basic_type_specifier
+				{ $$ = $3->addQualifiers( $2 )->addType( $1 ); }
+		;
 
 basic_type_specifier:
-	direct_type_name
-	| type_qualifier_list_opt indirect_type_name type_qualifier_list_opt
-		{ $$ = $2->addQualifiers( $1 )->addQualifiers( $3 ); }
-	;
+		direct_type_name
+		| type_qualifier_list_opt indirect_type_name type_qualifier_list_opt
+				{ $$ = $2->addQualifiers( $1 )->addQualifiers( $3 ); }
+		;
 
 direct_type_name:
-		// A semantic check is necessary for conflicting type qualifiers.
-	basic_type_name
-	| type_qualifier_list basic_type_name
-		{ $$ = $2->addQualifiers( $1 ); }
-	| direct_type_name type_qualifier
-		{ $$ = $1->addQualifiers( $2 ); }
-	| direct_type_name basic_type_name
-		{ $$ = $1->addType( $2 ); }
-	;
+				// A semantic check is necessary for conflicting type qualifiers.
+		basic_type_name
+		| type_qualifier_list basic_type_name
+				{ $$ = $2->addQualifiers( $1 ); }
+		| direct_type_name type_qualifier
+				{ $$ = $1->addQualifiers( $2 ); }
+		| direct_type_name basic_type_name
+				{ $$ = $1->addType( $2 ); }
+		;
 
 indirect_type_name:
-	TYPEOF '(' type_name ')'			// GCC: typeof(x) y;
-		{ $$ = $3; }
-	| TYPEOF '(' comma_expression ')'		// GCC: typeof(a+b) y;
-		{ $$ = DeclarationNode::newTypeof( $3 ); }
-	| ATTR_TYPEGENname '(' type_name ')'		// CFA: e.g., @type(x) y;
-		{ $$ = DeclarationNode::newAttr( $1, $3 ); }
-	| ATTR_TYPEGENname '(' comma_expression ')' 	// CFA: e.g., @type(a+b) y;
-		{ $$ = DeclarationNode::newAttr( $1, $3 ); }
-	;
+		TYPEOF '(' type_name ')'						// GCC: typeof(x) y;
+				{ $$ = $3; }
+		| TYPEOF '(' comma_expression ')'				// GCC: typeof(a+b) y;
+				{ $$ = DeclarationNode::newTypeof( $3 ); }
+		| ATTR_TYPEGENname '(' type_name ')'			// CFA: e.g., @type(x) y;
+				{ $$ = DeclarationNode::newAttr( $1, $3 ); }
+		| ATTR_TYPEGENname '(' comma_expression ')'		// CFA: e.g., @type(a+b) y;
+				{ $$ = DeclarationNode::newAttr( $1, $3 ); }
+		;
 
 sue_declaration_specifier:
-	sue_type_specifier
-	| declaration_qualifier_list sue_type_specifier
-		{ $$ = $2->addQualifiers( $1 ); }
-	| sue_declaration_specifier storage_class	// remaining OBSOLESCENT (see 2)
-		{ $$ = $1->addQualifiers( $2 ); }
-	| sue_declaration_specifier storage_class type_qualifier_list
-		{ $$ = $1->addQualifiers( $2 )->addQualifiers( $3 ); }
-	;
+		sue_type_specifier
+		| declaration_qualifier_list sue_type_specifier
+				{ $$ = $2->addQualifiers( $1 ); }
+		| sue_declaration_specifier storage_class		// remaining OBSOLESCENT (see 2)
+				{ $$ = $1->addQualifiers( $2 ); }
+		| sue_declaration_specifier storage_class type_qualifier_list
+				{ $$ = $1->addQualifiers( $2 )->addQualifiers( $3 ); }
+		;
 
 sue_type_specifier:
-	elaborated_type_name				// struct, union, enum
-	| type_qualifier_list elaborated_type_name
-		{ $$ = $2->addQualifiers( $1 ); }
-	| sue_type_specifier type_qualifier
-		{ $$ = $1->addQualifiers( $2 ); }
-	;
+		elaborated_type_name							// struct, union, enum
+		| type_qualifier_list elaborated_type_name
+				{ $$ = $2->addQualifiers( $1 ); }
+		| sue_type_specifier type_qualifier
+				{ $$ = $1->addQualifiers( $2 ); }
+		;
 
 typedef_declaration_specifier:
-	typedef_type_specifier
-	| declaration_qualifier_list typedef_type_specifier
-		{ $$ = $2->addQualifiers( $1 ); }
-	| typedef_declaration_specifier storage_class	// remaining OBSOLESCENT (see 2)
-		{ $$ = $1->addQualifiers( $2 ); }
-	| typedef_declaration_specifier storage_class type_qualifier_list
-		{ $$ = $1->addQualifiers( $2 )->addQualifiers( $3 ); }
-	;
-
-typedef_type_specifier:					// typedef types
-	TYPEDEFname
-		{ $$ = DeclarationNode::newFromTypedef( $1 ); }
-	| type_qualifier_list TYPEDEFname
-		{ $$ = DeclarationNode::newFromTypedef( $2 )->addQualifiers( $1 ); }
-	| typedef_type_specifier type_qualifier
-		{ $$ = $1->addQualifiers( $2 ); }
-	;
+		typedef_type_specifier
+		| declaration_qualifier_list typedef_type_specifier
+				{ $$ = $2->addQualifiers( $1 ); }
+		| typedef_declaration_specifier storage_class	// remaining OBSOLESCENT (see 2)
+				{ $$ = $1->addQualifiers( $2 ); }
+		| typedef_declaration_specifier storage_class type_qualifier_list
+				{ $$ = $1->addQualifiers( $2 )->addQualifiers( $3 ); }
+		;
+
+typedef_type_specifier:									// typedef types
+		TYPEDEFname
+				{ $$ = DeclarationNode::newFromTypedef( $1 ); }
+		| type_qualifier_list TYPEDEFname
+				{ $$ = DeclarationNode::newFromTypedef( $2 )->addQualifiers( $1 ); }
+		| typedef_type_specifier type_qualifier
+				{ $$ = $1->addQualifiers( $2 ); }
+		;
 
 elaborated_type_name:
-	aggregate_name
-	| enum_name
-	;
+		aggregate_name
+		| enum_name
+		;
 
 aggregate_name:
-	aggregate_key '{' field_declaration_list '}'
-		{ $$ = DeclarationNode::newAggregate( $1, 0, 0, 0, $3 ); }
-	| aggregate_key no_attr_identifier_or_typedef_name
-		{ $$ = DeclarationNode::newAggregate( $1, $2, 0, 0, 0 ); }
-	| aggregate_key no_attr_identifier_or_typedef_name '{' field_declaration_list '}'
-		{ $$ = DeclarationNode::newAggregate( $1, $2, 0, 0, $4 ); }
-	| aggregate_key '(' push type_parameter_list pop ')' '{' field_declaration_list '}' // CFA
-		{ $$ = DeclarationNode::newAggregate( $1, 0, $4, 0, $8 ); }
-	| aggregate_key '(' push type_parameter_list pop ')' no_attr_identifier_or_typedef_name // CFA
-		{ $$ = DeclarationNode::newAggregate( $1, $7, $4, 0, 0 ); }
-	| aggregate_key '(' push type_parameter_list pop ')' no_attr_identifier_or_typedef_name '{' field_declaration_list '}' // CFA
-		{ $$ = DeclarationNode::newAggregate( $1, $7, $4, 0, $9 ); }
-	| aggregate_key '(' push type_parameter_list pop ')' '(' type_name_list ')' '{' field_declaration_list '}' // CFA
-		{ $$ = DeclarationNode::newAggregate( $1, 0, $4, $8, $11 ); }
-	| aggregate_key '(' push type_name_list pop ')' no_attr_identifier_or_typedef_name // CFA
-		// push and pop are only to prevent S/R conflicts
-		{ $$ = DeclarationNode::newAggregate( $1, $7, 0, $4, 0 ); }
-	| aggregate_key '(' push type_parameter_list pop ')' '(' type_name_list ')' no_attr_identifier_or_typedef_name '{' field_declaration_list '}' // CFA
-		{ $$ = DeclarationNode::newAggregate( $1, $10, $4, $8, $12 ); }
-	;
+		aggregate_key '{' field_declaration_list '}'
+				{ $$ = DeclarationNode::newAggregate( $1, 0, 0, 0, $3 ); }
+		| aggregate_key no_attr_identifier_or_typedef_name
+				{ $$ = DeclarationNode::newAggregate( $1, $2, 0, 0, 0 ); }
+		| aggregate_key no_attr_identifier_or_typedef_name '{' field_declaration_list '}'
+				{ $$ = DeclarationNode::newAggregate( $1, $2, 0, 0, $4 ); }
+		| aggregate_key '(' push type_parameter_list pop ')' '{' field_declaration_list '}' // CFA
+				{ $$ = DeclarationNode::newAggregate( $1, 0, $4, 0, $8 ); }
+		| aggregate_key '(' push type_parameter_list pop ')' no_attr_identifier_or_typedef_name // CFA
+				{ $$ = DeclarationNode::newAggregate( $1, $7, $4, 0, 0 ); }
+		| aggregate_key '(' push type_parameter_list pop ')' no_attr_identifier_or_typedef_name '{' field_declaration_list '}' // CFA
+				{ $$ = DeclarationNode::newAggregate( $1, $7, $4, 0, $9 ); }
+		| aggregate_key '(' push type_parameter_list pop ')' '(' type_name_list ')' '{' field_declaration_list '}' // CFA
+				{ $$ = DeclarationNode::newAggregate( $1, 0, $4, $8, $11 ); }
+		| aggregate_key '(' push type_name_list pop ')' no_attr_identifier_or_typedef_name // CFA
+				// push and pop are only to prevent S/R conflicts
+				{ $$ = DeclarationNode::newAggregate( $1, $7, 0, $4, 0 ); }
+		| aggregate_key '(' push type_parameter_list pop ')' '(' type_name_list ')' no_attr_identifier_or_typedef_name '{' field_declaration_list '}' // CFA
+				{ $$ = DeclarationNode::newAggregate( $1, $10, $4, $8, $12 ); }
+		;
 
 aggregate_key:
-	STRUCT attribute_list_opt
-		{ $$ = DeclarationNode::Struct; }
-	| UNION attribute_list_opt
-		{ $$ = DeclarationNode::Union; }
-	;
+		STRUCT attribute_list_opt
+				{ $$ = DeclarationNode::Struct; }
+		| UNION attribute_list_opt
+				{ $$ = DeclarationNode::Union; }
+		;
 
 field_declaration_list:
-	field_declaration
-		{ $$ = $1; }
-	| field_declaration_list field_declaration
-		{ $$ = $1->appendList( $2 ); }
-	;
+		field_declaration
+				{ $$ = $1; }
+		| field_declaration_list field_declaration
+				{ $$ = $1->appendList( $2 ); }
+		;
 
 field_declaration:
-	new_field_declaring_list ';'			// CFA, new style field declaration
-	| EXTENSION new_field_declaring_list ';'	// GCC
-		{ $$ = $2; }
-	| field_declaring_list ';'
-	| EXTENSION field_declaring_list ';'		// GCC
-		{ $$ = $2; }
-	;
-
-new_field_declaring_list:				// CFA, new style field declaration
-	new_abstract_declarator_tuple			// CFA, no field name
-	| new_abstract_declarator_tuple no_attr_identifier_or_typedef_name
-		{ $$ = $1->addName( $2 ); }
-	| new_field_declaring_list ',' no_attr_identifier_or_typedef_name
-		{ $$ = $1->appendList( $1->cloneType( $3 ) ); }
-	| new_field_declaring_list ','			// CFA, no field name
-		{ $$ = $1->appendList( $1->cloneType( 0 ) ); }
-	;
+		new_field_declaring_list ';'					// CFA, new style field declaration
+		| EXTENSION new_field_declaring_list ';'		// GCC
+				{ $$ = $2; }
+		| field_declaring_list ';'
+		| EXTENSION field_declaring_list ';'			// GCC
+				{ $$ = $2; }
+		;
+
+new_field_declaring_list:								// CFA, new style field declaration
+		new_abstract_declarator_tuple					// CFA, no field name
+		| new_abstract_declarator_tuple no_attr_identifier_or_typedef_name
+				{ $$ = $1->addName( $2 ); }
+		| new_field_declaring_list ',' no_attr_identifier_or_typedef_name
+				{ $$ = $1->appendList( $1->cloneType( $3 ) ); }
+		| new_field_declaring_list ','					// CFA, no field name
+				{ $$ = $1->appendList( $1->cloneType( 0 ) ); }
+		;
 
 field_declaring_list:
-	type_specifier field_declarator
-		{ $$ = $2->addType( $1 ); }
-	| field_declaring_list ',' attribute_list_opt field_declarator
-		{ $$ = $1->appendList( $1->cloneBaseType( $4 ) ); }
-	;
+		type_specifier field_declarator
+				{ $$ = $2->addType( $1 ); }
+		| field_declaring_list ',' attribute_list_opt field_declarator
+				{ $$ = $1->appendList( $1->cloneBaseType( $4 ) ); }
+		;
 
 field_declarator:
-	// empty
-		{ $$ = DeclarationNode::newName( 0 ); /* XXX */ } // CFA, no field name
-	| bit_subrange_size				// no field name
-		{ $$ = DeclarationNode::newBitfield( $1 ); }
-	| variable_declarator bit_subrange_size_opt
-		// A semantic check is required to ensure bit_subrange only appears on base type int.
-		{ $$ = $1->addBitfield( $2 ); }
-	| typedef_redeclarator bit_subrange_size_opt
-		// A semantic check is required to ensure bit_subrange only appears on base type int.
-		{ $$ = $1->addBitfield( $2 ); }
-	| variable_abstract_declarator			// CFA, no field name
-	;
+		// empty
+				{ $$ = DeclarationNode::newName( 0 ); /* XXX */ } // CFA, no field name
+		| bit_subrange_size								// no field name
+				{ $$ = DeclarationNode::newBitfield( $1 ); }
+		| variable_declarator bit_subrange_size_opt
+				// A semantic check is required to ensure bit_subrange only appears on base type int.
+				{ $$ = $1->addBitfield( $2 ); }
+		| typedef_redeclarator bit_subrange_size_opt
+				// A semantic check is required to ensure bit_subrange only appears on base type int.
+				{ $$ = $1->addBitfield( $2 ); }
+		| variable_abstract_declarator					// CFA, no field name
+		;
 
 bit_subrange_size_opt:
-	// empty
-		{ $$ = 0; }
-	| bit_subrange_size
-		{ $$ = $1; }
-	;
+		// empty
+				{ $$ = 0; }
+		| bit_subrange_size
+				{ $$ = $1; }
+		;
 
 bit_subrange_size:
-	':' constant_expression
-		{ $$ = $2; }
-	;
+		':' constant_expression
+				{ $$ = $2; }
+		;
 
 enum_key:
-	ENUM attribute_list_opt
-	;
+		ENUM attribute_list_opt
+		;
 
 enum_name:
-	enum_key '{' enumerator_list comma_opt '}'
-		{ $$ = DeclarationNode::newEnum( 0, $3 ); }
-	| enum_key no_attr_identifier_or_typedef_name '{' enumerator_list comma_opt '}'
-		{ $$ = DeclarationNode::newEnum( $2, $4 ); }
-	| enum_key no_attr_identifier_or_typedef_name
-		{ $$ = DeclarationNode::newEnum( $2, 0 ); }
-	;
+		enum_key '{' enumerator_list comma_opt '}'
+				{ $$ = DeclarationNode::newEnum( 0, $3 ); }
+		| enum_key no_attr_identifier_or_typedef_name '{' enumerator_list comma_opt '}'
+				{ $$ = DeclarationNode::newEnum( $2, $4 ); }
+		| enum_key no_attr_identifier_or_typedef_name
+				{ $$ = DeclarationNode::newEnum( $2, 0 ); }
+		;
 
 enumerator_list:
-	no_attr_identifier_or_typedef_name enumerator_value_opt
-		{ $$ = DeclarationNode::newEnumConstant( $1, $2 ); }
-	| enumerator_list ',' no_attr_identifier_or_typedef_name enumerator_value_opt
-		{ $$ = $1->appendList( DeclarationNode::newEnumConstant( $3, $4 ) ); }
-	;
+		no_attr_identifier_or_typedef_name enumerator_value_opt
+				{ $$ = DeclarationNode::newEnumConstant( $1, $2 ); }
+		| enumerator_list ',' no_attr_identifier_or_typedef_name enumerator_value_opt
+				{ $$ = $1->appendList( DeclarationNode::newEnumConstant( $3, $4 ) ); }
+		;
 
 enumerator_value_opt:
-	// empty
-		{ $$ = 0; }
-	| '=' constant_expression
-		{ $$ = $2; }
-	;
+		// empty
+				{ $$ = 0; }
+		| '=' constant_expression
+				{ $$ = $2; }
+		;
 
 // Minimum of one parameter after which ellipsis is allowed only at the end.
 
-new_parameter_type_list_opt:				// CFA
-	// empty
-		{ $$ = 0; }
-	| new_parameter_type_list
-	;
-
-new_parameter_type_list:				// CFA, abstract + real
-	new_abstract_parameter_list
-	| new_parameter_list
-	| new_parameter_list pop ',' push new_abstract_parameter_list
-		{ $$ = $1->appendList( $5 ); }
-	| new_abstract_parameter_list pop ',' push ELLIPSIS
-		{ $$ = $1->addVarArgs(); }
-	| new_parameter_list pop ',' push ELLIPSIS
-		{ $$ = $1->addVarArgs(); }
-	;
-
-new_parameter_list:					// CFA
-		// To obtain LR(1) between new_parameter_list and new_abstract_tuple, the last
-		// new_abstract_parameter_list is factored out from new_parameter_list, flattening the rules
-		// to get lookahead to the ']'.
-	new_parameter_declaration
-	| new_abstract_parameter_list pop ',' push new_parameter_declaration
-		{ $$ = $1->appendList( $5 ); }
-	| new_parameter_list pop ',' push new_parameter_declaration
-		{ $$ = $1->appendList( $5 ); }
-	| new_parameter_list pop ',' push new_abstract_parameter_list pop ',' push new_parameter_declaration
-		{ $$ = $1->appendList( $5 )->appendList( $9 ); }
-	;
-
-new_abstract_parameter_list:				// CFA, new & old style abstract
-	new_abstract_parameter_declaration
-	| new_abstract_parameter_list pop ',' push new_abstract_parameter_declaration
-		{ $$ = $1->appendList( $5 ); }
-	;
+new_parameter_type_list_opt:							// CFA
+		// empty
+				{ $$ = 0; }
+		| new_parameter_type_list
+		;
+
+new_parameter_type_list:								// CFA, abstract + real
+		new_abstract_parameter_list
+		| new_parameter_list
+		| new_parameter_list pop ',' push new_abstract_parameter_list
+				{ $$ = $1->appendList( $5 ); }
+		| new_abstract_parameter_list pop ',' push ELLIPSIS
+				{ $$ = $1->addVarArgs(); }
+		| new_parameter_list pop ',' push ELLIPSIS
+				{ $$ = $1->addVarArgs(); }
+		;
+
+new_parameter_list:										// CFA
+				// To obtain LR(1) between new_parameter_list and new_abstract_tuple, the last
+				// new_abstract_parameter_list is factored out from new_parameter_list, flattening the rules
+				// to get lookahead to the ']'.
+		new_parameter_declaration
+		| new_abstract_parameter_list pop ',' push new_parameter_declaration
+				{ $$ = $1->appendList( $5 ); }
+		| new_parameter_list pop ',' push new_parameter_declaration
+				{ $$ = $1->appendList( $5 ); }
+		| new_parameter_list pop ',' push new_abstract_parameter_list pop ',' push new_parameter_declaration
+				{ $$ = $1->appendList( $5 )->appendList( $9 ); }
+		;
+
+new_abstract_parameter_list:							// CFA, new & old style abstract
+		new_abstract_parameter_declaration
+		| new_abstract_parameter_list pop ',' push new_abstract_parameter_declaration
+				{ $$ = $1->appendList( $5 ); }
+		;
 
 parameter_type_list_opt:
-	// empty
-		{ $$ = 0; }
-	| parameter_type_list
-	;
+		// empty
+				{ $$ = 0; }
+		| parameter_type_list
+		;
 
 parameter_type_list:
-	parameter_list
-	| parameter_list pop ',' push ELLIPSIS
-		{ $$ = $1->addVarArgs(); }
-	;
-
-parameter_list:						// abstract + real
-	abstract_parameter_declaration
-	| parameter_declaration
-	| parameter_list pop ',' push abstract_parameter_declaration
-		{ $$ = $1->appendList( $5 ); }
-	| parameter_list pop ',' push parameter_declaration
-		{ $$ = $1->appendList( $5 ); }
-	;
+		parameter_list
+		| parameter_list pop ',' push ELLIPSIS
+				{ $$ = $1->addVarArgs(); }
+		;
+
+parameter_list:											// abstract + real
+		abstract_parameter_declaration
+		| parameter_declaration
+		| parameter_list pop ',' push abstract_parameter_declaration
+				{ $$ = $1->appendList( $5 ); }
+		| parameter_list pop ',' push parameter_declaration
+				{ $$ = $1->appendList( $5 ); }
+		;
 
 // Provides optional identifier names (abstract_declarator/variable_declarator), no initialization, different
@@ -1534,44 +1536,44 @@
 // function prototypes.
 
-new_parameter_declaration:				// CFA, new & old style parameter declaration
-	parameter_declaration
-	| new_identifier_parameter_declarator_no_tuple identifier_or_typedef_name assignment_opt
-		{ $$ = $1->addName( $2 ); }
-	| new_abstract_tuple identifier_or_typedef_name assignment_opt
-		// To obtain LR(1), these rules must be duplicated here (see new_abstract_declarator).
-		{ $$ = $1->addName( $2 ); }
-	| type_qualifier_list new_abstract_tuple identifier_or_typedef_name assignment_opt
-		{ $$ = $2->addName( $3 )->addQualifiers( $1 ); }
-	| new_function_specifier
-	;
-
-new_abstract_parameter_declaration:			// CFA, new & old style parameter declaration
-	abstract_parameter_declaration
-	| new_identifier_parameter_declarator_no_tuple
-	| new_abstract_tuple
-		// To obtain LR(1), these rules must be duplicated here (see new_abstract_declarator).
-	| type_qualifier_list new_abstract_tuple
-		{ $$ = $2->addQualifiers( $1 ); }
-	| new_abstract_function
-	;
+new_parameter_declaration:								// CFA, new & old style parameter declaration
+		parameter_declaration
+		| new_identifier_parameter_declarator_no_tuple identifier_or_typedef_name assignment_opt
+				{ $$ = $1->addName( $2 ); }
+		| new_abstract_tuple identifier_or_typedef_name assignment_opt
+				// To obtain LR(1), these rules must be duplicated here (see new_abstract_declarator).
+				{ $$ = $1->addName( $2 ); }
+		| type_qualifier_list new_abstract_tuple identifier_or_typedef_name assignment_opt
+				{ $$ = $2->addName( $3 )->addQualifiers( $1 ); }
+		| new_function_specifier
+		;
+
+new_abstract_parameter_declaration:						// CFA, new & old style parameter declaration
+		abstract_parameter_declaration
+		| new_identifier_parameter_declarator_no_tuple
+		| new_abstract_tuple
+				// To obtain LR(1), these rules must be duplicated here (see new_abstract_declarator).
+		| type_qualifier_list new_abstract_tuple
+				{ $$ = $2->addQualifiers( $1 ); }
+		| new_abstract_function
+		;
 
 parameter_declaration:
-	declaration_specifier identifier_parameter_declarator assignment_opt
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    $$ = $2->addType( $1 )->addInitializer( new InitializerNode($3) );
-		}
-	| declaration_specifier typedef_parameter_redeclarator assignment_opt
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    $$ = $2->addType( $1 )->addInitializer( new InitializerNode($3) );
-		}
-	;
+		declaration_specifier identifier_parameter_declarator assignment_opt
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					$$ = $2->addType( $1 )->addInitializer( new InitializerNode($3) );
+				}
+		| declaration_specifier typedef_parameter_redeclarator assignment_opt
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					$$ = $2->addType( $1 )->addInitializer( new InitializerNode($3) );
+				}
+		;
 
 abstract_parameter_declaration:
-	declaration_specifier
-	| declaration_specifier abstract_parameter_declarator
-		{ $$ = $2->addType( $1 ); }
-	;
+		declaration_specifier
+		| declaration_specifier abstract_parameter_declarator
+				{ $$ = $2->addType( $1 ); }
+		;
 
 // ISO/IEC 9899:1999 Section 6.9.1(6) : "An identifier declared as a typedef name shall not be redeclared as a
@@ -1579,66 +1581,67 @@
 // based only on identifiers.  The ANSI-style parameter-list can redefine a typedef name.
 
-identifier_list:					// K&R-style parameter list => no types
-	no_attr_identifier
-		{ $$ = DeclarationNode::newName( $1 ); }
-	| identifier_list ',' no_attr_identifier
-		{ $$ = $1->appendList( DeclarationNode::newName( $3 ) ); }
-	;
+identifier_list:										// K&R-style parameter list => no types
+		no_attr_identifier
+				{ $$ = DeclarationNode::newName( $1 ); }
+		| identifier_list ',' no_attr_identifier
+				{ $$ = $1->appendList( DeclarationNode::newName( $3 ) ); }
+		;
 
 identifier_or_typedef_name:
-	identifier
-	| TYPEDEFname
-	| TYPEGENname
-	;
+		identifier
+		| TYPEDEFname
+		| TYPEGENname
+		;
 
 no_01_identifier_or_typedef_name:
-	no_01_identifier
-	| TYPEDEFname
-	| TYPEGENname
-	;
+		no_01_identifier
+		| TYPEDEFname
+		| TYPEGENname
+		;
 
 no_attr_identifier_or_typedef_name:
-	no_attr_identifier
-	| TYPEDEFname
-	| TYPEGENname
-	;
-
-type_name_no_function:					// sizeof, alignof, cast (constructor)
-	new_abstract_declarator_tuple			// CFA
-	| type_specifier
-	| type_specifier variable_abstract_declarator
-		{ $$ = $2->addType( $1 ); }
-	;
-
-type_name:						// typeof, assertion
-	new_abstract_declarator_tuple			// CFA
-	| new_abstract_function				// CFA
-	| type_specifier
-	| type_specifier abstract_declarator
-		{ $$ = $2->addType( $1 ); }
-	;
+		no_attr_identifier
+		| TYPEDEFname
+		| TYPEGENname
+		;
+
+type_name_no_function:									// sizeof, alignof, cast (constructor)
+		new_abstract_declarator_tuple					// CFA
+		| type_specifier
+		| type_specifier variable_abstract_declarator
+				{ $$ = $2->addType( $1 ); }
+		;
+
+type_name:												// typeof, assertion
+		new_abstract_declarator_tuple					// CFA
+		| new_abstract_function							// CFA
+		| type_specifier
+		| type_specifier abstract_declarator
+				{ $$ = $2->addType( $1 ); }
+		;
 
 initializer_opt:
-	/* empty */                             	{ $$ = 0; }
-	| '=' initializer                       	{ $$ = $2; }
-	;
+		// empty
+				{ $$ = 0; }
+		| '=' initializer								{ $$ = $2; }
+		;
 
 initializer:
-	assignment_expression				{ $$ = new InitializerNode($1); }
-	| '{' initializer_list comma_opt '}'    	{ $$ = new InitializerNode($2, true); }
-	;
+		assignment_expression							{ $$ = new InitializerNode($1); }
+		| '{' initializer_list comma_opt '}'			{ $$ = new InitializerNode($2, true); }
+		;
 
 initializer_list:
-	initializer
-	| designation initializer			{ $$ = $2->set_designators( $1 ); }
-	| initializer_list ',' initializer		{ $$ = (InitializerNode *)( $1->set_link($3) ); }
-	| initializer_list ',' designation initializer
-							{ $$ = (InitializerNode *)( $1->set_link( $4->set_designators($3) ) ); }
-	;
-
-// There is an unreconcileable parsing problem between C99 and CFA with respect to designators. The problem
-// is use of '=' to separator the designator from the initializer value, as in:
-//
-//	int x[10] = { [1] = 3 };
+		initializer
+		| designation initializer						{ $$ = $2->set_designators( $1 ); }
+		| initializer_list ',' initializer				{ $$ = (InitializerNode *)( $1->set_link($3) ); }
+		| initializer_list ',' designation initializer
+				{ $$ = (InitializerNode *)( $1->set_link( $4->set_designators($3) ) ); }
+		;
+
+// There is an unreconcileable parsing problem between C99 and CFA with respect to designators. The problem is
+// use of '=' to separator the designator from the initializer value, as in:
+//
+//		int x[10] = { [1] = 3 };
 //
 // The string "[1] = 3" can be parsed as a designator assignment or a tuple assignment.  To disambiguate this
@@ -1648,28 +1651,28 @@
 
 designation:
-	designator_list ':'				// C99, CFA uses ":" instead of "="
-	| no_attr_identifier_or_typedef_name ':'	// GCC, field name
-							{ $$ = new VarRefNode( $1 ); }
-	;
-
-designator_list:					// C99
-	designator
-	| designator_list designator			{ $$ = (ExpressionNode *)($1->set_link( $2 )); }
-	;
+		designator_list ':'								// C99, CFA uses ":" instead of "="
+		| no_attr_identifier_or_typedef_name ':'		// GCC, field name
+						{ $$ = new VarRefNode( $1 ); }
+		;
+
+designator_list:										// C99
+		designator
+		| designator_list designator						{ $$ = (ExpressionNode *)($1->set_link( $2 )); }
+		;
 
 designator:
-	'.' no_attr_identifier_or_typedef_name		// C99, field name
-							{ $$ = new VarRefNode( $2 ); }
-	| '[' push assignment_expression pop ']'	// C99, single array element
-		/* assignment_expression used instead of constant_expression because of shift/reduce conflicts
-		   with tuple. */
-							{ $$ = $3; }
-	| '[' push subrange pop ']'			// CFA, multiple array elements
-							{ $$ = $3; }
-	| '[' push constant_expression ELLIPSIS constant_expression pop ']' // GCC, multiple array elements
-							{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Range), $3, $5); }
-	| '.' '[' push field_list pop ']'		// CFA, tuple field selector
-							{ $$ = $4; }
-	;
+		'.' no_attr_identifier_or_typedef_name			// C99, field name
+				{ $$ = new VarRefNode( $2 ); }
+		| '[' push assignment_expression pop ']'		// C99, single array element
+				// assignment_expression used instead of constant_expression because of shift/reduce conflicts
+				// with tuple.
+				{ $$ = $3; }
+		| '[' push subrange pop ']'						// CFA, multiple array elements
+				{ $$ = $3; }
+		| '[' push constant_expression ELLIPSIS constant_expression pop ']' // GCC, multiple array elements
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Range), $3, $5); }
+		| '.' '[' push field_list pop ']'				// CFA, tuple field selector
+				{ $$ = $4; }
+		;
 
 // The CFA type system is based on parametric polymorphism, the ability to declare functions with type
@@ -1692,354 +1695,347 @@
 //     to declare requirements on type arguments of polymorphic functions.
 
-typegen_declaration_specifier:				// CFA
-	typegen_type_specifier
-	| declaration_qualifier_list typegen_type_specifier
-		{ $$ = $2->addQualifiers( $1 ); }
-	| typegen_declaration_specifier storage_class	// remaining OBSOLESCENT (see 2)
-		{ $$ = $1->addQualifiers( $2 ); }
-	| typegen_declaration_specifier storage_class type_qualifier_list
-		{ $$ = $1->addQualifiers( $2 )->addQualifiers( $3 ); }
-	;
-
-typegen_type_specifier:					// CFA
-	TYPEGENname '(' type_name_list ')'
-		{ $$ = DeclarationNode::newFromTypeGen( $1, $3 ); }
-	| type_qualifier_list TYPEGENname '(' type_name_list ')'
-		{ $$ = DeclarationNode::newFromTypeGen( $2, $4 )->addQualifiers( $1 ); }
-	| typegen_type_specifier type_qualifier
-		{ $$ = $1->addQualifiers( $2 ); }
-	;
-
-type_parameter_list:					// CFA
-	type_parameter assignment_opt
-	| type_parameter_list ',' type_parameter assignment_opt
-		{ $$ = $1->appendList( $3 ); }
-	;
-
-type_parameter:						// CFA
-	type_class no_attr_identifier_or_typedef_name
-		{ typedefTable.addToEnclosingScope(*($2), TypedefTable::TD); }
-	  assertion_list_opt
-		{ $$ = DeclarationNode::newTypeParam( $1, $2 )->addAssertions( $4 ); }
-	| type_specifier identifier_parameter_declarator
-	;
-
-type_class:						// CFA
-	TYPE
-		{ $$ = DeclarationNode::Type; }
-	| DTYPE
-		{ $$ = DeclarationNode::Ftype; }
-	| FTYPE
-		{ $$ = DeclarationNode::Dtype; }
-	;
-
-assertion_list_opt:					// CFA
-	// empty
-		{ $$ = 0; }
-	| assertion_list_opt assertion
-		{ $$ = $1 == 0 ? $2 : $1->appendList( $2 ); }
-	;
-
-assertion:						// CFA
-	'|' no_attr_identifier_or_typedef_name '(' type_name_list ')'
-		{
-		    typedefTable.openContext( *($2) );
-		    $$ = DeclarationNode::newContextUse( $2, $4 );
-		}
-	| '|' '{' push context_declaration_list '}'
-		{ $$ = $4; }
-	| '|' '(' push type_parameter_list pop ')' '{' push context_declaration_list '}' '(' type_name_list ')'
-		{ $$ = 0; }
-	;
-
-type_name_list:						// CFA
-	type_name
-		{ $$ = new TypeValueNode( $1 ); }
-	| assignment_expression
-	| type_name_list ',' type_name
-		{ $$ = (ExpressionNode *)($1->set_link(new TypeValueNode( $3 ))); }
-	| type_name_list ',' assignment_expression
-		{ $$ = (ExpressionNode *)($1->set_link($3)); }
-	;
-
-type_declaring_list:					// CFA
-	TYPE type_declarator
-		{ $$ = $2; }
-	| storage_class_list TYPE type_declarator
-		{ $$ = $3->addQualifiers( $1 ); }
-	| type_declaring_list ',' type_declarator
-		{ $$ = $1->appendList( $3->copyStorageClasses( $1 ) ); }
-	;
-
-type_declarator:					// CFA
-	type_declarator_name assertion_list_opt
-		{ $$ = $1->addAssertions( $2 ); }
-	| type_declarator_name assertion_list_opt '=' type_name
-		{ $$ = $1->addAssertions( $2 )->addType( $4 ); }
-	;
-
-type_declarator_name:					// CFA
-	no_attr_identifier_or_typedef_name
-		{
-		    typedefTable.addToEnclosingScope(*($1), TypedefTable::TD);
-		    $$ = DeclarationNode::newTypeDecl( $1, 0 );
-		}
-	| no_01_identifier_or_typedef_name '(' push type_parameter_list pop ')'
-		{
-		    typedefTable.addToEnclosingScope(*($1), TypedefTable::TG);
-		    $$ = DeclarationNode::newTypeDecl( $1, $4 );
-		}
-	;
-
-context_specifier:					// CFA
-	CONTEXT no_attr_identifier_or_typedef_name '(' push type_parameter_list pop ')' '{' '}'
-		{
-		    typedefTable.addToEnclosingScope(*($2), TypedefTable::ID );
-		    $$ = DeclarationNode::newContext( $2, $5, 0 );
-		}
-	| CONTEXT no_attr_identifier_or_typedef_name '(' push type_parameter_list pop ')' '{'
-		{
-		    typedefTable.enterContext( *($2) );
-		    typedefTable.enterScope();
-		}
-	  context_declaration_list '}'
-		{
-		    typedefTable.leaveContext();
-		    typedefTable.addToEnclosingScope(*($2), TypedefTable::ID );
-		    $$ = DeclarationNode::newContext( $2, $5, $10 );
-		}
-	;
-
-context_declaration_list:				// CFA
-	context_declaration
-	| context_declaration_list push context_declaration
-		{ $$ = $1->appendList( $3 ); }
-	;
-
-context_declaration:					// CFA
-	new_context_declaring_list pop ';'
-	| context_declaring_list pop ';'
-	;
-
-new_context_declaring_list:				// CFA
-	new_variable_specifier
-		{
-		    typedefTable.addToEnclosingScope2( TypedefTable::ID );
-		    $$ = $1;
-		}
-	| new_function_specifier
-		{
-		    typedefTable.addToEnclosingScope2( TypedefTable::ID );
-		    $$ = $1;
-		}
-	| new_context_declaring_list pop ',' push identifier_or_typedef_name
-		{
-		    typedefTable.addToEnclosingScope2( *($5), TypedefTable::ID );
-		    $$ = $1->appendList( $1->cloneType( $5 ) );
-		}
-	;
-
-context_declaring_list:					// CFA
-	type_specifier declarator
-		{
-		    typedefTable.addToEnclosingScope2( TypedefTable::ID );
-		    $$ = $2->addType( $1 );
-		}
-	| context_declaring_list pop ',' push declarator
-		{
-		    typedefTable.addToEnclosingScope2( TypedefTable::ID );
-		    $$ = $1->appendList( $1->cloneBaseType( $5 ) );
-		}
-	;
+typegen_declaration_specifier:							// CFA
+		typegen_type_specifier
+		| declaration_qualifier_list typegen_type_specifier
+				{ $$ = $2->addQualifiers( $1 ); }
+		| typegen_declaration_specifier storage_class	// remaining OBSOLESCENT (see 2)
+				{ $$ = $1->addQualifiers( $2 ); }
+		| typegen_declaration_specifier storage_class type_qualifier_list
+				{ $$ = $1->addQualifiers( $2 )->addQualifiers( $3 ); }
+		;
+
+typegen_type_specifier:									// CFA
+		TYPEGENname '(' type_name_list ')'
+				{ $$ = DeclarationNode::newFromTypeGen( $1, $3 ); }
+		| type_qualifier_list TYPEGENname '(' type_name_list ')'
+				{ $$ = DeclarationNode::newFromTypeGen( $2, $4 )->addQualifiers( $1 ); }
+		| typegen_type_specifier type_qualifier
+				{ $$ = $1->addQualifiers( $2 ); }
+		;
+
+type_parameter_list:									// CFA
+		type_parameter assignment_opt
+		| type_parameter_list ',' type_parameter assignment_opt
+				{ $$ = $1->appendList( $3 ); }
+		;
+
+type_parameter:											// CFA
+		type_class no_attr_identifier_or_typedef_name
+				{ typedefTable.addToEnclosingScope(*($2), TypedefTable::TD); }
+		  assertion_list_opt
+				{ $$ = DeclarationNode::newTypeParam( $1, $2 )->addAssertions( $4 ); }
+		| type_specifier identifier_parameter_declarator
+		;
+
+type_class:												// CFA
+		TYPE
+				{ $$ = DeclarationNode::Type; }
+		| DTYPE
+				{ $$ = DeclarationNode::Ftype; }
+		| FTYPE
+				{ $$ = DeclarationNode::Dtype; }
+		;
+
+assertion_list_opt:										// CFA
+		// empty
+				{ $$ = 0; }
+		| assertion_list_opt assertion
+				{ $$ = $1 == 0 ? $2 : $1->appendList( $2 ); }
+		;
+
+assertion:												// CFA
+		'|' no_attr_identifier_or_typedef_name '(' type_name_list ')'
+				{
+					typedefTable.openContext( *($2) );
+					$$ = DeclarationNode::newContextUse( $2, $4 );
+				}
+		| '|' '{' push context_declaration_list '}'
+				{ $$ = $4; }
+		| '|' '(' push type_parameter_list pop ')' '{' push context_declaration_list '}' '(' type_name_list ')'
+				{ $$ = 0; }
+		;
+
+type_name_list:											// CFA
+		type_name
+				{ $$ = new TypeValueNode( $1 ); }
+		| assignment_expression
+		| type_name_list ',' type_name
+				{ $$ = (ExpressionNode *)($1->set_link(new TypeValueNode( $3 ))); }
+		| type_name_list ',' assignment_expression
+				{ $$ = (ExpressionNode *)($1->set_link($3)); }
+		;
+
+type_declaring_list:									// CFA
+		TYPE type_declarator
+				{ $$ = $2; }
+		| storage_class_list TYPE type_declarator
+				{ $$ = $3->addQualifiers( $1 ); }
+		| type_declaring_list ',' type_declarator
+				{ $$ = $1->appendList( $3->copyStorageClasses( $1 ) ); }
+		;
+
+type_declarator:										// CFA
+		type_declarator_name assertion_list_opt
+				{ $$ = $1->addAssertions( $2 ); }
+		| type_declarator_name assertion_list_opt '=' type_name
+				{ $$ = $1->addAssertions( $2 )->addType( $4 ); }
+		;
+
+type_declarator_name:									// CFA
+		no_attr_identifier_or_typedef_name
+				{
+					typedefTable.addToEnclosingScope(*($1), TypedefTable::TD);
+					$$ = DeclarationNode::newTypeDecl( $1, 0 );
+				}
+		| no_01_identifier_or_typedef_name '(' push type_parameter_list pop ')'
+				{
+					typedefTable.addToEnclosingScope(*($1), TypedefTable::TG);
+					$$ = DeclarationNode::newTypeDecl( $1, $4 );
+				}
+		;
+
+context_specifier:										// CFA
+		CONTEXT no_attr_identifier_or_typedef_name '(' push type_parameter_list pop ')' '{' '}'
+				{
+					typedefTable.addToEnclosingScope(*($2), TypedefTable::ID );
+					$$ = DeclarationNode::newContext( $2, $5, 0 );
+				}
+		| CONTEXT no_attr_identifier_or_typedef_name '(' push type_parameter_list pop ')' '{'
+				{
+					typedefTable.enterContext( *($2) );
+					typedefTable.enterScope();
+				}
+		  context_declaration_list '}'
+				{
+					typedefTable.leaveContext();
+					typedefTable.addToEnclosingScope(*($2), TypedefTable::ID );
+					$$ = DeclarationNode::newContext( $2, $5, $10 );
+				}
+		;
+
+context_declaration_list:								// CFA
+		context_declaration
+		| context_declaration_list push context_declaration
+				{ $$ = $1->appendList( $3 ); }
+		;
+
+context_declaration:									// CFA
+		new_context_declaring_list pop ';'
+		| context_declaring_list pop ';'
+		;
+
+new_context_declaring_list:								// CFA
+		new_variable_specifier
+				{
+					typedefTable.addToEnclosingScope2( TypedefTable::ID );
+					$$ = $1;
+				}
+		| new_function_specifier
+				{
+					typedefTable.addToEnclosingScope2( TypedefTable::ID );
+					$$ = $1;
+				}
+		| new_context_declaring_list pop ',' push identifier_or_typedef_name
+				{
+					typedefTable.addToEnclosingScope2( *($5), TypedefTable::ID );
+					$$ = $1->appendList( $1->cloneType( $5 ) );
+				}
+		;
+
+context_declaring_list:									// CFA
+		type_specifier declarator
+				{
+					typedefTable.addToEnclosingScope2( TypedefTable::ID );
+					$$ = $2->addType( $1 );
+				}
+		| context_declaring_list pop ',' push declarator
+				{
+					typedefTable.addToEnclosingScope2( TypedefTable::ID );
+					$$ = $1->appendList( $1->cloneBaseType( $5 ) );
+				}
+		;
 
 //***************************** EXTERNAL DEFINITIONS *****************************
 
 translation_unit:
-	// empty
-		{}					// empty input file
-	| external_definition_list
-		{
-		  if ( theTree ) {
-		    theTree->appendList( $1 );
-		  } else {
-		    theTree = $1;
-		  }
-		}
-	;
+		// empty
+				{}										// empty input file
+		| external_definition_list
+				{
+					if ( theTree ) {
+						theTree->appendList( $1 );
+					} else {
+						theTree = $1;
+					}
+				}
+		;
 
 external_definition_list:
-	external_definition
-	| external_definition_list push external_definition
-		{
-		    if ( $1 ) {
-			$$ = $1->appendList( $3 );
-		    } else {
-			$$ = $3;
-		    }
-		}
-	;
+		external_definition
+		| external_definition_list push external_definition
+				{ $$ = ($1 != NULL ) ? $1->appendList( $3 ) : $3; }
+		;
 
 external_definition_list_opt:
-	// empty
-		{ $$ = 0; }
-	| external_definition_list
-	;
+		// empty
+				{ $$ = 0; }
+		| external_definition_list
+		;
 
 external_definition:
-	declaration
-	| function_definition
-	| asm_statement					// GCC, global assembler statement
-		{}
-	| EXTERN STRINGliteral
-		{
-		  linkageStack.push( linkage );
-		  linkage = LinkageSpec::fromString( *$2 );
-		}
-	  '{' external_definition_list_opt '}'		// C++-style linkage specifier
-		{
-		  linkage = linkageStack.top();
-		  linkageStack.pop();
-		  $$ = $5;
-		}
-	| EXTENSION external_definition
-		{ $$ = $2; }
-	;
+		declaration
+		| function_definition
+		| asm_statement									// GCC, global assembler statement
+				{}
+		| EXTERN STRINGliteral
+				{
+					linkageStack.push( linkage );
+					linkage = LinkageSpec::fromString( *$2 );
+				}
+		  '{' external_definition_list_opt '}'			// C++-style linkage specifier
+				{
+					linkage = linkageStack.top();
+					linkageStack.pop();
+					$$ = $5;
+				}
+		| EXTENSION external_definition
+				{ $$ = $2; }
+		;
 
 function_definition:
-	new_function_specifier compound_statement	// CFA
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $1->addFunctionBody( $2 );
-		}
-	| declaration_qualifier_list new_function_specifier compound_statement // CFA
-		// declaration_qualifier_list also includes type_qualifier_list, so a semantic check is
-		// necessary to preclude them as a type_qualifier cannot appear in this context.
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $2->addFunctionBody( $3 )->addQualifiers( $1 );
-		}
-
-	| declaration_specifier function_declarator compound_statement
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $2->addFunctionBody( $3 )->addType( $1 );
-		}
-
-		// These rules are a concession to the "implicit int" type_specifier because there is a
-		// significant amount of code with functions missing a type-specifier on the return type.
-		// Parsing is possible because function_definition does not appear in the context of an
-		// expression (nested functions would preclude this concession). A function prototype
-		// declaration must still have a type_specifier. OBSOLESCENT (see 1)
-	| function_declarator compound_statement
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $1->addFunctionBody( $2 );
-		}
-	| type_qualifier_list function_declarator compound_statement
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $2->addFunctionBody( $3 )->addQualifiers( $1 );
-		}
-	| declaration_qualifier_list function_declarator compound_statement
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $2->addFunctionBody( $3 )->addQualifiers( $1 );
-		}
-	| declaration_qualifier_list type_qualifier_list function_declarator compound_statement
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $3->addFunctionBody( $4 )->addQualifiers( $2 )->addQualifiers( $1 );
-		}
-
-		// Old-style K&R function definition, OBSOLESCENT (see 4)
-	| declaration_specifier old_function_declarator push old_declaration_list_opt compound_statement
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $2->addOldDeclList( $4 )->addFunctionBody( $5 )->addType( $1 );
-		}
-	| old_function_declarator push old_declaration_list_opt compound_statement
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $1->addOldDeclList( $3 )->addFunctionBody( $4 );
-		}
-	| type_qualifier_list old_function_declarator push old_declaration_list_opt compound_statement
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $2->addOldDeclList( $4 )->addFunctionBody( $5 )->addQualifiers( $1 );
-		}
-
-		// Old-style K&R function definition with "implicit int" type_specifier, OBSOLESCENT (see 4)
-	| declaration_qualifier_list old_function_declarator push old_declaration_list_opt compound_statement
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $2->addOldDeclList( $4 )->addFunctionBody( $5 )->addQualifiers( $1 );
-		}
-	| declaration_qualifier_list type_qualifier_list old_function_declarator push old_declaration_list_opt
-			compound_statement
-		{
-		    typedefTable.addToEnclosingScope( TypedefTable::ID );
-		    typedefTable.leaveScope();
-		    $$ = $3->addOldDeclList( $5 )->addFunctionBody( $6 )->addQualifiers( $2 )->addQualifiers( $1 );
-		}
-	;
+		new_function_specifier compound_statement		// CFA
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $1->addFunctionBody( $2 );
+				}
+		| declaration_qualifier_list new_function_specifier compound_statement // CFA
+				// declaration_qualifier_list also includes type_qualifier_list, so a semantic check is
+				// necessary to preclude them as a type_qualifier cannot appear in this context.
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $2->addFunctionBody( $3 )->addQualifiers( $1 );
+				}
+
+		| declaration_specifier function_declarator compound_statement
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $2->addFunctionBody( $3 )->addType( $1 );
+				}
+
+				// These rules are a concession to the "implicit int" type_specifier because there is a
+				// significant amount of code with functions missing a type-specifier on the return type.
+				// Parsing is possible because function_definition does not appear in the context of an
+				// expression (nested functions would preclude this concession). A function prototype
+				// declaration must still have a type_specifier. OBSOLESCENT (see 1)
+		| function_declarator compound_statement
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $1->addFunctionBody( $2 );
+				}
+		| type_qualifier_list function_declarator compound_statement
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $2->addFunctionBody( $3 )->addQualifiers( $1 );
+				}
+		| declaration_qualifier_list function_declarator compound_statement
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $2->addFunctionBody( $3 )->addQualifiers( $1 );
+				}
+		| declaration_qualifier_list type_qualifier_list function_declarator compound_statement
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $3->addFunctionBody( $4 )->addQualifiers( $2 )->addQualifiers( $1 );
+				}
+
+				// Old-style K&R function definition, OBSOLESCENT (see 4)
+		| declaration_specifier old_function_declarator push old_declaration_list_opt compound_statement
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $2->addOldDeclList( $4 )->addFunctionBody( $5 )->addType( $1 );
+				}
+		| old_function_declarator push old_declaration_list_opt compound_statement
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $1->addOldDeclList( $3 )->addFunctionBody( $4 );
+				}
+		| type_qualifier_list old_function_declarator push old_declaration_list_opt compound_statement
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $2->addOldDeclList( $4 )->addFunctionBody( $5 )->addQualifiers( $1 );
+				}
+
+				// Old-style K&R function definition with "implicit int" type_specifier, OBSOLESCENT (see 4)
+		| declaration_qualifier_list old_function_declarator push old_declaration_list_opt compound_statement
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $2->addOldDeclList( $4 )->addFunctionBody( $5 )->addQualifiers( $1 );
+				}
+		| declaration_qualifier_list type_qualifier_list old_function_declarator push old_declaration_list_opt compound_statement
+				{
+					typedefTable.addToEnclosingScope( TypedefTable::ID );
+					typedefTable.leaveScope();
+					$$ = $3->addOldDeclList( $5 )->addFunctionBody( $6 )->addQualifiers( $2 )->addQualifiers( $1 );
+				}
+		;
 
 declarator:
-	variable_declarator
-	| function_declarator
-	| typedef_redeclarator
-	;
+		variable_declarator
+		| function_declarator
+		| typedef_redeclarator
+		;
 
 subrange:
-	constant_expression '~' constant_expression	// CFA, integer subrange
-		{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Range), $1, $3); }
-	;
-
-asm_name_opt:						// GCC
-	// empty
-	| ASM '(' string_literal_list ')' attribute_list_opt
-	;
-
-attribute_list_opt:					// GCC
-	// empty
-	| attribute_list
-	;
-
-attribute_list:						// GCC
-	attribute
-	| attribute_list attribute
-	;
-
-attribute:						// GCC
-	ATTRIBUTE '(' '(' attribute_parameter_list ')' ')'
-	;
-
-attribute_parameter_list:				// GCC
-	attrib
-	| attribute_parameter_list ',' attrib
-	;
-
-attrib:							// GCC
-	// empty
-	| any_word
-	| any_word '(' comma_expression_opt ')'
-	;
-
-any_word:						// GCC
-	identifier_or_typedef_name {}
-	| storage_class_name {}
-	| basic_type_name {}
-	| type_qualifier {}
-	;
+		constant_expression '~' constant_expression		// CFA, integer subrange
+				{ $$ = new CompositeExprNode(new OperatorNode(OperatorNode::Range), $1, $3); }
+		;
+
+asm_name_opt:											// GCC
+		// empty
+		| ASM '(' string_literal_list ')' attribute_list_opt
+		;
+
+attribute_list_opt:										// GCC
+		// empty
+		| attribute_list
+		;
+
+attribute_list:											// GCC
+		attribute
+		| attribute_list attribute
+		;
+
+attribute:												// GCC
+		ATTRIBUTE '(' '(' attribute_parameter_list ')' ')'
+		;
+
+attribute_parameter_list:								// GCC
+		attrib
+		| attribute_parameter_list ',' attrib
+		;
+
+attrib:													// GCC
+		// empty
+		| any_word
+		| any_word '(' comma_expression_opt ')'
+		;
+
+any_word:												// GCC
+		identifier_or_typedef_name {}
+		| storage_class_name {}
+		| basic_type_name {}
+		| type_qualifier {}
+		;
 
 // ============================================================================
@@ -2048,6 +2044,6 @@
 // in an expression, as in:
 //
-//	int (*f())[10] { ... };
-//	... (*f())[3] += 1;	// definition mimics usage
+//		int (*f())[10] { ... };
+//		... (*f())[3] += 1;		// definition mimics usage
 //
 // Because these patterns are highly recursive, changes at a lower level in the recursion require copying some
@@ -2060,10 +2056,10 @@
 // declarators to define a variable or function prototype, e.g.:
 //
-//	valid declaration	invalid definition
-//	-----------------	------------------
-//	int f;			int f {}
-//	int *f;			int *f {}
-//	int f[10];		int f[10] {}
-//	int (*f)(int);		int (*f)(int) {}
+//		valid declaration		invalid definition
+//		-----------------		------------------
+//		int f;						int f {}
+//		int *f;						int *f {}
+//		int f[10];				int f[10] {}
+//		int (*f)(int);				int (*f)(int) {}
 //
 // To preclude this syntactic anomaly requires separating the grammar rules for variable and function
@@ -2075,46 +2071,46 @@
 
 variable_declarator:
-	paren_identifier attribute_list_opt
-	| variable_ptr
-	| variable_array attribute_list_opt
-	| variable_function attribute_list_opt
-	;
+		paren_identifier attribute_list_opt
+		| variable_ptr
+		| variable_array attribute_list_opt
+		| variable_function attribute_list_opt
+		;
 
 paren_identifier:
-	identifier
-		{
-		    typedefTable.setNextIdentifier( *($1) );
-		    $$ = DeclarationNode::newName( $1 );
-		}
-	| '(' paren_identifier ')'			// redundant parenthesis
-		{ $$ = $2; }
-	;
+		identifier
+				{
+					typedefTable.setNextIdentifier( *($1) );
+					$$ = DeclarationNode::newName( $1 );
+				}
+		| '(' paren_identifier ')'						// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 variable_ptr:
-	'*' variable_declarator
-		{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
-	| '*' type_qualifier_list variable_declarator
-		{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
-	| '(' variable_ptr ')'
-		{ $$ = $2; }
-	;
+		'*' variable_declarator
+				{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
+		| '*' type_qualifier_list variable_declarator
+				{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
+		| '(' variable_ptr ')'
+				{ $$ = $2; }
+		;
 
 variable_array:
-	paren_identifier array_dimension
-		{ $$ = $1->addArray( $2 ); }
-	| '(' variable_ptr ')' array_dimension
-		{ $$ = $2->addArray( $4 ); }
-	| '(' variable_array ')' multi_array_dimension	// redundant parenthesis
-		{ $$ = $2->addArray( $4 ); }
-	| '(' variable_array ')'			// redundant parenthesis
-		{ $$ = $2; }
-	;
+		paren_identifier array_dimension
+				{ $$ = $1->addArray( $2 ); }
+		| '(' variable_ptr ')' array_dimension
+				{ $$ = $2->addArray( $4 ); }
+		| '(' variable_array ')' multi_array_dimension	// redundant parenthesis
+				{ $$ = $2->addArray( $4 ); }
+		| '(' variable_array ')'						// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 variable_function:
-	'(' variable_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $2->addParamList( $6 ); }
-	| '(' variable_function ')'			// redundant parenthesis
-		{ $$ = $2; }
-	;
+		'(' variable_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $2->addParamList( $6 ); }
+		| '(' variable_function ')'						// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 // This pattern parses a function declarator that is not redefining a typedef name. Because functions cannot
@@ -2124,35 +2120,35 @@
 
 function_declarator:
-	function_no_ptr attribute_list_opt
-	| function_ptr
-	| function_array attribute_list_opt
-	;
+		function_no_ptr attribute_list_opt
+		| function_ptr
+		| function_array attribute_list_opt
+		;
 
 function_no_ptr:
-	paren_identifier '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $1->addParamList( $4 ); }
-	| '(' function_ptr ')' '(' push parameter_type_list_opt pop ')'
-		{ $$ = $2->addParamList( $6 ); }
-	| '(' function_no_ptr ')'			// redundant parenthesis
-		{ $$ = $2; }
-	;
+		paren_identifier '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $1->addParamList( $4 ); }
+		| '(' function_ptr ')' '(' push parameter_type_list_opt pop ')'
+				{ $$ = $2->addParamList( $6 ); }
+		| '(' function_no_ptr ')'						// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 function_ptr:
-	'*' function_declarator
-		{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
-	| '*' type_qualifier_list function_declarator
-		{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
-	| '(' function_ptr ')'
-		{ $$ = $2; }
-	;
+		'*' function_declarator
+				{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
+		| '*' type_qualifier_list function_declarator
+				{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
+		| '(' function_ptr ')'
+				{ $$ = $2; }
+		;
 
 function_array:
-	'(' function_ptr ')' array_dimension
-		{ $$ = $2->addArray( $4 ); }
-	| '(' function_array ')' multi_array_dimension	// redundant parenthesis
-		{ $$ = $2->addArray( $4 ); }
-	| '(' function_array ')'			// redundant parenthesis
-		{ $$ = $2; }
-	;
+		'(' function_ptr ')' array_dimension
+				{ $$ = $2->addArray( $4 ); }
+		| '(' function_array ')' multi_array_dimension	// redundant parenthesis
+				{ $$ = $2->addArray( $4 ); }
+		| '(' function_array ')'						// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 // This pattern parses an old-style K&R function declarator (OBSOLESCENT, see 4) that is not redefining a
@@ -2161,42 +2157,42 @@
 
 old_function_declarator:
-	old_function_no_ptr
-	| old_function_ptr
-	| old_function_array
-	;
+		old_function_no_ptr
+		| old_function_ptr
+		| old_function_array
+		;
 
 old_function_no_ptr:
-	paren_identifier '(' identifier_list ')'	// function_declarator handles empty parameter
-		{ $$ = $1->addIdList( $3 ); }
-	| '(' old_function_ptr ')' '(' identifier_list ')'
-		{ $$ = $2->addIdList( $5 ); }
-	| '(' old_function_no_ptr ')'			// redundant parenthesis
-		{ $$ = $2; }
-	;
+		paren_identifier '(' identifier_list ')'		// function_declarator handles empty parameter
+				{ $$ = $1->addIdList( $3 ); }
+		| '(' old_function_ptr ')' '(' identifier_list ')'
+				{ $$ = $2->addIdList( $5 ); }
+		| '(' old_function_no_ptr ')'					// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 old_function_ptr:
-	'*' old_function_declarator
-		{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
-	| '*' type_qualifier_list old_function_declarator
-		{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
-	| '(' old_function_ptr ')'
-		{ $$ = $2; }
-	;
+		'*' old_function_declarator
+				{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
+		| '*' type_qualifier_list old_function_declarator
+				{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
+		| '(' old_function_ptr ')'
+				{ $$ = $2; }
+		;
 
 old_function_array:
-	'(' old_function_ptr ')' array_dimension
-		{ $$ = $2->addArray( $4 ); }
-	| '(' old_function_array ')' multi_array_dimension // redundant parenthesis
-		{ $$ = $2->addArray( $4 ); }
-	| '(' old_function_array ')'			// redundant parenthesis
-		{ $$ = $2; }
-	;
+		'(' old_function_ptr ')' array_dimension
+				{ $$ = $2->addArray( $4 ); }
+		| '(' old_function_array ')' multi_array_dimension // redundant parenthesis
+				{ $$ = $2->addArray( $4 ); }
+		| '(' old_function_array ')'					// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 // This pattern parses a declaration for a variable or function prototype that redefines a typedef name, e.g.:
 //
-//	typedef int foo;
-//	{
-//	   int foo; // redefine typedef name in new scope
-//	}
+//		typedef int foo;
+//		{
+//		   int foo; // redefine typedef name in new scope
+//		}
 //
 // The pattern precludes declaring an array of functions versus a pointer to an array of functions, and
@@ -2204,48 +2200,48 @@
 
 typedef_redeclarator:
-	paren_typedef attribute_list_opt
-	| typedef_ptr
-	| typedef_array attribute_list_opt
-	| typedef_function attribute_list_opt
-	;
+		paren_typedef attribute_list_opt
+		| typedef_ptr
+		| typedef_array attribute_list_opt
+		| typedef_function attribute_list_opt
+		;
 
 paren_typedef:
-	TYPEDEFname
-		{
-		typedefTable.setNextIdentifier( *($1) );
-		$$ = DeclarationNode::newName( $1 );
-		}
-	| '(' paren_typedef ')'
-		{ $$ = $2; }
-	;
+		TYPEDEFname
+				{
+				typedefTable.setNextIdentifier( *($1) );
+				$$ = DeclarationNode::newName( $1 );
+				}
+		| '(' paren_typedef ')'
+				{ $$ = $2; }
+		;
 
 typedef_ptr:
-	'*' typedef_redeclarator
-		{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
-	| '*' type_qualifier_list typedef_redeclarator
-		{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
-	| '(' typedef_ptr ')'
-		{ $$ = $2; }
-	;
+		'*' typedef_redeclarator
+				{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
+		| '*' type_qualifier_list typedef_redeclarator
+				{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
+		| '(' typedef_ptr ')'
+				{ $$ = $2; }
+		;
 
 typedef_array:
-	paren_typedef array_dimension
-		{ $$ = $1->addArray( $2 ); }
-	| '(' typedef_ptr ')' array_dimension
-		{ $$ = $2->addArray( $4 ); }
-	| '(' typedef_array ')' multi_array_dimension	// redundant parenthesis
-		{ $$ = $2->addArray( $4 ); }
-	| '(' typedef_array ')'				// redundant parenthesis
-		{ $$ = $2; }
-	;
+		paren_typedef array_dimension
+				{ $$ = $1->addArray( $2 ); }
+		| '(' typedef_ptr ')' array_dimension
+				{ $$ = $2->addArray( $4 ); }
+		| '(' typedef_array ')' multi_array_dimension	// redundant parenthesis
+				{ $$ = $2->addArray( $4 ); }
+		| '(' typedef_array ')'							// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 typedef_function:
-	paren_typedef '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $1->addParamList( $4 ); }
-	| '(' typedef_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $2->addParamList( $6 ); }
-	| '(' typedef_function ')'			// redundant parenthesis
-		{ $$ = $2; }
-	;
+		paren_typedef '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $1->addParamList( $4 ); }
+		| '(' typedef_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $2->addParamList( $6 ); }
+		| '(' typedef_function ')'						// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 // This pattern parses a declaration for a parameter variable or function prototype that is not redefining a
@@ -2255,464 +2251,467 @@
 
 identifier_parameter_declarator:
-	paren_identifier attribute_list_opt
-	| identifier_parameter_ptr
-	| identifier_parameter_array attribute_list_opt
-	| identifier_parameter_function attribute_list_opt
-	;
+		paren_identifier attribute_list_opt
+		| identifier_parameter_ptr
+		| identifier_parameter_array attribute_list_opt
+		| identifier_parameter_function attribute_list_opt
+		;
 
 identifier_parameter_ptr:
-	'*' identifier_parameter_declarator
-		{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
-	| '*' type_qualifier_list identifier_parameter_declarator
-		{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
-	| '(' identifier_parameter_ptr ')'
-		{ $$ = $2; }
-	;
+		'*' identifier_parameter_declarator
+				{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
+		| '*' type_qualifier_list identifier_parameter_declarator
+				{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
+		| '(' identifier_parameter_ptr ')'
+				{ $$ = $2; }
+		;
 
 identifier_parameter_array:
-	paren_identifier array_parameter_dimension
-		{ $$ = $1->addArray( $2 ); }
-	| '(' identifier_parameter_ptr ')' array_dimension
-		{ $$ = $2->addArray( $4 ); }
-	| '(' identifier_parameter_array ')' multi_array_dimension // redundant parenthesis
-		{ $$ = $2->addArray( $4 ); }
-	| '(' identifier_parameter_array ')'		// redundant parenthesis
-		{ $$ = $2; }
-	;
+		paren_identifier array_parameter_dimension
+				{ $$ = $1->addArray( $2 ); }
+		| '(' identifier_parameter_ptr ')' array_dimension
+				{ $$ = $2->addArray( $4 ); }
+		| '(' identifier_parameter_array ')' multi_array_dimension // redundant parenthesis
+				{ $$ = $2->addArray( $4 ); }
+		| '(' identifier_parameter_array ')'			// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 identifier_parameter_function:
-	paren_identifier '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $1->addParamList( $4 ); }
-	| '(' identifier_parameter_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $2->addParamList( $6 ); }
-	| '(' identifier_parameter_function ')'		// redundant parenthesis
-		{ $$ = $2; }
-	;
-
-// This pattern parses a declaration for a parameter variable or function prototype that is redefining a typedef name,
-// e.g.:
-//
-//	typedef int foo;
-//	int f( int foo ); // redefine typedef name in new scope
-//
-// and allows the C99 array options, which can only appear in a parameter list.  In addition, the pattern handles the
-// special meaning of parenthesis around a typedef name:
-//
-//	ISO/IEC 9899:1999 Section 6.7.5.3(11) : "In a parameter declaration, a single typedef name in
-//	parentheses is taken to be an abstract declarator that specifies a function with a single parameter,
-//	not as redundant parentheses around the identifier."
+		paren_identifier '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $1->addParamList( $4 ); }
+		| '(' identifier_parameter_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $2->addParamList( $6 ); }
+		| '(' identifier_parameter_function ')'			// redundant parenthesis
+				{ $$ = $2; }
+		;
+
+// This pattern parses a declaration for a parameter variable or function prototype that is redefining a
+// typedef name, e.g.:
+//
+//		typedef int foo;
+//		int f( int foo ); // redefine typedef name in new scope
+//
+// and allows the C99 array options, which can only appear in a parameter list.  In addition, the pattern
+// handles the special meaning of parenthesis around a typedef name:
+//
+//		ISO/IEC 9899:1999 Section 6.7.5.3(11) : "In a parameter declaration, a single typedef name in
+//		parentheses is taken to be an abstract declarator that specifies a function with a single parameter,
+//		not as redundant parentheses around the identifier."
 //
 // which precludes the following cases:
 //
-//	typedef float T;
-//	int f( int ( T [5] ) );			// see abstract_parameter_declarator
-//	int g( int ( T ( int ) ) );		// see abstract_parameter_declarator
-//	int f( int f1( T a[5] ) );		// see identifier_parameter_declarator
-//	int g( int g1( T g2( int p ) ) );	// see identifier_parameter_declarator
-//
-// In essence, a '(' immediately to the left of typedef name, T, is interpreted as starting a parameter type list, and
-// not as redundant parentheses around a redeclaration of T. Finally, the pattern also precludes declaring an array of
-// functions versus a pointer to an array of functions, and returning arrays and functions versus pointers to arrays and
-// functions.
+//		typedef float T;
+//		int f( int ( T [5] ) );						// see abstract_parameter_declarator
+//		int g( int ( T ( int ) ) );				// see abstract_parameter_declarator
+//		int f( int f1( T a[5] ) );				// see identifier_parameter_declarator
+//		int g( int g1( T g2( int p ) ) );		// see identifier_parameter_declarator
+//
+// In essence, a '(' immediately to the left of typedef name, T, is interpreted as starting a parameter type
+// list, and not as redundant parentheses around a redeclaration of T. Finally, the pattern also precludes
+// declaring an array of functions versus a pointer to an array of functions, and returning arrays and
+// functions versus pointers to arrays and functions.
 
 typedef_parameter_redeclarator:
-	typedef attribute_list_opt
-	| typedef_parameter_ptr
-	| typedef_parameter_array attribute_list_opt
-	| typedef_parameter_function attribute_list_opt
-	;
+		typedef attribute_list_opt
+		| typedef_parameter_ptr
+		| typedef_parameter_array attribute_list_opt
+		| typedef_parameter_function attribute_list_opt
+		;
 
 typedef:
-	TYPEDEFname
-		{
-		    typedefTable.setNextIdentifier( *($1) );
-		    $$ = DeclarationNode::newName( $1 );
-		}
-	;
+		TYPEDEFname
+				{
+					typedefTable.setNextIdentifier( *($1) );
+					$$ = DeclarationNode::newName( $1 );
+				}
+		;
 
 typedef_parameter_ptr:
-	'*' typedef_parameter_redeclarator
-		{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
-	| '*' type_qualifier_list typedef_parameter_redeclarator
-		{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
-	| '(' typedef_parameter_ptr ')'
-		{ $$ = $2; }
-	;
+		'*' typedef_parameter_redeclarator
+				{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
+		| '*' type_qualifier_list typedef_parameter_redeclarator
+				{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
+		| '(' typedef_parameter_ptr ')'
+				{ $$ = $2; }
+		;
 
 typedef_parameter_array:
-	typedef array_parameter_dimension
-		{ $$ = $1->addArray( $2 ); }
-	| '(' typedef_parameter_ptr ')' array_parameter_dimension
-		{ $$ = $2->addArray( $4 ); }
-	;
+		typedef array_parameter_dimension
+				{ $$ = $1->addArray( $2 ); }
+		| '(' typedef_parameter_ptr ')' array_parameter_dimension
+				{ $$ = $2->addArray( $4 ); }
+		;
 
 typedef_parameter_function:
-	typedef '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $1->addParamList( $4 ); }
-	| '(' typedef_parameter_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $2->addParamList( $6 ); }
-	;
-
-// This pattern parses a declaration of an abstract variable or function prototype, i.e., there is no identifier to
-// which the type applies, e.g.:
-//
-//	sizeof( int );
-//	sizeof( int [10] );
-//
-// The pattern precludes declaring an array of functions versus a pointer to an array of functions, and returning arrays
-// and functions versus pointers to arrays and functions.
+		typedef '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $1->addParamList( $4 ); }
+		| '(' typedef_parameter_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $2->addParamList( $6 ); }
+		;
+
+// This pattern parses a declaration of an abstract variable or function prototype, i.e., there is no
+// identifier to which the type applies, e.g.:
+//
+//		sizeof( int );
+//		sizeof( int [10] );
+//
+// The pattern precludes declaring an array of functions versus a pointer to an array of functions, and
+// returning arrays and functions versus pointers to arrays and functions.
 
 abstract_declarator:
-	abstract_ptr
-	| abstract_array attribute_list_opt
-	| abstract_function attribute_list_opt
-	;
+		abstract_ptr
+		| abstract_array attribute_list_opt
+		| abstract_function attribute_list_opt
+		;
 
 abstract_ptr:
-	'*'
-		{ $$ = DeclarationNode::newPointer( 0 ); }
-	| '*' type_qualifier_list
-		{ $$ = DeclarationNode::newPointer( $2 ); }
-	| '*' abstract_declarator
-		{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
-	| '*' type_qualifier_list abstract_declarator
-		{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
-	| '(' abstract_ptr ')'
-		{ $$ = $2; }
-	;
+		'*'
+				{ $$ = DeclarationNode::newPointer( 0 ); }
+		| '*' type_qualifier_list
+				{ $$ = DeclarationNode::newPointer( $2 ); }
+		| '*' abstract_declarator
+				{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
+		| '*' type_qualifier_list abstract_declarator
+				{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
+		| '(' abstract_ptr ')'
+				{ $$ = $2; }
+		;
 
 abstract_array:
-	array_dimension
-	| '(' abstract_ptr ')' array_dimension
-		{ $$ = $2->addArray( $4 ); }
-	| '(' abstract_array ')' multi_array_dimension	// redundant parenthesis
-		{ $$ = $2->addArray( $4 ); }
-	| '(' abstract_array ')'			// redundant parenthesis
-		{ $$ = $2; }
-	;
+		array_dimension
+		| '(' abstract_ptr ')' array_dimension
+				{ $$ = $2->addArray( $4 ); }
+		| '(' abstract_array ')' multi_array_dimension	// redundant parenthesis
+				{ $$ = $2->addArray( $4 ); }
+		| '(' abstract_array ')'						// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 abstract_function:
-	'(' push parameter_type_list_opt pop ')'	// empty parameter list OBSOLESCENT (see 3)
-		{ $$ = DeclarationNode::newFunction( 0, 0, $3, 0 ); }
-	| '(' abstract_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $2->addParamList( $6 ); }
-	| '(' abstract_function ')'			// redundant parenthesis
-		{ $$ = $2; }
-	;
+		'(' push parameter_type_list_opt pop ')'		// empty parameter list OBSOLESCENT (see 3)
+				{ $$ = DeclarationNode::newFunction( 0, 0, $3, 0 ); }
+		| '(' abstract_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $2->addParamList( $6 ); }
+		| '(' abstract_function ')'						// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 array_dimension:
-		// Only the first dimension can be empty.
-	'[' push pop ']'
-		{ $$ = DeclarationNode::newArray( 0, 0, false ); }
-	| '[' push pop ']' multi_array_dimension
-		{ $$ = DeclarationNode::newArray( 0, 0, false )->addArray( $5 ); }
-	| multi_array_dimension
-	;
+				// Only the first dimension can be empty.
+		'[' push pop ']'
+				{ $$ = DeclarationNode::newArray( 0, 0, false ); }
+		| '[' push pop ']' multi_array_dimension
+				{ $$ = DeclarationNode::newArray( 0, 0, false )->addArray( $5 ); }
+		| multi_array_dimension
+		;
 
 multi_array_dimension:
-	'[' push assignment_expression pop ']'
-		{ $$ = DeclarationNode::newArray( $3, 0, false ); }
-	| '[' push '*' pop ']'				// C99
-		{ $$ = DeclarationNode::newVarArray( 0 ); }
-	| multi_array_dimension '[' push assignment_expression pop ']'
-		{ $$ = $1->addArray( DeclarationNode::newArray( $4, 0, false ) ); }
-	| multi_array_dimension '[' push '*' pop ']'	// C99
-		{ $$ = $1->addArray( DeclarationNode::newVarArray( 0 ) ); }
-	;
+		'[' push assignment_expression pop ']'
+				{ $$ = DeclarationNode::newArray( $3, 0, false ); }
+		| '[' push '*' pop ']'								// C99
+				{ $$ = DeclarationNode::newVarArray( 0 ); }
+		| multi_array_dimension '[' push assignment_expression pop ']'
+				{ $$ = $1->addArray( DeclarationNode::newArray( $4, 0, false ) ); }
+		| multi_array_dimension '[' push '*' pop ']'		// C99
+				{ $$ = $1->addArray( DeclarationNode::newVarArray( 0 ) ); }
+		;
 
 // This pattern parses a declaration of a parameter abstract variable or function prototype, i.e., there is no
 // identifier to which the type applies, e.g.:
 //
-//	int f( int );		// abstract variable parameter; no parameter name specified
-//	int f( int (int) );	// abstract function-prototype parameter; no parameter name specified
-//
-// The pattern precludes declaring an array of functions versus a pointer to an array of functions, and returning arrays
-// and functions versus pointers to arrays and functions. */
+//		int f( int );			// abstract variable parameter; no parameter name specified
+//		int f( int (int) );		// abstract function-prototype parameter; no parameter name specified
+//
+// The pattern precludes declaring an array of functions versus a pointer to an array of functions, and
+// returning arrays and functions versus pointers to arrays and functions.
 
 abstract_parameter_declarator:
-	abstract_parameter_ptr
-	| abstract_parameter_array attribute_list_opt
-	| abstract_parameter_function attribute_list_opt
-	;
+		abstract_parameter_ptr
+		| abstract_parameter_array attribute_list_opt
+		| abstract_parameter_function attribute_list_opt
+		;
 
 abstract_parameter_ptr:
-	'*'
-		{ $$ = DeclarationNode::newPointer( 0 ); }
-	| '*' type_qualifier_list
-		{ $$ = DeclarationNode::newPointer( $2 ); }
-	| '*' abstract_parameter_declarator
-		{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
-	| '*' type_qualifier_list abstract_parameter_declarator
-		{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
-	| '(' abstract_parameter_ptr ')'
-		{ $$ = $2; }
-	;
+		'*'
+				{ $$ = DeclarationNode::newPointer( 0 ); }
+		| '*' type_qualifier_list
+				{ $$ = DeclarationNode::newPointer( $2 ); }
+		| '*' abstract_parameter_declarator
+				{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
+		| '*' type_qualifier_list abstract_parameter_declarator
+				{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
+		| '(' abstract_parameter_ptr ')'
+				{ $$ = $2; }
+		;
 
 abstract_parameter_array:
-	array_parameter_dimension
-	| '(' abstract_parameter_ptr ')' array_parameter_dimension
-		{ $$ = $2->addArray( $4 ); }
-	| '(' abstract_parameter_array ')' multi_array_dimension // redundant parenthesis
-		{ $$ = $2->addArray( $4 ); }
-	| '(' abstract_parameter_array ')'		// redundant parenthesis
-		{ $$ = $2; }
-	;
+		array_parameter_dimension
+		| '(' abstract_parameter_ptr ')' array_parameter_dimension
+				{ $$ = $2->addArray( $4 ); }
+		| '(' abstract_parameter_array ')' multi_array_dimension // redundant parenthesis
+				{ $$ = $2->addArray( $4 ); }
+		| '(' abstract_parameter_array ')'				// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 abstract_parameter_function:
-	'(' push parameter_type_list_opt pop ')'	// empty parameter list OBSOLESCENT (see 3)
-		{ $$ = DeclarationNode::newFunction( 0, 0, $3, 0 ); }
-	| '(' abstract_parameter_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $2->addParamList( $6 ); }
-	| '(' abstract_parameter_function ')'		// redundant parenthesis
-		{ $$ = $2; }
-	;
+		'(' push parameter_type_list_opt pop ')'		// empty parameter list OBSOLESCENT (see 3)
+				{ $$ = DeclarationNode::newFunction( 0, 0, $3, 0 ); }
+		| '(' abstract_parameter_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $2->addParamList( $6 ); }
+		| '(' abstract_parameter_function ')'			// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 array_parameter_dimension:
-		// Only the first dimension can be empty or have qualifiers.
-	array_parameter_1st_dimension
-	| array_parameter_1st_dimension multi_array_dimension
-		{ $$ = $1->addArray( $2 ); }
-	| multi_array_dimension
-	;
+				// Only the first dimension can be empty or have qualifiers.
+		array_parameter_1st_dimension
+		| array_parameter_1st_dimension multi_array_dimension
+				{ $$ = $1->addArray( $2 ); }
+		| multi_array_dimension
+		;
 
 // The declaration of an array parameter has additional syntax over arrays in normal variable declarations:
 //
-//	ISO/IEC 9899:1999 Section 6.7.5.2(1) : "The optional type qualifiers and the keyword static shall appear only in
-//	a declaration of a function parameter with an array type, and then only in the outermost array type derivation."
+//		ISO/IEC 9899:1999 Section 6.7.5.2(1) : "The optional type qualifiers and the keyword static shall
+//		appear only in a declaration of a function parameter with an array type, and then only in the
+//		outermost array type derivation."
 
 array_parameter_1st_dimension:
-	'[' push pop ']'
-		{ $$ = DeclarationNode::newArray( 0, 0, false ); }
-	// multi_array_dimension handles the '[' '*' ']' case
-	| '[' push type_qualifier_list '*' pop ']'	// remaining C99
-		{ $$ = DeclarationNode::newVarArray( $3 ); }
-	| '[' push type_qualifier_list pop ']'
-		{ $$ = DeclarationNode::newArray( 0, $3, false ); }
-	// multi_array_dimension handles the '[' assignment_expression ']' case
-	| '[' push type_qualifier_list assignment_expression pop ']'
-		{ $$ = DeclarationNode::newArray( $4, $3, false ); }
-	| '[' push STATIC type_qualifier_list_opt assignment_expression pop ']'
-		{ $$ = DeclarationNode::newArray( $5, $4, true ); }
-	| '[' push type_qualifier_list STATIC assignment_expression pop ']'
-		{ $$ = DeclarationNode::newArray( $5, $3, true ); }
-	;
-
-// This pattern parses a declaration of an abstract variable, i.e., there is no identifier to which the type applies,
-// e.g.:
-//
-//	sizeof( int ); // abstract variable; no identifier name specified
-//
-// The pattern precludes declaring an array of functions versus a pointer to an array of functions, and returning arrays
-// and functions versus pointers to arrays and functions. */
+		'[' push pop ']'
+				{ $$ = DeclarationNode::newArray( 0, 0, false ); }
+		// multi_array_dimension handles the '[' '*' ']' case
+		| '[' push type_qualifier_list '*' pop ']'		// remaining C99
+				{ $$ = DeclarationNode::newVarArray( $3 ); }
+		| '[' push type_qualifier_list pop ']'
+				{ $$ = DeclarationNode::newArray( 0, $3, false ); }
+		// multi_array_dimension handles the '[' assignment_expression ']' case
+		| '[' push type_qualifier_list assignment_expression pop ']'
+				{ $$ = DeclarationNode::newArray( $4, $3, false ); }
+		| '[' push STATIC type_qualifier_list_opt assignment_expression pop ']'
+				{ $$ = DeclarationNode::newArray( $5, $4, true ); }
+		| '[' push type_qualifier_list STATIC assignment_expression pop ']'
+				{ $$ = DeclarationNode::newArray( $5, $3, true ); }
+		;
+
+// This pattern parses a declaration of an abstract variable, i.e., there is no identifier to which the type
+// applies, e.g.:
+//
+//		sizeof( int ); // abstract variable; no identifier name specified
+//
+// The pattern precludes declaring an array of functions versus a pointer to an array of functions, and
+// returning arrays and functions versus pointers to arrays and functions.
 
 variable_abstract_declarator:
-	variable_abstract_ptr
-	| variable_abstract_array attribute_list_opt
-	| variable_abstract_function attribute_list_opt
-	;
+		variable_abstract_ptr
+		| variable_abstract_array attribute_list_opt
+		| variable_abstract_function attribute_list_opt
+		;
 
 variable_abstract_ptr:
-	'*'
-		{ $$ = DeclarationNode::newPointer( 0 ); }
-	| '*' type_qualifier_list
-		{ $$ = DeclarationNode::newPointer( $2 ); }
-	| '*' variable_abstract_declarator
-		{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
-	| '*' type_qualifier_list variable_abstract_declarator
-		{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
-	| '(' variable_abstract_ptr ')'
-		{ $$ = $2; }
-	;
+		'*'
+				{ $$ = DeclarationNode::newPointer( 0 ); }
+		| '*' type_qualifier_list
+				{ $$ = DeclarationNode::newPointer( $2 ); }
+		| '*' variable_abstract_declarator
+				{ $$ = $2->addPointer( DeclarationNode::newPointer( 0 ) ); }
+		| '*' type_qualifier_list variable_abstract_declarator
+				{ $$ = $3->addPointer( DeclarationNode::newPointer( $2 ) ); }
+		| '(' variable_abstract_ptr ')'
+				{ $$ = $2; }
+		;
 
 variable_abstract_array:
-	array_dimension
-	| '(' variable_abstract_ptr ')' array_dimension
-		{ $$ = $2->addArray( $4 ); }
-	| '(' variable_abstract_array ')' multi_array_dimension // redundant parenthesis
-		{ $$ = $2->addArray( $4 ); }
-	| '(' variable_abstract_array ')'		// redundant parenthesis
-		{ $$ = $2; }
-	;
+		array_dimension
+		| '(' variable_abstract_ptr ')' array_dimension
+				{ $$ = $2->addArray( $4 ); }
+		| '(' variable_abstract_array ')' multi_array_dimension // redundant parenthesis
+				{ $$ = $2->addArray( $4 ); }
+		| '(' variable_abstract_array ')'				// redundant parenthesis
+				{ $$ = $2; }
+		;
 
 variable_abstract_function:
-	'(' variable_abstract_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
-		{ $$ = $2->addParamList( $6 ); }
-	| '(' variable_abstract_function ')'		// redundant parenthesis
-		{ $$ = $2; }
-	;
-
-// This pattern parses a new-style declaration for a parameter variable or function prototype that is either an
-// identifier or typedef name and allows the C99 array options, which can only appear in a parameter list.
-
-new_identifier_parameter_declarator_tuple:		// CFA
-	new_identifier_parameter_declarator_no_tuple
-	| new_abstract_tuple
-	| type_qualifier_list new_abstract_tuple
-		{ $$ = $2->addQualifiers( $1 ); }
-	;
-
-new_identifier_parameter_declarator_no_tuple:		// CFA
-	new_identifier_parameter_ptr
-	| new_identifier_parameter_array
-	;
-
-new_identifier_parameter_ptr:				// CFA
-	'*' type_specifier
-		{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
-	| type_qualifier_list '*' type_specifier
-		{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
-	| '*' new_abstract_function
-		{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
-	| type_qualifier_list '*' new_abstract_function
-		{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
-	| '*' new_identifier_parameter_declarator_tuple
-		{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
-	| type_qualifier_list '*' new_identifier_parameter_declarator_tuple
-		{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
-	;
-
-new_identifier_parameter_array:				// CFA
-		// Only the first dimension can be empty or have qualifiers. Empty dimension must be factored out due to
-		// shift/reduce conflict with new-style empty (void) function return type. */
-	'[' push pop ']' type_specifier
-		{ $$ = $5->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
-	| new_array_parameter_1st_dimension type_specifier
-		{ $$ = $2->addNewArray( $1 ); }
-	| '[' push pop ']' multi_array_dimension type_specifier
-		{ $$ = $6->addNewArray( $5 )->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
-	| new_array_parameter_1st_dimension multi_array_dimension type_specifier
-		{ $$ = $3->addNewArray( $2 )->addNewArray( $1 ); }
-	| multi_array_dimension type_specifier
-		{ $$ = $2->addNewArray( $1 ); }
-	| '[' push pop ']' new_identifier_parameter_ptr
-		{ $$ = $5->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
-	| new_array_parameter_1st_dimension new_identifier_parameter_ptr
-		{ $$ = $2->addNewArray( $1 ); }
-	| '[' push pop ']' multi_array_dimension new_identifier_parameter_ptr
-		{ $$ = $6->addNewArray( $5 )->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
-	| new_array_parameter_1st_dimension multi_array_dimension new_identifier_parameter_ptr
-		{ $$ = $3->addNewArray( $2 )->addNewArray( $1 ); }
-	| multi_array_dimension new_identifier_parameter_ptr
-		{ $$ = $2->addNewArray( $1 ); }
-	;
+		'(' variable_abstract_ptr ')' '(' push parameter_type_list_opt pop ')' // empty parameter list OBSOLESCENT (see 3)
+				{ $$ = $2->addParamList( $6 ); }
+		| '(' variable_abstract_function ')'			// redundant parenthesis
+				{ $$ = $2; }
+		;
+
+// This pattern parses a new-style declaration for a parameter variable or function prototype that is either
+// an identifier or typedef name and allows the C99 array options, which can only appear in a parameter list.
+
+new_identifier_parameter_declarator_tuple:				// CFA
+		new_identifier_parameter_declarator_no_tuple
+		| new_abstract_tuple
+		| type_qualifier_list new_abstract_tuple
+				{ $$ = $2->addQualifiers( $1 ); }
+		;
+
+new_identifier_parameter_declarator_no_tuple:			// CFA
+		new_identifier_parameter_ptr
+		| new_identifier_parameter_array
+		;
+
+new_identifier_parameter_ptr:							// CFA
+		'*' type_specifier
+				{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
+		| type_qualifier_list '*' type_specifier
+				{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
+		| '*' new_abstract_function
+				{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
+		| type_qualifier_list '*' new_abstract_function
+				{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
+		| '*' new_identifier_parameter_declarator_tuple
+				{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
+		| type_qualifier_list '*' new_identifier_parameter_declarator_tuple
+				{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
+		;
+
+new_identifier_parameter_array:							// CFA
+				// Only the first dimension can be empty or have qualifiers. Empty dimension must be factored
+				// out due to shift/reduce conflict with new-style empty (void) function return type.
+		'[' push pop ']' type_specifier
+				{ $$ = $5->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
+		| new_array_parameter_1st_dimension type_specifier
+				{ $$ = $2->addNewArray( $1 ); }
+		| '[' push pop ']' multi_array_dimension type_specifier
+				{ $$ = $6->addNewArray( $5 )->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
+		| new_array_parameter_1st_dimension multi_array_dimension type_specifier
+				{ $$ = $3->addNewArray( $2 )->addNewArray( $1 ); }
+		| multi_array_dimension type_specifier
+				{ $$ = $2->addNewArray( $1 ); }
+		| '[' push pop ']' new_identifier_parameter_ptr
+				{ $$ = $5->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
+		| new_array_parameter_1st_dimension new_identifier_parameter_ptr
+				{ $$ = $2->addNewArray( $1 ); }
+		| '[' push pop ']' multi_array_dimension new_identifier_parameter_ptr
+				{ $$ = $6->addNewArray( $5 )->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
+		| new_array_parameter_1st_dimension multi_array_dimension new_identifier_parameter_ptr
+				{ $$ = $3->addNewArray( $2 )->addNewArray( $1 ); }
+		| multi_array_dimension new_identifier_parameter_ptr
+				{ $$ = $2->addNewArray( $1 ); }
+		;
 
 new_array_parameter_1st_dimension:
-	'[' push type_qualifier_list '*' pop ']'	// remaining C99
-		{ $$ = DeclarationNode::newVarArray( $3 ); }
-	| '[' push type_qualifier_list assignment_expression pop ']'
-		{ $$ = DeclarationNode::newArray( $4, $3, false ); }
-	| '[' push declaration_qualifier_list assignment_expression pop ']'
-		// declaration_qualifier_list must be used because of shift/reduce conflict with assignment_expression,
-		// so a semantic check is necessary to preclude them as a type_qualifier cannot appear in this
-		// context.
-		{ $$ = DeclarationNode::newArray( $4, $3, true ); }
-	| '[' push declaration_qualifier_list type_qualifier_list assignment_expression pop ']'
-		{ $$ = DeclarationNode::newArray( $5, $4->addQualifiers( $3 ), true ); }
-	;
-
-// This pattern parses a new-style declaration of an abstract variable or function prototype, i.e., there is no
-// identifier to which the type applies, e.g.:
-//
-//	[int] f( int );		// abstract variable parameter; no parameter name specified
-//	[int] f( [int] (int) );	// abstract function-prototype parameter; no parameter name specified
+		'[' push type_qualifier_list '*' pop ']'		// remaining C99
+				{ $$ = DeclarationNode::newVarArray( $3 ); }
+		| '[' push type_qualifier_list assignment_expression pop ']'
+				{ $$ = DeclarationNode::newArray( $4, $3, false ); }
+		| '[' push declaration_qualifier_list assignment_expression pop ']'
+				// declaration_qualifier_list must be used because of shift/reduce conflict with
+				// assignment_expression, so a semantic check is necessary to preclude them as a
+				// type_qualifier cannot appear in this context.
+				{ $$ = DeclarationNode::newArray( $4, $3, true ); }
+		| '[' push declaration_qualifier_list type_qualifier_list assignment_expression pop ']'
+				{ $$ = DeclarationNode::newArray( $5, $4->addQualifiers( $3 ), true ); }
+		;
+
+// This pattern parses a new-style declaration of an abstract variable or function prototype, i.e., there is
+// no identifier to which the type applies, e.g.:
+//
+//		[int] f( int );				// abstract variable parameter; no parameter name specified
+//		[int] f( [int] (int) );		// abstract function-prototype parameter; no parameter name specified
 //
 // These rules need LR(3):
 //
-//	new_abstract_tuple identifier_or_typedef_name
-//	'[' new_parameter_list ']' identifier_or_typedef_name '(' new_parameter_type_list_opt ')'
+//		new_abstract_tuple identifier_or_typedef_name
+//		'[' new_parameter_list ']' identifier_or_typedef_name '(' new_parameter_type_list_opt ')'
 //
 // since a function return type can be syntactically identical to a tuple type:
 //
-//	[int, int] t;
-//	[int, int] f( int );
+//		[int, int] t;
+//		[int, int] f( int );
 //
 // Therefore, it is necessary to look at the token after identifier_or_typedef_name to know when to reduce
-// new_abstract_tuple. To make this LR(1), several rules have to be flattened (lengthened) to allow the necessary
-// lookahead. To accomplish this, new_abstract_declarator has an entry point without tuple, and tuple declarations are
-// duplicated when appearing with new_function_specifier.
-
-new_abstract_declarator_tuple:				// CFA
-	new_abstract_tuple
-	| type_qualifier_list new_abstract_tuple
-		{ $$ = $2->addQualifiers( $1 ); }
-	| new_abstract_declarator_no_tuple
-	;
-
-new_abstract_declarator_no_tuple:			// CFA
-	new_abstract_ptr
-	| new_abstract_array
-	;
-
-new_abstract_ptr:					// CFA
-	'*' type_specifier
-		{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
-	| type_qualifier_list '*' type_specifier
-		{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
-	| '*' new_abstract_function
-		{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
-	| type_qualifier_list '*' new_abstract_function
-		{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
-	| '*' new_abstract_declarator_tuple
-		{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
-	| type_qualifier_list '*' new_abstract_declarator_tuple
-		{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
-	;
-
-new_abstract_array:					// CFA
-		// Only the first dimension can be empty. Empty dimension must be factored out due to shift/reduce
-		// conflict with empty (void) function return type.
-	'[' push pop ']' type_specifier
-		{ $$ = $5->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
-	| '[' push pop ']' multi_array_dimension type_specifier
-		{ $$ = $6->addNewArray( $5 )->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
-	| multi_array_dimension type_specifier
-		{ $$ = $2->addNewArray( $1 ); }
-	| '[' push pop ']' new_abstract_ptr
-		{ $$ = $5->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
-	| '[' push pop ']' multi_array_dimension new_abstract_ptr
-		{ $$ = $6->addNewArray( $5 )->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
-	| multi_array_dimension new_abstract_ptr
-		{ $$ = $2->addNewArray( $1 ); }
-	;
-
-new_abstract_tuple:					// CFA
-	'[' push new_abstract_parameter_list pop ']'
-		{ $$ = DeclarationNode::newTuple( $3 ); }
-	;
-
-new_abstract_function:					// CFA
-	'[' push pop ']' '(' new_parameter_type_list_opt ')'
-		{ $$ = DeclarationNode::newFunction( 0, DeclarationNode::newTuple( 0 ), $6, 0 ); }
-	| new_abstract_tuple '(' push new_parameter_type_list_opt pop ')'
-		{ $$ = DeclarationNode::newFunction( 0, $1, $4, 0 ); }
-	| new_function_return '(' push new_parameter_type_list_opt pop ')'
-		{ $$ = DeclarationNode::newFunction( 0, $1, $4, 0 ); }
-	;
-
-// 1) ISO/IEC 9899:1999 Section 6.7.2(2) : "At least one type specifier shall be given in the declaration specifiers in
-//    each declaration, and in the specifier-qualifier list in each structure declaration and type name."
-//
-// 2) ISO/IEC 9899:1999 Section 6.11.5(1) : "The placement of a storage-class specifier other than at the beginning of
-//    the declaration specifiers in a declaration is an obsolescent feature."
+// new_abstract_tuple. To make this LR(1), several rules have to be flattened (lengthened) to allow the
+// necessary lookahead. To accomplish this, new_abstract_declarator has an entry point without tuple, and
+// tuple declarations are duplicated when appearing with new_function_specifier.
+
+new_abstract_declarator_tuple:							// CFA
+		new_abstract_tuple
+		| type_qualifier_list new_abstract_tuple
+				{ $$ = $2->addQualifiers( $1 ); }
+		| new_abstract_declarator_no_tuple
+		;
+
+new_abstract_declarator_no_tuple:						// CFA
+		new_abstract_ptr
+		| new_abstract_array
+		;
+
+new_abstract_ptr:										// CFA
+		'*' type_specifier
+				{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
+		| type_qualifier_list '*' type_specifier
+				{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
+		| '*' new_abstract_function
+				{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
+		| type_qualifier_list '*' new_abstract_function
+				{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
+		| '*' new_abstract_declarator_tuple
+				{ $$ = $2->addNewPointer( DeclarationNode::newPointer( 0 ) ); }
+		| type_qualifier_list '*' new_abstract_declarator_tuple
+				{ $$ = $3->addNewPointer( DeclarationNode::newPointer( $1 ) ); }
+		;
+
+new_abstract_array:										// CFA
+				// Only the first dimension can be empty. Empty dimension must be factored out due to
+				// shift/reduce conflict with empty (void) function return type.
+		'[' push pop ']' type_specifier
+				{ $$ = $5->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
+		| '[' push pop ']' multi_array_dimension type_specifier
+				{ $$ = $6->addNewArray( $5 )->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
+		| multi_array_dimension type_specifier
+				{ $$ = $2->addNewArray( $1 ); }
+		| '[' push pop ']' new_abstract_ptr
+				{ $$ = $5->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
+		| '[' push pop ']' multi_array_dimension new_abstract_ptr
+				{ $$ = $6->addNewArray( $5 )->addNewArray( DeclarationNode::newArray( 0, 0, false ) ); }
+		| multi_array_dimension new_abstract_ptr
+				{ $$ = $2->addNewArray( $1 ); }
+		;
+
+new_abstract_tuple:										// CFA
+		'[' push new_abstract_parameter_list pop ']'
+				{ $$ = DeclarationNode::newTuple( $3 ); }
+		;
+
+new_abstract_function:									// CFA
+		'[' push pop ']' '(' new_parameter_type_list_opt ')'
+				{ $$ = DeclarationNode::newFunction( 0, DeclarationNode::newTuple( 0 ), $6, 0 ); }
+		| new_abstract_tuple '(' push new_parameter_type_list_opt pop ')'
+				{ $$ = DeclarationNode::newFunction( 0, $1, $4, 0 ); }
+		| new_function_return '(' push new_parameter_type_list_opt pop ')'
+				{ $$ = DeclarationNode::newFunction( 0, $1, $4, 0 ); }
+		;
+
+// 1) ISO/IEC 9899:1999 Section 6.7.2(2) : "At least one type specifier shall be given in the declaration
+//    specifiers in each declaration, and in the specifier-qualifier list in each structure declaration and
+//    type name."
+//
+// 2) ISO/IEC 9899:1999 Section 6.11.5(1) : "The placement of a storage-class specifier other than at the
+//    beginning of the declaration specifiers in a declaration is an obsolescent feature."
 //
 // 3) ISO/IEC 9899:1999 Section 6.11.6(1) : "The use of function declarators with empty parentheses (not
 //    prototype-format parameter type declarators) is an obsolescent feature."
 //
-// 4) ISO/IEC 9899:1999 Section 6.11.7(1) : "The use of function definitions with separate parameter identifier and
-//    declaration lists (not prototype-format parameter type and identifier declarators) is an obsolescent feature.
+// 4) ISO/IEC 9899:1999 Section 6.11.7(1) : "The use of function definitions with separate parameter
+//    identifier and declaration lists (not prototype-format parameter type and identifier declarators) is an
+//    obsolescent feature.
 
 //************************* MISCELLANEOUS ********************************
 
-comma_opt:						// redundant comma
-	// empty
-	| ','
-	;
+comma_opt:												// redundant comma
+		// empty
+		| ','
+		;
 
 assignment_opt:
-	// empty
-		{ $$ = 0; }
-	| '=' assignment_expression
-		{ $$ = $2; }
-	;
+		// empty
+				{ $$ = 0; }
+		| '=' assignment_expression
+				{ $$ = $2; }
+		;
 
 %%
@@ -2720,15 +2719,17 @@
 
 void yyerror( char *string ) {
-    using std::cout;
-    using std::endl;
-    cout << "Error ";
-    if ( yyfilename ) {
-	cout << "in file " << yyfilename << " ";
-    }
-    cout << "at line " << yylineno << " reading token \"" << *(yylval.tok.str) << "\"" << endl;
+	using std::cout;
+	using std::endl;
+	cout << "Error ";
+	if ( yyfilename ) {
+		cout << "in file " << yyfilename << " ";
+	}
+	cout << "at line " << yylineno << " reading token \"" << *(yylval.tok.str) << "\"" << endl;
 }
 
 // Local Variables: //
 // fill-column: 110 //
+// tab-width: 4 //
+// mode: c++ //
 // compile-command: "make install" //
 // End: //
Index: translator/Parser/lex.h
===================================================================
--- translator/Parser/lex.h	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/lex.h	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,11 +1,16 @@
-/*
- * This file is part of the Cforall project
- *
- * $Id: lex.h,v 1.2 2003/11/07 19:45:31 rcbilson Exp $
- *
- * Prototypes that enable Roskind's c5.y to compile with g++
- * Richard Bilson       5 Jan 2001
- *
- */
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+// 
+// lex.h -- 
+// 
+// Author           : Peter A. Buhr
+// Created On       : Sat Sep 22 08:58:10 2001
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 12:18:48 2015
+// Update Count     : 334
+//
 
 #ifndef PARSER_LEX_H
@@ -14,30 +19,32 @@
 int yylex();
 void yyerror(char *);
-extern "C" {
-#include <malloc.h>
-}
 
-/* External declarations for information sharing between lexer and scanner */
+// External declarations for information sharing between lexer and scanner
 #include "TypedefTable.h"
 extern TypedefTable typedefTable;
 
-/* current location in the input */
+// current location in the input
 extern int yylineno;
 extern char *yyfilename;
 
-struct Location
-{
-  char *file;
-  int line;
+struct Location {
+    char *file;
+    int line;
 };
 
-class Token
-{
-public:
-  std::string *str;
-  Location loc;
+class Token {
+  public:
+    std::string *str;
+    Location loc;
 
-  operator std::string *() { return str; }
+    operator std::string *() { return str; }
 };
 
-#endif // ifndef PARSER_LEX_H
+#endif // PARSER_LEX_H
+
+// Local Variables: //
+// fill-column: 110 //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/lex.l
===================================================================
--- translator/Parser/lex.l	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/lex.l	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,7 +1,7 @@
-/*                               -*- Mode: C -*- 
- * 
- * CForall Lexer Version 1.0, Copyright (C) Peter A. Buhr 2001 -- Permission is granted to copy this
- *	grammar and to use it within software systems.  THIS GRAMMAR IS PROVIDED "AS IS" AND WITHOUT
- *	ANY EXPRESS OR IMPLIED WARRANTIES.
+/*
+ * Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+ *
+ * The contents of this file are covered under the licence agreement in the
+ * file "LICENCE" distributed with Cforall.
  * 
  * lex.l -- 
@@ -10,6 +10,6 @@
  * Created On       : Sat Sep 22 08:58:10 2001
  * Last Modified By : Peter A. Buhr
- * Last Modified On : Wed Jan 21 08:43:59 2015
- * Update Count     : 320
+ * Last Modified On : Sat May 16 12:14:18 2015
+ * Update Count     : 330
  */
 
@@ -17,8 +17,7 @@
 
 %{
-// This lexer assumes the program has been preprocessed by cpp. Hence, all user level preprocessor
-// directive have been performed and removed from the source. The only exceptions are preprocessor
-// directives passed to the compiler (e.g., line-number directives) and C/C++ style comments, which
-// are ignored.
+// This lexer assumes the program has been preprocessed by cpp. Hence, all user level preprocessor directive
+// have been performed and removed from the source. The only exceptions are preprocessor directives passed to
+// the compiler (e.g., line-number directives) and C/C++ style comments, which are ignored.
 
 //**************************** Includes and Defines ****************************
@@ -28,41 +27,41 @@
 #include "lex.h"
 #include "ParseNode.h"
-#include "cfa.tab.h" // YACC generated definitions based on C++ grammar
+#include "cfa.tab.h"									// YACC generated definitions based on C++ grammar
 
 char *yyfilename;
-std::string *strtext;					// accumulate parts of character and string constant value
-
-#define WHITE_RETURN(x)					// do nothing
+std::string *strtext;									// accumulate parts of character and string constant value
+
+#define WHITE_RETURN(x)									// do nothing
 #define NEWLINE_RETURN()	WHITE_RETURN('\n')
 #define RETURN_VAL(x)		yylval.tok.str = new std::string(yytext); \
-                                yylval.tok.loc.file = yyfilename; \
-                                yylval.tok.loc.line = yylineno; \
-                                return(x)
+		                        yylval.tok.loc.file = yyfilename; \
+		                        yylval.tok.loc.line = yylineno; \
+		                        return(x)
 #define RETURN_STR(x)		yylval.tok.str = strtext; \
-                                yylval.tok.loc.file = yyfilename; \
-                                yylval.tok.loc.line = yylineno; \
-                                return(x)
-
-#define KEYWORD_RETURN(x)	RETURN_VAL(x)		// keyword
+		                        yylval.tok.loc.file = yyfilename; \
+		                        yylval.tok.loc.line = yylineno; \
+		                        return(x)
+
+#define KEYWORD_RETURN(x)	RETURN_VAL(x)				// keyword
 #define IDENTIFIER_RETURN()	RETURN_VAL((typedefTable.isIdentifier(yytext) ? IDENTIFIER : typedefTable.isTypedef(yytext) ? TYPEDEFname : TYPEGENname))
 //#define ATTRIBUTE_RETURN()	RETURN_VAL((typedefTable.isIdentifier(yytext) ? ATTR_IDENTIFIER : typedefTable.isTypedef(yytext) ? ATTR_TYPEDEFname : ATTR_TYPEGENname))
 #define ATTRIBUTE_RETURN()	RETURN_VAL(ATTR_IDENTIFIER)
 
-#define ASCIIOP_RETURN()	RETURN_VAL((int)yytext[0]) // single character operator
-#define NAMEDOP_RETURN(x)	RETURN_VAL(x)		// multichar operator, with a name
+#define ASCIIOP_RETURN()	RETURN_VAL((int)yytext[0])	// single character operator
+#define NAMEDOP_RETURN(x)	RETURN_VAL(x)				// multichar operator, with a name
 
 #define NUMERIC_RETURN(x)	rm_underscore(); RETURN_VAL(x) // numeric constant
 
 void rm_underscore() {
-    // remove underscores in numeric constant
-    int j = 0;
-    for ( int i = 0; yytext[i] != '\0'; i += 1 ) {
-	if ( yytext[i] != '_' ) {
-	    yytext[j] = yytext[i];
-	    j += 1;
-	} // if
-    } // for
-    yyleng = j;
-    yytext[yyleng] = '\0';
+	// remove underscores in numeric constant
+	int j = 0;
+	for ( int i = 0; yytext[i] != '\0'; i += 1 ) {
+		if ( yytext[i] != '_' ) {
+			yytext[j] = yytext[i];
+			j += 1;
+		} // if
+	} // for
+	yyleng = j;
+	yytext[yyleng] = '\0';
 }
 
@@ -75,14 +74,14 @@
 universal_char "\\"((u"_"?{hex_quad})|(U"_"?{hex_quad}{2}))
 
-	// identifier, GCC: $ in identifier
+				// identifier, GCC: $ in identifier
 identifier ([a-zA-Z_$]|{universal_char})([0-9a-zA-Z_$]|{universal_char})*
 
-	// quoted identifier
+				// quoted identifier
 quoted_identifier "`"{identifier}"`"
 
-	// attribute identifier, GCC: $ in identifier
+				// attribute identifier, GCC: $ in identifier
 attr_identifier "@"{identifier}
 
-	// numeric constants, CFA: '_' in constant
+				// numeric constants, CFA: '_' in constant
 hex_quad {hex}("_"?{hex}){3}
 integer_suffix "_"?(([uU][lL]?)|([uU]("ll"|"LL")?)|([lL][uU]?)|("ll"|"LL")[uU]?)
@@ -109,12 +108,12 @@
 hex_floating_constant {hex_prefix}(({hex_fractional_constant}{binary_exponent})|({hex_digits}{binary_exponent})){floating_suffix}?
 
-	// character escape sequence, GCC: \e => esc character
+				// character escape sequence, GCC: \e => esc character
 simple_escape "\\"[abefnrtv'"?\\]
-	// ' stop highlighting
+				// ' stop highlighting
 octal_escape "\\"{octal}("_"?{octal}){0,2}
 hex_escape "\\""x""_"?{hex_digits}
 escape_seq {simple_escape}|{octal_escape}|{hex_escape}|{universal_char}
 
-	// display/white-space characters
+				// display/white-space characters
 h_tab [\011]
 form_feed [\014]
@@ -123,5 +122,5 @@
 h_white [ ]|{h_tab}
 
-	// operators
+				// operators
 op_unary_only "~"|"!"
 op_unary_binary "+"|"-"|"*"
@@ -140,5 +139,5 @@
 
 %%
-	/* line directives */
+				   /* line directives */
 ^{h_white}*"#"{h_white}*[0-9]+{h_white}*["][^"\n]+["][^\n]*"\n" {
 	/* " stop highlighting */
@@ -150,130 +149,130 @@
 	begin_string = strchr( end_num, '"' );
 	if ( begin_string ) {
-	    end_string = strchr( begin_string + 1, '"' );
-	    if ( end_string ) {
-		length = end_string - begin_string - 1;
-		filename = new char[ length + 1 ];
-		memcpy( filename, begin_string + 1, length );
-		filename[ length ] = '\0';
-		//std::cout << "file " << filename << " line " << lineno << std::endl;
-		yylineno = lineno;
-		yyfilename = filename;
-	    }
-	}
+		end_string = strchr( begin_string + 1, '"' );
+		if ( end_string ) {
+			length = end_string - begin_string - 1;
+			filename = new char[ length + 1 ];
+			memcpy( filename, begin_string + 1, length );
+			filename[ length ] = '\0';
+			//std::cout << "file " << filename << " line " << lineno << std::endl;
+			yylineno = lineno;
+			yyfilename = filename;
+		} // if
+	} // if
 }
 
-	/* ignore preprocessor directives (for now) */
+				/* ignore preprocessor directives (for now) */
 ^{h_white}*"#"[^\n]*"\n" ;
 
-	/* ignore C style comments */
+				/* ignore C style comments */
 "/*"			{ BEGIN COMMENT; }
 <COMMENT>.|\n		;
 <COMMENT>"*/"		{ BEGIN 0; }
 
-	/* ignore C++ style comments */
+				/* ignore C++ style comments */
 "//"[^\n]*"\n"		;
 
-	/* ignore whitespace */
+				/* ignore whitespace */
 {h_white}+		{ WHITE_RETURN(' '); }
 ({v_tab}|{c_return}|{form_feed})+ { WHITE_RETURN(' '); }
 ({h_white}|{v_tab}|{c_return}|{form_feed})*"\n" { NEWLINE_RETURN(); }
 
-	/* keywords */
-_Alignas		{ KEYWORD_RETURN(ALIGNAS); }	// C11
-_Alignof		{ KEYWORD_RETURN(ALIGNOF); }	// C11
-__alignof		{ KEYWORD_RETURN(ALIGNOF); }	// GCC
-__alignof__		{ KEYWORD_RETURN(ALIGNOF); }	// GCC
-asm			{ KEYWORD_RETURN(ASM); }
-__asm			{ KEYWORD_RETURN(ASM); }	// GCC
-__asm__			{ KEYWORD_RETURN(ASM); }	// GCC
-_Atomic			{ KEYWORD_RETURN(ATOMIC); }	// C11
-__attribute		{ KEYWORD_RETURN(ATTRIBUTE); }	// GCC
-__attribute__		{ KEYWORD_RETURN(ATTRIBUTE); }	// GCC
+				/* keywords */
+_Alignas		{ KEYWORD_RETURN(ALIGNAS); }			// C11
+_Alignof		{ KEYWORD_RETURN(ALIGNOF); }			// C11
+__alignof		{ KEYWORD_RETURN(ALIGNOF); }			// GCC
+__alignof__		{ KEYWORD_RETURN(ALIGNOF); }			// GCC
+asm				{ KEYWORD_RETURN(ASM); }
+__asm			{ KEYWORD_RETURN(ASM); }				// GCC
+__asm__			{ KEYWORD_RETURN(ASM); }				// GCC
+_Atomic			{ KEYWORD_RETURN(ATOMIC); }				// C11
+__attribute		{ KEYWORD_RETURN(ATTRIBUTE); }			// GCC
+__attribute__	{ KEYWORD_RETURN(ATTRIBUTE); }			// GCC
 auto			{ KEYWORD_RETURN(AUTO); }
-_Bool			{ KEYWORD_RETURN(BOOL); }	// C99
+_Bool			{ KEYWORD_RETURN(BOOL); }				// C99
 break			{ KEYWORD_RETURN(BREAK); }
 case			{ KEYWORD_RETURN(CASE); }
-catch			{ KEYWORD_RETURN(CATCH); }	// CFA
+catch			{ KEYWORD_RETURN(CATCH); }				// CFA
 char			{ KEYWORD_RETURN(CHAR); }
-choose			{ KEYWORD_RETURN(CHOOSE); }	// CFA
-_Complex		{ KEYWORD_RETURN(COMPLEX); }	// C99
-__complex		{ KEYWORD_RETURN(COMPLEX); }	// GCC
-__complex__		{ KEYWORD_RETURN(COMPLEX); }	// GCC
+choose			{ KEYWORD_RETURN(CHOOSE); }				// CFA
+_Complex		{ KEYWORD_RETURN(COMPLEX); }			// C99
+__complex		{ KEYWORD_RETURN(COMPLEX); }			// GCC
+__complex__		{ KEYWORD_RETURN(COMPLEX); }			// GCC
 const			{ KEYWORD_RETURN(CONST); }
-__const			{ KEYWORD_RETURN(CONST); }	// GCC
-__const__		{ KEYWORD_RETURN(CONST); }	// GCC
-context			{ KEYWORD_RETURN(CONTEXT); }	// CFA
+__const			{ KEYWORD_RETURN(CONST); }				// GCC
+__const__		{ KEYWORD_RETURN(CONST); }				// GCC
+context			{ KEYWORD_RETURN(CONTEXT); }			// CFA
 continue		{ KEYWORD_RETURN(CONTINUE); }
 default			{ KEYWORD_RETURN(DEFAULT); }
-do			{ KEYWORD_RETURN(DO); }
+do				{ KEYWORD_RETURN(DO); }
 double			{ KEYWORD_RETURN(DOUBLE); }
-dtype			{ KEYWORD_RETURN(DTYPE); }	// CFA
+dtype			{ KEYWORD_RETURN(DTYPE); }				// CFA
 else			{ KEYWORD_RETURN(ELSE); }
 enum			{ KEYWORD_RETURN(ENUM); }
-__extension__		{ KEYWORD_RETURN(EXTENSION); }	// GCC
+__extension__	{ KEYWORD_RETURN(EXTENSION); }			// GCC
 extern			{ KEYWORD_RETURN(EXTERN); }
-fallthru		{ KEYWORD_RETURN(FALLTHRU); }	// CFA
-finally			{ KEYWORD_RETURN(FINALLY); }	// CFA
+fallthru		{ KEYWORD_RETURN(FALLTHRU); }			// CFA
+finally			{ KEYWORD_RETURN(FINALLY); }			// CFA
 float			{ KEYWORD_RETURN(FLOAT); }
-__float128		{ KEYWORD_RETURN(FLOAT); }	// GCC
-for			{ KEYWORD_RETURN(FOR); }
-forall			{ KEYWORD_RETURN(FORALL); }	// CFA
+__float128		{ KEYWORD_RETURN(FLOAT); }				// GCC
+for				{ KEYWORD_RETURN(FOR); }
+forall			{ KEYWORD_RETURN(FORALL); }				// CFA
 fortran			{ KEYWORD_RETURN(FORTRAN); }
-ftype			{ KEYWORD_RETURN(FTYPE); }	// CFA
-_Generic		{ KEYWORD_RETURN(GENERIC); }	// C11
+ftype			{ KEYWORD_RETURN(FTYPE); }				// CFA
+_Generic		{ KEYWORD_RETURN(GENERIC); }			// C11
 goto			{ KEYWORD_RETURN(GOTO); }
-if			{ KEYWORD_RETURN(IF); }
-_Imaginary		{ KEYWORD_RETURN(IMAGINARY); }	// C99
-__imag			{ KEYWORD_RETURN(IMAGINARY); }	// GCC
-__imag__		{ KEYWORD_RETURN(IMAGINARY); }	// GCC
-inline			{ KEYWORD_RETURN(INLINE); }	// C99
-__inline		{ KEYWORD_RETURN(INLINE); }	// GCC
-__inline__		{ KEYWORD_RETURN(INLINE); }	// GCC
-int			{ KEYWORD_RETURN(INT); }
-__int128		{ KEYWORD_RETURN(INT); }	// GCC
-__label__		{ KEYWORD_RETURN(LABEL); }	// GCC
+if				{ KEYWORD_RETURN(IF); }
+_Imaginary		{ KEYWORD_RETURN(IMAGINARY); }			// C99
+__imag			{ KEYWORD_RETURN(IMAGINARY); }			// GCC
+__imag__		{ KEYWORD_RETURN(IMAGINARY); }			// GCC
+inline			{ KEYWORD_RETURN(INLINE); }				// C99
+__inline		{ KEYWORD_RETURN(INLINE); }				// GCC
+__inline__		{ KEYWORD_RETURN(INLINE); }				// GCC
+int				{ KEYWORD_RETURN(INT); }
+__int128		{ KEYWORD_RETURN(INT); }				// GCC
+__label__		{ KEYWORD_RETURN(LABEL); }				// GCC
 long			{ KEYWORD_RETURN(LONG); }
-lvalue			{ KEYWORD_RETURN(LVALUE); }	// CFA
-_Noreturn		{ KEYWORD_RETURN(NORETURN); }	// C11
+lvalue			{ KEYWORD_RETURN(LVALUE); }				// CFA
+_Noreturn		{ KEYWORD_RETURN(NORETURN); }			// C11
 register		{ KEYWORD_RETURN(REGISTER); }
-restrict		{ KEYWORD_RETURN(RESTRICT); }	// C99
-__restrict		{ KEYWORD_RETURN(RESTRICT); }	// GCC
-__restrict__		{ KEYWORD_RETURN(RESTRICT); }	// GCC
+restrict		{ KEYWORD_RETURN(RESTRICT); }			// C99
+__restrict		{ KEYWORD_RETURN(RESTRICT); }			// GCC
+__restrict__	{ KEYWORD_RETURN(RESTRICT); }			// GCC
 return			{ KEYWORD_RETURN(RETURN); }
 short			{ KEYWORD_RETURN(SHORT); }
 signed			{ KEYWORD_RETURN(SIGNED); }
-__signed		{ KEYWORD_RETURN(SIGNED); }	// GCC
-__signed__		{ KEYWORD_RETURN(SIGNED); }	// GCC
+__signed		{ KEYWORD_RETURN(SIGNED); }				// GCC
+__signed__		{ KEYWORD_RETURN(SIGNED); }				// GCC
 sizeof			{ KEYWORD_RETURN(SIZEOF); }
 static			{ KEYWORD_RETURN(STATIC); }
-_Static_assert		{ KEYWORD_RETURN(STATICASSERT); } // C11
+_Static_assert	{ KEYWORD_RETURN(STATICASSERT); }		// C11
 struct			{ KEYWORD_RETURN(STRUCT); }
 switch			{ KEYWORD_RETURN(SWITCH); }
-_Thread_local		{ KEYWORD_RETURN(THREADLOCAL); } // C11
-throw			{ KEYWORD_RETURN(THROW); }	// CFA
-try			{ KEYWORD_RETURN(TRY); }	// CFA
-type			{ KEYWORD_RETURN(TYPE); }	// CFA
+_Thread_local	{ KEYWORD_RETURN(THREADLOCAL); }		// C11
+throw			{ KEYWORD_RETURN(THROW); }				// CFA
+try				{ KEYWORD_RETURN(TRY); }				// CFA
+type			{ KEYWORD_RETURN(TYPE); }				// CFA
 typedef			{ KEYWORD_RETURN(TYPEDEF); }
-typeof			{ KEYWORD_RETURN(TYPEOF); }	// GCC
-__typeof		{ KEYWORD_RETURN(TYPEOF); }	// GCC
-__typeof__		{ KEYWORD_RETURN(TYPEOF); }	// GCC
+typeof			{ KEYWORD_RETURN(TYPEOF); }				// GCC
+__typeof		{ KEYWORD_RETURN(TYPEOF); }				// GCC
+__typeof__		{ KEYWORD_RETURN(TYPEOF); }				// GCC
 union			{ KEYWORD_RETURN(UNION); }
 unsigned		{ KEYWORD_RETURN(UNSIGNED); }
 void			{ KEYWORD_RETURN(VOID); }
 volatile		{ KEYWORD_RETURN(VOLATILE); }
-__volatile		{ KEYWORD_RETURN(VOLATILE); }	// GCC
-__volatile__		{ KEYWORD_RETURN(VOLATILE); }	// GCC
+__volatile		{ KEYWORD_RETURN(VOLATILE); }			// GCC
+__volatile__	{ KEYWORD_RETURN(VOLATILE); }			// GCC
 while			{ KEYWORD_RETURN(WHILE); }
 
-	/* identifier */
-{identifier}		{ IDENTIFIER_RETURN(); }
-{attr_identifier}	{ ATTRIBUTE_RETURN(); }
+				/* identifier */
+{identifier}	{ IDENTIFIER_RETURN(); }
+{attr_identifier} { ATTRIBUTE_RETURN(); }
 "`"			{ BEGIN BKQUOTE; }
-<BKQUOTE>{identifier}	{ IDENTIFIER_RETURN(); }
-<BKQUOTE>"`"		{ BEGIN 0; }
-
-	/* numeric constants */
-"0"			{ NUMERIC_RETURN(ZERO); }	// CFA
-"1"			{ NUMERIC_RETURN(ONE); }	// CFA
+<BKQUOTE>{identifier} { IDENTIFIER_RETURN(); }
+<BKQUOTE>"`"	{ BEGIN 0; }
+
+				/* numeric constants */
+"0"				{ NUMERIC_RETURN(ZERO); }				// CFA
+"1"				{ NUMERIC_RETURN(ONE); }				// CFA
 {decimal_constant}	{ NUMERIC_RETURN(INTEGERconstant); }
 {octal_constant}	{ NUMERIC_RETURN(INTEGERconstant); }
@@ -282,33 +281,33 @@
 {hex_floating_constant}	{ NUMERIC_RETURN(FLOATINGconstant); }
 
-	/* character constant, allows empty value */
+				/* character constant, allows empty value */
 "L"?"_"?[']		{ BEGIN QUOTE; rm_underscore(); strtext = new std::string; *strtext += std::string( yytext ); }
-<QUOTE>[^'\\\n]*	{ *strtext += std::string( yytext ); }
-<QUOTE>['\n]		{ BEGIN 0; *strtext += std::string( yytext); RETURN_STR(CHARACTERconstant); }
-	/* ' stop highlighting */
-
-	/* string constant */
+<QUOTE>[^'\\\n]* { *strtext += std::string( yytext ); }
+<QUOTE>['\n]	{ BEGIN 0; *strtext += std::string( yytext); RETURN_STR(CHARACTERconstant); }
+				/* ' stop highlighting */
+
+				/* string constant */
 "L"?"_"?["]		{ BEGIN STRING; rm_underscore(); strtext = new std::string; *strtext += std::string( yytext ); }
-<STRING>[^"\\\n]*	{ *strtext += std::string( yytext ); }
-<STRING>["\n]		{ BEGIN 0; *strtext += std::string( yytext); RETURN_STR(STRINGliteral); }
-	/* " stop highlighting */
+<STRING>[^"\\\n]* { *strtext += std::string( yytext ); }
+<STRING>["\n]	{ BEGIN 0; *strtext += std::string( yytext); RETURN_STR(STRINGliteral); }
+				/* " stop highlighting */
 
 <QUOTE,STRING>{escape_seq} { rm_underscore(); *strtext += std::string( yytext ); }
 <QUOTE,STRING>[\\]	{ *strtext += std::string( yytext ); } // unknown escape character
 
-	/* punctuation */
-"["			{ ASCIIOP_RETURN(); }
-"]"			{ ASCIIOP_RETURN(); }
-"("			{ ASCIIOP_RETURN(); }
-")"			{ ASCIIOP_RETURN(); }
-"{"			{ ASCIIOP_RETURN(); }
-"}"			{ ASCIIOP_RETURN(); }
-","			{ ASCIIOP_RETURN(); }		// also operator
-":"			{ ASCIIOP_RETURN(); }
-";"			{ ASCIIOP_RETURN(); }
-"."			{ ASCIIOP_RETURN(); }		// also operator
+				/* punctuation */
+"["				{ ASCIIOP_RETURN(); }
+"]"				{ ASCIIOP_RETURN(); }
+"("				{ ASCIIOP_RETURN(); }
+")"				{ ASCIIOP_RETURN(); }
+"{"				{ ASCIIOP_RETURN(); }
+"}"				{ ASCIIOP_RETURN(); }
+","				{ ASCIIOP_RETURN(); }					// also operator
+":"				{ ASCIIOP_RETURN(); }
+";"				{ ASCIIOP_RETURN(); }
+"."				{ ASCIIOP_RETURN(); }					// also operator
 "..."			{ NAMEDOP_RETURN(ELLIPSIS); }
 
-	/* alternative C99 brackets, "<:" & "<:<:" handled by preprocessor */
+				/* alternative C99 brackets, "<:" & "<:<:" handled by preprocessor */
 "<:"			{ RETURN_VAL('['); }
 ":>"			{ RETURN_VAL(']'); }
@@ -316,19 +315,19 @@
 "%>"			{ RETURN_VAL('}'); }
 
-	/* operators */
-"!"			{ ASCIIOP_RETURN(); }
-"+"			{ ASCIIOP_RETURN(); }
-"-"			{ ASCIIOP_RETURN(); }
-"*"			{ ASCIIOP_RETURN(); }
-"/"			{ ASCIIOP_RETURN(); }
-"%"			{ ASCIIOP_RETURN(); }
-"^"			{ ASCIIOP_RETURN(); }
-"~"			{ ASCIIOP_RETURN(); }
-"&"			{ ASCIIOP_RETURN(); }
-"|"			{ ASCIIOP_RETURN(); }
-"<"			{ ASCIIOP_RETURN(); }
-">"			{ ASCIIOP_RETURN(); }
-"="			{ ASCIIOP_RETURN(); }
-"?"			{ ASCIIOP_RETURN(); }
+				/* operators */
+"!"				{ ASCIIOP_RETURN(); }
+"+"				{ ASCIIOP_RETURN(); }
+"-"				{ ASCIIOP_RETURN(); }
+"*"				{ ASCIIOP_RETURN(); }
+"/"				{ ASCIIOP_RETURN(); }
+"%"				{ ASCIIOP_RETURN(); }
+"^"				{ ASCIIOP_RETURN(); }
+"~"				{ ASCIIOP_RETURN(); }
+"&"				{ ASCIIOP_RETURN(); }
+"|"				{ ASCIIOP_RETURN(); }
+"<"				{ ASCIIOP_RETURN(); }
+">"				{ ASCIIOP_RETURN(); }
+"="				{ ASCIIOP_RETURN(); }
+"?"				{ ASCIIOP_RETURN(); }
 
 "++"			{ NAMEDOP_RETURN(ICR); }
@@ -354,22 +353,20 @@
 ">>="			{ NAMEDOP_RETURN(RSassign); }
 
-	/* CFA, operator identifier */
-{op_unary}"?"		{ IDENTIFIER_RETURN(); }	// unary
+				/* CFA, operator identifier */
+{op_unary}"?"	{ IDENTIFIER_RETURN(); }				// unary
 "?"({op_unary_pre_post}|"()"|"[?]") { IDENTIFIER_RETURN(); }
-"?"{op_binary_over}"?"	{ IDENTIFIER_RETURN(); }	// binary
+"?"{op_binary_over}"?"	{ IDENTIFIER_RETURN(); }		// binary
 	/*
-	  This rule handles ambiguous cases with operator identifiers, e.g., "int *?*?()", where the
-	  string "*?*?"  can be lexed as "*"/"?*?" or "*?"/"*?". Since it is common practise to put
-	  a unary operator juxtaposed to an identifier, e.g., "*i", users will be annoyed if they
-	  cannot do this with respect to operator identifiers. Even with this special hack, there
-	  are 5 general cases that cannot be handled. The first case is for the function-call
-	  identifier "?()":
+	  This rule handles ambiguous cases with operator identifiers, e.g., "int *?*?()", where the string "*?*?"
+	  can be lexed as "*"/"?*?" or "*?"/"*?". Since it is common practise to put a unary operator juxtaposed
+	  to an identifier, e.g., "*i", users will be annoyed if they cannot do this with respect to operator
+	  identifiers. Even with this special hack, there are 5 general cases that cannot be handled. The first
+	  case is for the function-call identifier "?()":
 
 	  int * ?()();	// declaration: space required after '*'
 	  * ?()();	// expression: space required after '*'
 
-	  Without the space, the string "*?()" is ambiguous without N character look ahead; it
-	  requires scanning ahead to determine if there is a '(', which is the start of an
-	  argument/parameter list.
+	  Without the space, the string "*?()" is ambiguous without N character look ahead; it requires scanning
+	  ahead to determine if there is a '(', which is the start of an argument/parameter list.
 
 	  The 4 remaining cases occur in expressions:
@@ -380,29 +377,30 @@
 	  i?--i:0;		// space required after '?'
 
-	  In the first two cases, the string "i++?" is ambiguous, where this string can be lexed as
-	  "i"/"++?" or "i++"/"?"; it requires scanning ahead to determine if there is a '(', which
-	  is the start of an argument list.  In the second two cases, the string "?++x" is
-	  ambiguous, where this string can be lexed as "?++"/"x" or "?"/"++x"; it requires scanning
-	  ahead to determine if there is a '(', which is the start of an argument list.
+	  In the first two cases, the string "i++?" is ambiguous, where this string can be lexed as "i"/"++?" or
+	  "i++"/"?"; it requires scanning ahead to determine if there is a '(', which is the start of an argument
+	  list.  In the second two cases, the string "?++x" is ambiguous, where this string can be lexed as
+	  "?++"/"x" or "?"/"++x"; it requires scanning ahead to determine if there is a '(', which is the start of
+	  an argument list.
 	*/
 {op_unary}"?"(({op_unary_pre_post}|"[?]")|({op_binary_over}"?")) {
-			    // 1 or 2 character unary operator ?
-			    int i = yytext[1] == '?' ? 1 : 2;
-			    yyless( i );		// put back characters up to first '?'
-			    if ( i > 1 ) {
-				NAMEDOP_RETURN( yytext[0] == '+' ? ICR : DECR );
-			    } else {
-				ASCIIOP_RETURN();
-			    } // if
-			}
-
-	/* unknown characters */
+	// 1 or 2 character unary operator ?
+	int i = yytext[1] == '?' ? 1 : 2;
+	yyless( i );		// put back characters up to first '?'
+	if ( i > 1 ) {
+		NAMEDOP_RETURN( yytext[0] == '+' ? ICR : DECR );
+	} else {
+		ASCIIOP_RETURN();
+	} // if
+}
+
+				/* unknown characters */
 .			{ printf("unknown character(s):\"%s\" on line %d\n", yytext, yylineno); }
 
 %%
 
-
-// Local Variables:
-// fill-column: 100
-// compile-command: "make"
-// End:
+// Local Variables: //
+// fill-column: 110 //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/module.mk
===================================================================
--- translator/Parser/module.mk	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/module.mk	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,7 +1,17 @@
-###
-### This file is part of the Cforall project
-###
-### $Id: module.mk,v 1.12 2005/08/30 19:11:40 rcbilson Exp $
-###
+######################### -*- Mode: Makefile-Gmake -*- ########################
+##
+## Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+##
+## The contents of this file are covered under the licence agreement in the
+## file "LICENCE" distributed with Cforall.
+##
+## module.mk -- 
+##
+## Author           : Peter A. Buhr
+## Created On       : Sat May 16 15:29:09 2015
+## Last Modified By : Peter A. Buhr
+## Last Modified On : Sat May 16 15:29:50 2015
+## Update Count     : 1
+###############################################################################
 
 YACC=bison
Index: translator/Parser/parseutility.cc
===================================================================
--- translator/Parser/parseutility.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/parseutility.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,11 +1,31 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// parseutility.cc -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 15:30:39 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 15:31:33 2015
+// Update Count     : 2
+// 
+
 #include "parseutility.h"
 #include "SynTree/Type.h"
 #include "SynTree/Expression.h"
 
+Expression *notZeroExpr( Expression *orig ) {
+	UntypedExpr *comparison = new UntypedExpr( new NameExpr( "?!=?" ) );
+	comparison->get_args().push_back( orig );
+	comparison->get_args().push_back( new NameExpr( "0" ) );
+	return new CastExpr( comparison, new BasicType( Type::Qualifiers(), BasicType::SignedInt ) );
+}
 
-Expression *notZeroExpr( Expression *orig ) {
-      UntypedExpr *comparison = new UntypedExpr( new NameExpr( "?!=?" ) );
-      comparison->get_args().push_back( orig );
-      comparison->get_args().push_back( new NameExpr( "0" ) );
-      return new CastExpr( comparison, new BasicType( Type::Qualifiers(), BasicType::SignedInt ) );
-}
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/Parser/parseutility.h
===================================================================
--- translator/Parser/parseutility.h	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/Parser/parseutility.h	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,4 +1,19 @@
-#ifndef PARSER_PARSEUTILITY_H
-#define PARSER_PARSEUTILITY_H
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// parseutility.h -- 
+//
+// Author           : Rodolfo G. Esteves
+// Created On       : Sat May 16 15:31:46 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 15:32:58 2015
+// Update Count     : 2
+//
+
+#ifndef PARSEUTILITY_H
+#define PARSEUTILITY_H
 
 #include "SynTree/SynTree.h"
@@ -6,3 +21,9 @@
 Expression *notZeroExpr( Expression *orig );
 
-#endif // PARSER_PARSEUTILITY_H
+#endif // PARSEUTILITY_H
+
+// Local Variables: //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
+// End: //
Index: translator/ResolvExpr/AlternativeFinder.cc
===================================================================
--- translator/ResolvExpr/AlternativeFinder.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/ResolvExpr/AlternativeFinder.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -25,6 +25,6 @@
 #include "utility.h"
 
-extern bool resolveVerbose;
-#define PRINT( text ) if ( resolveVerbose ) { text } 
+extern bool resolvep;
+#define PRINT( text ) if ( resolvep ) { text } 
 //#define DEBUG_COST
 
Index: translator/examples/Makefile.in
===================================================================
--- translator/examples/Makefile.in	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/examples/Makefile.in	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,4 +1,20 @@
+######################### -*- Mode: Makefile-Gmake -*- ########################
+##
+## Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+##
+## The contents of this file are covered under the licence agreement in the
+## file "LICENCE" distributed with Cforall.
+##
+## Makefile.in -- 
+##
+## Author           : Peter A. Buhr
+## Created On       : Sat May 16 11:34:24 2015
+## Last Modified By : Peter A. Buhr
+## Last Modified On : Sat May 16 11:35:25 2015
+## Update Count     : 2
+###############################################################################
+
 CC := @CFA_BINDIR@/cfa
-CFLAGS = -g -Wall -Wunused-function -MMD
+CFLAGS = -g -Wall -Wno-unused-function -MMD
 MAKEFILE_NAME = ${firstword ${MAKEFILE_LIST}}	# makefile name
 
Index: translator/main.cc
===================================================================
--- translator/main.cc	(revision b8508a2e1ff21bb4fcf257c21b8086694f961c08)
+++ translator/main.cc	(revision b87a5edee8b2aa6c36e184150ebd60baf4c64251)
@@ -1,7 +1,22 @@
+//
+// Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
+//
+// The contents of this file are covered under the licence agreement in the
+// file "LICENCE" distributed with Cforall.
+//
+// main.cc -- 
+//
+// Author           : Peter A. Buhr
+// Created On       : Fri May 15 23:12:02 2015
+// Last Modified By : Peter A. Buhr
+// Last Modified On : Sat May 16 07:42:27 2015
+// Update Count     : 8
+//
+
 #include <iostream>
 #include <fstream>
-#include <iterator>
-#include <algorithm>
+#include <cstdlib>
 #include <cstdio>
+#include <getopt.h>
 #include "Parser/Parser.h"
 #include "Parser/ParseNode.h"
@@ -31,5 +46,4 @@
 #include "SemanticError.h"
 #include "UnimplementedError.h"
-#include "utility.h"
 
 #include "../config.h"
@@ -37,333 +51,315 @@
 using namespace std;
 
-extern "C"{
-#include <unistd.h>
-} // extern
-
-FILE *open_prelude();
-FILE *open_builtins();
-bool beVerbose = false;
-bool resolveVerbose = false;
+bool
+	astp = false,
+	exprp = false,
+	expraltp = false,
+	grammarp = false,
+	libcfap = false,
+	resolvep = false,									// used in AlternativeFinder
+	symtabp = false,
+	parsep = false,
+	validp = false,
+	preludep = true,
+	protop = false,
+	codegenp = false,
+	errorp = false;
+
+enum { Ast, Expr, ExprAlt, Grammar, LibCFA, Nopreamble, Prototypes, Resolver, Symbol, Parse, };
+
+static struct option long_opts[] = {
+	{ "ast", no_argument, 0, Ast },
+	{ "expr", no_argument, 0, Expr },
+	{ "expralt", no_argument, 0, ExprAlt },
+	{ "grammar", no_argument, 0, Grammar },
+	{ "libcfa", no_argument, 0, LibCFA },
+	{ "nopreamble", no_argument, 0, Nopreamble },
+	{ "prototypes", no_argument, 0, Prototypes },
+	{ "resolver", no_argument, 0, Resolver },
+	{ "symbol", no_argument, 0, Symbol },
+	{ "parse", no_argument, 0, Parse },
+	{ 0, 0, 0, 0 }
+};
 
 int main( int argc, char *argv[] ) {
-    bool debugp = false, treep = false, astp = false, manglep = false, symtabp = false, validp = false;
-    bool preludep = true, protop = false, libp = false;
-    bool exprp = false, codegenp = false, errorp = false;
-    int c;
-    FILE *input, *prelude, *builtins;
-    std::ostream *output = &std::cout;
-
-    opterr = 0;
-
-    std::list< Declaration* > translationUnit;
-    
-    while ( (c = getopt( argc, argv, "dtsgmvxcenprlDyz:" )) != -1 ) {
-	switch (c) {
-	  case 'd':
-	    // bison debugging info
-	    debugp = true;
-	    break;
-	  case 't':
-	    // dump parse tree
-	    treep = true;
-	    break;
-	  case 's':
-	    // dump AST
-	    astp = true;
-	    break;
-	  case 'g':
-	    // print alternatives for expressions
-	    manglep = true;
-	    break;
-	  case 'm':
-	    // print symbol table events
-	    symtabp = true;
-	    break;
-	  case 'r':
-	    // print resolver steps
-	    resolveVerbose = true;
-	    break;
-	  case 'x':
-	    // dump AST after decl validation pass
-	    validp = true;
-	    break;
-	  case 'e':
-	    // dump AST after expression analysis
-	    exprp = true;
-	    break;
-          case 'z':
-            codegenp = true;
-            break;
-          case 'y':
-            errorp = true;
-            break;
-	  case 'n':
-	    // don't read preamble
-	    preludep = false;
-	    break;
-	  case 'p':
-	    // generate prototypes for preamble functions
-	    protop = true;
-	    break;
-	  case 'l':
-	    // generate libcfa.c
-	    libp = true;
-	    break;
-	  case 'v':
-	    // verbose
-	    beVerbose = true;
-	    break;
-	  case 'D':
-	    // ignore -Dxxx
-	    break;
-	  case '?':
-	    cout << "Unknown option: '" << (char)optopt << "'" << endl;
-	    exit(1);
-	  default:
-	    abort();
-	} // switch
-    } // while
-
-    try {
-	if ( optind < argc ) {
-	    input = fopen( argv[ optind ], "r" );
-	    if ( ! input ) {
-		std::cout << "Error: can't open " << argv[optind] << std::endl;
-		exit( 1 );
-	    } // if
-	    optind++;
-	} else {
-	    input = stdin;
-	} // if
-
-	if ( optind < argc ) {
-	    output = new ofstream( argv[ optind ] );
-	} // if
-    
-	Parser::get_parser().set_debug( debugp );
-    
-	if ( preludep ) {
-	    // include gcc builtins
-	    builtins = open_builtins();
-	    if ( !builtins ) {
-		std::cout << "Error: can't open builtins" << std::endl;
-		exit( 1 );
-	    } // if
-      
-	    Parser::get_parser().set_linkage( LinkageSpec::Compiler );
-	    Parser::get_parser().parse( builtins );
-    
-	    if ( Parser::get_parser().get_parseStatus() != 0 ) {
-		return Parser::get_parser().get_parseStatus();
-	    } // if
-	    fclose( builtins );
-
-	    // include cfa prelude
-	    if ( libp ) {
-		prelude = input;
-	    } else {
-		prelude = open_prelude();
-	    } // if
-	    if ( !prelude ) {
-		std::cout << "Error: can't open prelude" << std::endl;
-		exit( 1 );
-	    } // if
-      
-	    Parser::get_parser().set_linkage( LinkageSpec::Intrinsic );
-	    Parser::get_parser().parse( prelude );
-    
-	    if ( Parser::get_parser().get_parseStatus() != 0 ) {
-		return Parser::get_parser().get_parseStatus();
-	    } // if
-	    fclose( prelude );
-	} // if
-    
-	if ( libp ) {
-	    std::list< Declaration* > translationUnit;
-	    buildList( Parser::get_parser().get_parseTree(), translationUnit );
-	    Parser::get_parser().freeTree();
-	    SymTab::validate( translationUnit, false );
-	    CodeGen::fixNames( translationUnit );
-	    LibCfa::makeLibCfa( translationUnit );
-	    ResolvExpr::resolve( translationUnit );
-	    GenPoly::convertLvalue( translationUnit );
-	    GenPoly::box( translationUnit );
-	    CodeGen::generate( translationUnit, *output, true );
-	    if ( output != &std::cout ) {
-		delete output;
-	    } // if
-	    return 0;
-	} // if
-    
-	Parser::get_parser().set_linkage( LinkageSpec::Cforall );
+	FILE *input;
+	std::ostream *output = &std::cout;
+	int long_index;
+	std::list< Declaration* > translationUnit;
+
+	opterr = 0;											// prevent getopt from printing error messages
+	
+	int c;
+	while ( (c = getopt_long( argc, argv, "aefglnpqrsxyzD:", long_opts, &long_index )) != -1 ) {
+		switch ( c ) {
+		  case Ast:
+		  case 'a':										// dump AST
+			astp = true;
+			break;
+		  case Expr:
+		  case 'e':										// dump AST after expression analysis
+			exprp = true;
+			break;
+		  case ExprAlt:
+		  case 'f':										// print alternatives for expressions
+			expraltp = true;
+			break;
+		  case Grammar:
+		  case 'g':										// bison debugging info (grammar rules)
+			grammarp = true;
+			break;
+		  case LibCFA:
+		  case 'l':										// generate libcfa.c
+			libcfap = true;
+			break;
+		  case Nopreamble:
+		  case 'n':										// do not read preamble
+			preludep = false;
+			break;
+		  case Prototypes:
+		  case 'p':										// generate prototypes for preamble functions
+			protop = true;
+			break;
+		  case Parse:
+		  case 'q':										// dump parse tree
+			parsep = true;
+			break;
+		  case Resolver:
+		  case 'r':										// print resolver steps
+			resolvep = true;
+			break;
+		  case Symbol:
+		  case 's':										// print symbol table events
+			symtabp = true;
+			break;
+		  case 'x':										// dump AST after decl validation pass
+			validp = true;
+			break;
+		  case 'y':
+			errorp = true;
+			break;
+		  case 'z':
+			codegenp = true;
+			break;
+		  case 'D':										// ignore -Dxxx
+			break;
+		  case '?':
+			cout << "Unknown option: '" << (char)optopt << "'" << endl;
+			exit(1);
+		  default:
+			abort();
+		} // switch
+	} // while
+
+	try {
+		if ( optind < argc ) {
+			input = fopen( argv[ optind ], "r" );
+			if ( ! input ) {
+				std::cout << "Error: can't open " << argv[optind] << std::endl;
+				exit( 1 );
+			} // if
+			optind += 1;
+		} else {
+			input = stdin;
+		} // if
+
+		if ( optind < argc ) {
+			output = new ofstream( argv[ optind ] );
+		} // if
+	
+		Parser::get_parser().set_debug( grammarp );
+	
+		if ( preludep ) {								// include gcc builtins
+			FILE *builtins = fopen( CFA_LIBDIR "/builtins.cf", "r" );
+			if ( builtins == NULL ) {
+				std::cout << "Error: can't open builtins" << std::endl;
+				exit( 1 );
+			} // if
+	  
+			Parser::get_parser().set_linkage( LinkageSpec::Compiler );
+			Parser::get_parser().parse( builtins );
+	
+			if ( Parser::get_parser().get_parseStatus() != 0 ) {
+				return Parser::get_parser().get_parseStatus();
+			} // if
+			fclose( builtins );
+
+			FILE *prelude;
+			if ( libcfap ) {							// include cfa prelude
+				prelude = input;
+			} else {
+				prelude = fopen( CFA_LIBDIR "/prelude.cf", "r" );
+			} // if
+			if ( prelude == NULL ) {
+				std::cout << "Error: can't open prelude" << std::endl;
+				exit( 1 );
+			} // if
+	  
+			Parser::get_parser().set_linkage( LinkageSpec::Intrinsic );
+			Parser::get_parser().parse( prelude );
+	
+			if ( Parser::get_parser().get_parseStatus() != 0 ) {
+				return Parser::get_parser().get_parseStatus();
+			} // if
+			fclose( prelude );
+		} // if
+	
+		if ( libcfap ) {
+			std::list< Declaration* > translationUnit;
+			buildList( Parser::get_parser().get_parseTree(), translationUnit );
+			Parser::get_parser().freeTree();
+			SymTab::validate( translationUnit, false );
+			CodeGen::fixNames( translationUnit );
+			LibCfa::makeLibCfa( translationUnit );
+			ResolvExpr::resolve( translationUnit );
+			GenPoly::convertLvalue( translationUnit );
+			GenPoly::box( translationUnit );
+			CodeGen::generate( translationUnit, *output, true );
+			if ( output != &std::cout ) {
+				delete output;
+			} // if
+			return 0;
+		} // if
+	
+		Parser::get_parser().set_linkage( LinkageSpec::Cforall );
   
-	Parser::get_parser().parse( input );
-	if ( debugp || Parser::get_parser().get_parseStatus() != 0 ) {
-	    return Parser::get_parser().get_parseStatus();
-	} // if
-	fclose( input );
+		Parser::get_parser().parse( input );
+		if ( grammarp || Parser::get_parser().get_parseStatus() != 0 ) {
+			return Parser::get_parser().get_parseStatus();
+		} // if
+		fclose( input );
   
-	if ( treep ) {
-	    Parser::get_parser().get_parseTree()->printList( std::cout );
-	    Parser::get_parser().freeTree();
-	    return 0;
-	} // if
-
-	buildList( Parser::get_parser().get_parseTree(), translationUnit );
-
-	Parser::get_parser().freeTree();
-	if ( astp ) {
-	    printAll( translationUnit, std::cout );
-	    return 0;
-	} // if
-
-	if ( manglep ) {
-	    SymTab::validate( translationUnit, false );
-	    ResolvExpr::AlternativePrinter printer( std::cout );
-	    acceptAll( translationUnit, printer );
-	    return 0;
-	} // if
-
-	if ( symtabp ) {
-	    SymTab::validate( translationUnit, true );
-	    return 0;
-	} // if
-
-	if ( validp ) {
-	    SymTab::validate( translationUnit, false );
-	    printAll( translationUnit, std::cout );
-	    return 0;
-	} // if
-
-	if ( exprp ) {
- 	    InitTweak::tweak( translationUnit );
-	    SymTab::validate( translationUnit, false );
-            ControlStruct::mutate( translationUnit );
-            CodeGen::fixNames( translationUnit );
- 	    ResolvExpr::resolve( translationUnit );
-	    printAll( translationUnit, std::cout );
-	    return 0;
-	} // if
-
-	if ( codegenp ) {
-            // print the tree right before code generation
- 	    cerr << "tweak" << endl;
- 	    InitTweak::tweak( translationUnit );
-            cerr << "validate" << endl;
-            SymTab::validate( translationUnit, false );
-            cerr << "mutate" << endl;
-            ControlStruct::mutate( translationUnit );
-            cerr << "fixNames" << endl;
-            CodeGen::fixNames( translationUnit );
-            cerr << "resolve" << endl;
-            ResolvExpr::resolve( translationUnit );
-            cerr << "copyParams" << endl;
-            GenPoly::copyParams( translationUnit );
-            cerr << "convertSpecializations" << endl;
-            GenPoly::convertSpecializations( translationUnit );
-            cerr << "convertLvalue" << endl;
-            GenPoly::convertLvalue( translationUnit );
-            cerr << "box" << endl;
-            GenPoly::box( translationUnit );
-            if ( errorp ) {
-                printAll( translationUnit, std::cout );
-            }
-            return 0;
-        } // if
-
-	// add the assignment statement after the 
-	// initialization of a type parameter
-	InitTweak::tweak( translationUnit );
-
-	//std::cerr << "before validate" << std::endl;
-	SymTab::validate( translationUnit, false );
-	//Try::visit( translationUnit );
-	//Tuples::mutate( translationUnit );
-	//InitTweak::mutate( translationUnit );
-	//std::cerr << "before mutate" << std::endl;
-	ControlStruct::mutate( translationUnit );
-	//std::cerr << "before fixNames" << std::endl;
-	CodeGen::fixNames( translationUnit );
-	//std::cerr << "before resolve" << std::endl;
-	ResolvExpr::resolve( translationUnit );
-	//Tuples::checkFunctions( translationUnit );
-	//      std::cerr << "Finished tuple checkfunctions" << std::endl;
-	//printAll( translationUnit, std::cerr );
-	//std::cerr << "before copyParams" << std::endl;
-	GenPoly::copyParams( translationUnit );
-	//std::cerr << "before convertSpecializations" << std::endl;
-	GenPoly::convertSpecializations( translationUnit );
-	//std::cerr << "before convertLvalue" << std::endl;
-	GenPoly::convertLvalue( translationUnit );
-	//std::cerr << "before box" << std::endl;
-	GenPoly::box( translationUnit );
-	//Tuples::mutate( translationUnit );
-
-	CodeGen::generate( translationUnit, *output, protop );
-
-	if ( output != &std::cout ) {
-	    delete output;
-	} // if
-
-    } catch ( SemanticError &e ) {
-    	if ( errorp ) {
-           printAll( translationUnit, std::cout );
-    	}
-	e.print( cout );
-	if ( output != &std::cout ) {
-	    delete output;
-	} // if
-	return 1;
-    } catch ( UnimplementedError &e ) {
-	std::cout << "Sorry, " << e.get_what() << " is not currently implemented" << std::endl;
-	if ( output != &std::cout ) {
-	    delete output;
-	} // if
-	return 1;
-    } catch ( CompilerError &e ) {
-	std::cerr << "Compiler Error: " << e.get_what() << std::endl;
-	std::cerr << "(please report bugs to " << std::endl;
-	if ( output != &std::cout ) {
-	    delete output;
-	} // if
-	return 1;
-    } // try
-
-    return 0;
+		if ( parsep ) {
+			Parser::get_parser().get_parseTree()->printList( std::cout );
+			Parser::get_parser().freeTree();
+			return 0;
+		} // if
+
+		buildList( Parser::get_parser().get_parseTree(), translationUnit );
+
+		Parser::get_parser().freeTree();
+		if ( astp ) {
+			printAll( translationUnit, std::cout );
+			return 0;
+		} // if
+
+		if ( expraltp ) {
+			SymTab::validate( translationUnit, false );
+			ResolvExpr::AlternativePrinter printer( std::cout );
+			acceptAll( translationUnit, printer );
+			return 0;
+		} // if
+
+		if ( symtabp ) {
+			SymTab::validate( translationUnit, true );
+			return 0;
+		} // if
+
+		if ( validp ) {
+			SymTab::validate( translationUnit, false );
+			printAll( translationUnit, std::cout );
+			return 0;
+		} // if
+
+		if ( exprp ) {
+			InitTweak::tweak( translationUnit );
+			SymTab::validate( translationUnit, false );
+			ControlStruct::mutate( translationUnit );
+			CodeGen::fixNames( translationUnit );
+			ResolvExpr::resolve( translationUnit );
+			printAll( translationUnit, std::cout );
+			return 0;
+		} // if
+
+		if ( codegenp ) {
+			// print the tree right before code generation
+			cerr << "tweak" << endl;
+			InitTweak::tweak( translationUnit );
+			cerr << "validate" << endl;
+			SymTab::validate( translationUnit, false );
+			cerr << "mutate" << endl;
+			ControlStruct::mutate( translationUnit );
+			cerr << "fixNames" << endl;
+			CodeGen::fixNames( translationUnit );
+			cerr << "resolve" << endl;
+			ResolvExpr::resolve( translationUnit );
+			cerr << "copyParams" << endl;
+			GenPoly::copyParams( translationUnit );
+			cerr << "convertSpecializations" << endl;
+			GenPoly::convertSpecializations( translationUnit );
+			cerr << "convertLvalue" << endl;
+			GenPoly::convertLvalue( translationUnit );
+			cerr << "box" << endl;
+			GenPoly::box( translationUnit );
+			if ( errorp ) {
+				printAll( translationUnit, std::cout );
+			}
+			return 0;
+		} // if
+
+		// add the assignment statement after the 
+		// initialization of a type parameter
+		InitTweak::tweak( translationUnit );
+
+		//std::cerr << "before validate" << std::endl;
+		SymTab::validate( translationUnit, false );
+		//Try::visit( translationUnit );
+		//Tuples::mutate( translationUnit );
+		//InitTweak::mutate( translationUnit );
+		//std::cerr << "before mutate" << std::endl;
+		ControlStruct::mutate( translationUnit );
+		//std::cerr << "before fixNames" << std::endl;
+		CodeGen::fixNames( translationUnit );
+		//std::cerr << "before resolve" << std::endl;
+		ResolvExpr::resolve( translationUnit );
+		//Tuples::checkFunctions( translationUnit );
+		//	  std::cerr << "Finished tuple checkfunctions" << std::endl;
+		//printAll( translationUnit, std::cerr );
+		//std::cerr << "before copyParams" << std::endl;
+		GenPoly::copyParams( translationUnit );
+		//std::cerr << "before convertSpecializations" << std::endl;
+		GenPoly::convertSpecializations( translationUnit );
+		//std::cerr << "before convertLvalue" << std::endl;
+		GenPoly::convertLvalue( translationUnit );
+		//std::cerr << "before box" << std::endl;
+		GenPoly::box( translationUnit );
+		//Tuples::mutate( translationUnit );
+
+		CodeGen::generate( translationUnit, *output, protop );
+
+		if ( output != &std::cout ) {
+			delete output;
+		} // if
+
+	} catch ( SemanticError &e ) {
+		if ( errorp ) {
+			printAll( translationUnit, std::cout );
+		}
+		e.print( cout );
+		if ( output != &std::cout ) {
+			delete output;
+		} // if
+		return 1;
+	} catch ( UnimplementedError &e ) {
+		std::cout << "Sorry, " << e.get_what() << " is not currently implemented" << std::endl;
+		if ( output != &std::cout ) {
+			delete output;
+		} // if
+		return 1;
+	} catch ( CompilerError &e ) {
+		std::cerr << "Compiler Error: " << e.get_what() << std::endl;
+		std::cerr << "(please report bugs to " << std::endl;
+		if ( output != &std::cout ) {
+			delete output;
+		} // if
+		return 1;
+	} // try
+
+	return 0;
 } // main
 
-FILE *open_prelude() {
-    FILE *ret;
-
-    const string name("prelude.cf"),
-	full_name = string(CFA_LIBDIR) + "/" + name;
-
-    if ( beVerbose ) {
-	cout << "Reading from " << full_name << endl;
-    } // if
-
-    if ( ! (ret = fopen(full_name.c_str(), "r" ) ) )
-	return fopen(name.c_str(), "r" );             // trying current directory
-    else
-	return ret;
-} // open_prelude
-
-FILE *open_builtins() {
-    FILE *ret;
-
-    const char *name = "builtins.cf";
-    const char *full_name = CFA_LIBDIR "/builtins.cf";
-
-    if ( beVerbose ) {
-	cout << "Reading from " << full_name << endl;
-    } // if
-
-    if ( ! (ret = fopen(full_name, "r" ) ) )
-	return fopen(name, "r" );			// trying current directory
-    else
-	return ret;
-} // open_builtins
-
 // Local Variables: //
-// compile-command: "make" //
+// tab-width: 4 //
+// mode: c++ //
+// compile-command: "make install" //
 // End:  //
