[prettyprint] r595 committed - Fix errors flagged by newer compilers.

0 views
Skip to first unread message

prett...@googlecode.com

unread,
Dec 30, 2012, 12:48:40 PM12/30/12
to pp-d...@googlegroups.com
Revision: 595
Author: thockin
Date: Sun Dec 30 09:48:21 2012
Log: Fix errors flagged by newer compilers.


http://code.google.com/p/prettyprint/source/detail?r=595

Modified:
/trunk/README
/trunk/language/syntax_tree.h
/trunk/language/type.cpp

=======================================
--- /trunk/README Tue Jul 29 23:00:11 2008
+++ /trunk/README Sun Dec 30 09:48:21 2012
@@ -6,6 +6,9 @@
Requirements:

To build this you will need several libraries:
+ - flex and bison
+ These should not be hard to get for just about any distro.
+
- gmp and gmpxx version 4.2.1 or higher
Apparently, ubuntu-dapper does not have official packages
that meet this requirement. I have rebuilt the ubuntu-edgy
=======================================
--- /trunk/language/syntax_tree.h Wed Dec 15 14:03:40 2010
+++ /trunk/language/syntax_tree.h Sun Dec 30 09:48:21 2012
@@ -223,7 +223,7 @@
public:
explicit
Statement(const Parser::Position &pos)
- : SyntaxNode(pos, NODE_TYPE_STATEMENT), m_labels(NULL)
+ : SyntaxNode(pos, NODE_TYPE_STATEMENT), m_labels()
{
}
virtual
=======================================
--- /trunk/language/type.cpp Tue Jul 6 21:00:55 2010
+++ /trunk/language/type.cpp Sun Dec 30 09:48:21 2012
@@ -90,6 +90,7 @@
case Type::TUPLE:
return INT_MAX;
}
+ throw Type::UnknownError(sprintfxx("unknown type (%d)", prim));
}

string
@@ -106,7 +107,7 @@
case TUPLE: return "tuple";
case VAR: return "var";
}
- return "(this can not happen)";
+ throw Type::UnknownError(sprintfxx("unknown type (%d)", prim));
}

string
Reply all
Reply to author
Forward
0 new messages