guile-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Patch for ice-9/format.scm (~&)


From: Marius Vollmer
Subject: Re: Patch for ice-9/format.scm (~&)
Date: 14 Jun 2001 17:07:42 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.0.102

Matthias Koeppe <address@hidden> writes:

> In CL, ~& outputs a new line if the port column cannot be
> determined.

Ok.
 
> I believe we should make format behaviour predictable and free of
> side-effects (and thread-safe).  That is, if no port columns are
> available, don't even attempt to maintain columns across format calls
> because the attempt will cause cryptic behavior in the cases described
> above.

Yes, agreed.  Should we keep columns within one call to format?  The
column is needed for ~& and for ~T, tabulate.  CL encourages format to
deduce the column count, just as our format does now, so I think we
should keep doing that, but maybe only when the ports doesn't do it
for us.  However, format:out-str fails when outputting a string that
contains newlines.

> For thread-safeness we would need to get rid of the global format
> variables and replace them with fluids or one structure passed between
> all the internal procedures.

I'd prefer a common structure.

> BTW: Can it really happen in Guile that port columns are not
> available, i.e. port-column returns #f?  Before my port-column
> patch, output ports would return 0 all the time...

I don't know.  If possible, we should fix the ones who don't play
nice.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]