Index: src/Common/Eval.cc
===================================================================
--- src/Common/Eval.cc	(revision 83b52f10c32ca12f8f96a9532884e06dd2d083dd)
+++ src/Common/Eval.cc	(revision 77d24328ac45a6a1b577a385f5aa9b046e17a1ee)
@@ -10,6 +10,6 @@
 // Created On       : Mon May 18 07:44:20 2015
 // Last Modified By : Peter A. Buhr
-// Last Modified On : Sun May  6 22:24:16 2018
-// Update Count     : 40
+// Last Modified On : Wed Jul 24 15:09:06 2019
+// Update Count     : 64
 //
 
@@ -27,12 +27,15 @@
 	bool valid = true;
 
-	void previsit( BaseSyntaxNode * ) { visit_children = false; }
-	void postvisit( BaseSyntaxNode * ) { valid = false; }
+	void previsit( const BaseSyntaxNode * ) { visit_children = false; }
+	void postvisit( const BaseSyntaxNode * ) { valid = false; }
 
-	void postvisit( ConstantExpr * expr ) {
+	void postvisit( const SizeofExpr * ) {
+	}
+
+	void postvisit( const ConstantExpr * expr ) {
 		value = expr->intValue();
 	}
 
-	void postvisit( CastExpr * expr ) {
+	void postvisit( const CastExpr * expr ) {
 		auto arg = eval(expr->arg);
 		valid = arg.second;
@@ -41,5 +44,5 @@
 	}
 
-	void postvisit( VariableExpr * expr ) {
+	void postvisit( const VariableExpr * const expr ) {
 		if ( EnumInstType * inst = dynamic_cast<EnumInstType *>(expr->result) ) {
 			if ( EnumDecl * decl = inst->baseEnum ) {
@@ -52,6 +55,6 @@
 	}
 
-	void postvisit( ApplicationExpr * expr ) {
-		DeclarationWithType * function = InitTweak::getFunction(expr);
+	void postvisit( const ApplicationExpr * expr ) {
+		DeclarationWithType * function = InitTweak::getFunction(const_cast<ApplicationExpr *>(expr));
 		if ( ! function || function->linkage != LinkageSpec::Intrinsic ) { valid = false; return; }
 		const std::string & fname = function->name;
@@ -94,4 +97,10 @@
 	void postvisit( const ast::ConstantExpr * expr ) {
 		value = expr->intValue();
+	}
+
+	void postvisit( const ast::SizeofExpr * expr ) {
+		if ( expr->expr ) value = eval(expr->expr).first;
+		else if ( expr->type ) value = eval(expr->expr).first;
+		else SemanticError( expr->location, ::toString( "Internal error: SizeofExpr has no expression or type value" ) );
 	}
 
@@ -145,5 +154,5 @@
 };
 
-std::pair<long long int, bool> eval(Expression * expr) {
+std::pair<long long int, bool> eval( const Expression * expr) {
 	PassVisitor<EvalOld> ev;
 	if (expr) {
Index: src/Common/utility.h
===================================================================
--- src/Common/utility.h	(revision 83b52f10c32ca12f8f96a9532884e06dd2d083dd)
+++ src/Common/utility.h	(revision 77d24328ac45a6a1b577a385f5aa9b046e17a1ee)
@@ -10,6 +10,6 @@
 // Created On       : Mon May 18 07:44:20 2015
 // Last Modified By : Peter A. Buhr
-// Last Modified On : Sun May  6 22:24:16 2018
-// Update Count     : 40
+// Last Modified On : Wed Jul 24 14:28:19 2019
+// Update Count     : 41
 //
 
@@ -483,5 +483,5 @@
 // -----------------------------------------------------------------------------
 /// evaluates expr as a long long int. If second is false, expr could not be evaluated
-std::pair<long long int, bool> eval(Expression * expr);
+std::pair<long long int, bool> eval(const Expression * expr);
 
 namespace ast {
