emacs.d/clones/lisp/www.cliki.net/Issue PRINTING-ARRAYS-READABLY.html
2022-10-07 15:47:14 +02:00

81 lines
No EOL
5.5 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>CLiki: Issue PRINTING-ARRAYS-READABLY</title>
<link rel="alternate" type="application/atom+xml" title="ATOM feed of edits to current article"
href="https://www.cliki.net/site/feed/article.atom?title=Issue%20PRINTING-ARRAYS-READABLY">
<link rel="stylesheet" href="static/css/style.css">
<link rel="stylesheet" href="static/css/colorize.css">
</head>
<body>
<span class="hidden">CLiki - Issue PRINTING-ARRAYS-READABLY</span>
<div id="content"><div id="content-area"><div id="article-title">Issue PRINTING-ARRAYS-READABLY</div><div id="article"><a href="Issue.html" class="category">Issue</a>: PRINTING-ARRAYS-READABLY<p>Forum: Editorial<p>References: <a href="https://www.cliki.net/site/HyperSpec/Body/var_stprint-readablyst.html" class="hyperspec">*PRINT-READABLY*</a>, <a href="https://www.cliki.net/site/HyperSpec/Body/sec_22-1-3-7.html">CLHS 22.1.3.7</a>, <a href="https://www.cliki.net/site/HyperSpec/Body/sec_22-1-3-8.html">CLHS 22.1.3.8</a><p>Category: CLARIFICATION/CHANGE<p>Edit history: 2004-07-20, Version 1 by Bruno Haible<p>Status: For CLiki consideration<p><dl>
<dt>Problem Description:<p></dt>
<dd>The description of <a href="https://www.cliki.net/site/HyperSpec/Body/var_stprint-readablyst.html" class="hyperspec">*PRINT-READABLY*</a> says that throwing a <a href="https://www.cliki.net/site/HyperSpec/Body/contyp_print-not-readable.html" class="hyperspec">PRINT-NOT-READABLE</a> error is allowed for certain arrays. <a href="http://www.cliki.net/site/HyperSpec/Body/sec_22-1-3-7.html">CLHS 22.1.3.7</a> seems to imply that no error is allowed. This should probably be clarified one way or the other.<p></dd>
<dt>Proposal (PRINTING-ARRAYS-READABLY:NO-ERROR):<p></dt>
<dd>Add a sentence to 22.1.3.7: "If *print-readably* is true ... Any vector can be printed readably without signaling an error of type PRINT-NOT-READABLE if all its elements can be printed readably without signaling an error of type PRINT-NOT-READABLE."
And similarly to 22.1.3.8: "If *print-readably* is true ... Any array can be printed readably without signaling an error of type PRINT-NOT-READABLE if all its elements can be printed readably without signaling an error of type PRINT-NOT-READABLE."<p></dd>
<dt>Test case:<p></dt>
<dd>(write (make-array '(3 0 5) :element-type '(unsigned-byte 8)) :readably t)<p></dd>
<dt>Rationale:<p></dt>
<dd>The implementation should ensure that it can print arrays readably.<p></dd>
<dt>Current practice:<p></dt>
<dd>
<a href="CLISP.html" class="internal">CLISP</a> supports proposal NO-ERROR. <a href="SBCL.html" class="internal">SBCL</a> doesn't.<p></dd>
<dt>Cost to Implementors:<p></dt>
<dd>Define a way to print arrays readably, including when the element-type is not t, or when one of the dimensions is 0.<p></dd>
<dt>Cost to Users:<p></dt>
<dd>None.<p></dd>
<dt>Cost of Non-Adoption:<p></dt>
<dd>
<a href="https://www.cliki.net/site/HyperSpec/Body/var_stprint-readablyst.html" class="hyperspec">*PRINT-READABLY*</a> is less useful.<p></dd>
<dt>Benefits:<p></dt>
<dd>Makes <a href="https://www.cliki.net/site/HyperSpec/Body/var_stprint-readablyst.html" class="hyperspec">*PRINT-READABLY*</a> more useful.<p></dd>
<dt>Aesthetics:<p><dt>Discussion:
</dt>
</dt>
<dd>
<ul>
<li>Bruno Haible supports proposal NO-ERROR.
</li>
</ul><p></dd>
</dl></div></div>
<div id="footer" class="buttonbar"><ul><li><a href="Issue&#32;PRINTING-ARRAYS-READABLY.html">Current version</a></li>
<li><a href="https://www.cliki.net/site/history?article=Issue%20PRINTING-ARRAYS-READABLY">History</a></li>
<li><a href="https://www.cliki.net/site/backlinks?article=Issue%20PRINTING-ARRAYS-READABLY">Backlinks</a></li><li><a href="https://www.cliki.net/site/edit-article?title=Issue%20PRINTING-ARRAYS-READABLY&amp;from-revision=3770933923">Edit</a></li><li><a href="https://www.cliki.net/site/edit-article?create=t">Create</a></li></ul></div>
</div>
<div id="header-buttons" class="buttonbar">
<ul>
<li><a href="https://www.cliki.net/">Home</a></li>
<li><a href="https://www.cliki.net/site/recent-changes">Recent Changes</a></li>
<li><a href="CLiki.html">About</a></li>
<li><a href="Text&#32;Formatting.html">Text Formatting</a></li>
<li><a href="https://www.cliki.net/site/tools">Tools</a></li>
</ul>
<div id="search">
<form action="https://www.cliki.net/site/search">
<label for="search_query" class="hidden">Search CLiki</label>
<input type="text" name="query" id="search_query" value="" />
<input type="submit" value="search" />
</form>
</div>
</div>
<div id="pageheader">
<div id="header">
<span id="logo">CLiki</span>
<span id="slogan">the common lisp wiki</span>
<div id="login"><form method="post" action="https://www.cliki.net/site/login">
<label for="login_name" class="hidden">Account name</label>
<input type="text" name="name" id="login_name" class="login_input" />
<label for= "login_password" class="hidden">Password</label>
<input type="password" name="password" id="login_password" class="login_input" />
<input type="submit" name="login" value="login" id="login_submit" /><br />
<div id="register"><a href="https://www.cliki.net/site/register">register</a></div>
<input type="submit" name="reset-pw" value="reset password" id="reset_pw" />
</form>
</div>
</div>
</div>
</body></html>