[pure-lang-svn] SF.net SVN: pure-lang:[729] pure/trunk/printer.cc
Status: Beta
Brought to you by:
agraef
From: <ag...@us...> - 2008-09-06 16:59:39
|
Revision: 729 http://pure-lang.svn.sourceforge.net/pure-lang/?rev=729&view=rev Author: agraef Date: 2008-09-06 16:59:50 +0000 (Sat, 06 Sep 2008) Log Message: ----------- Bugfixes. Modified Paths: -------------- pure/trunk/printer.cc Modified: pure/trunk/printer.cc =================================================================== --- pure/trunk/printer.cc 2008-09-06 15:00:35 UTC (rev 728) +++ pure/trunk/printer.cc 2008-09-06 16:59:50 UTC (rev 729) @@ -625,7 +625,12 @@ static inline bool pstr(ostream& os, pure_expr *x) { static bool recursive = false; - if (recursive) return false; + if (recursive || + // We don't want to force a thunk here. Unfortunately, this means that + // currently you can't define a print representation for a thunk, at + // least not directly. :( + x->tag == 0 && x->data.clos && x->data.clos->n == 0) + return false; interpreter& interp = *interpreter::g_interp; int32_t f = interp.symtab.__show__sym; if (f > 0 && interp.globenv.find(f) != interp.globenv.end()) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |