[ prog / sol / mona ]

prog


CLHS

1 2020-06-13 20:09

When I was starting to get into Lisp, the Common Lisp Hyper Spec (CLHS) was quite confusing. The formatting is off, much of the navigation is implemented using images, and despite the sites being packed, it was hard to find what one wanted to know. I have got used to it since, it is still kind of sad that one of the canonical references of the Lisp "community" is a non-free, not even any Creative Commons document, that cannot be updated or maintained by said users. It would be great if it could be redistributed as a SLIME package or as an Info document, but as it says "Copyright 1996-2005, LispWorks Ltd. All rights reserved." at the bottom of the page, it's not possible.

Sadly most alternatives I know of aren't as expansive. So has there ever been a push to get LispWorks to release the HyperSpec into some kind of a public domain/CC-BY-whatever state? If not, is it even feasible? Does anyone here know any details on it's history?

2 2020-06-15 00:27

>>1

So has there ever been a push to get LispWorks to release the HyperSpec into some kind of a public domain/CC-BY-whatever state? If not, is it even feasible? Does anyone here know any details on it's history?

I have no answer but this is relevant to my interests. At first glance it's hardly feasible.

http://www.lispworks.com/documentation/HyperSpec/Front/Help.htm#Legal

Permissions related to performance and to creation of derivative works are expressly NOT granted.

Permission to make partial copies is expressly NOT granted, EXCEPT that limited permission is granted to transmit and display a partial copy the Common Lisp HyperSpec for the ordinary purpose of direct viewing by a human being in the usual manner that hypertext browsers permit the viewing of such a complete document, provided that no recopying, redistribution, redisplay, or retransmission is made of any such partial copy.

Permission to make modified copies is expressly NOT granted.
Permission to add or replace any links or any graphical images to any of these pages is expressly NOT granted.
Permission to use any of the included graphical (GIF) images in any document other than the Common Lisp HyperSpec is expressly NOT granted.

3 2020-06-15 09:32

>>2
As far as I see, you can't distribute modified copies, but you could write a program that generates a modified copy, right? And then distribute this program.

4 2020-06-15 16:10

>>3
It seems far-fetched as a loophole. You'll probably have to wait for LispWorks to go bankrupt.

5 2020-06-17 19:23

>>1
I'm a Schemer but I heard some folks prefer the standard to Hyperspec and I found the following Texinfo conversion, with an additional conversion mentioned in the README: https://github.com/rebcabin/dpans2texi

6 2020-07-28 15:04

>>1
>>5

tldr: CLHS was programmatically generated from public domain standard, and it's the result of that work ("html code") that's copyrighted. CLHS and the standard are otherwise near identical and anyone can take the standard and produce their own html reference. CLHS is the oldest such effort, the copyright is permissive enough, that nobody has bothered to.

so the history behind CLHS is explained by Kent Pitman, the editor of the spec and the person who made Hyperspec https://nhplace.com/kent/Papers/cl-untold-story.html (starting at 6.2)

The standard committee produced several drafts of the spec, the copyright of the drafts was never transferred to ANSI, and the committee's explicit mandate was that the spec will be available to all interested parties to do with as they please. It's not clear who owns the copyright on the spec, but it's intentionally obscured so that nobody can claim it. I guess the most likely claimant is Kent Pitman, but he himself says that he was doing work for hire for an entity that doesn't exist.

Three draft proposed American National Standards (dpANS) were subsequently produced. dpANS 1 was a working draft and received extensive review and revision by X3J13. dpANS 2 was then created to resolve all remaining technical issues; X3J13 made no intentional changes in technical content after dpANS 2. dpANS 3 improved wording in a few places and extensively reworked the Credits section, not a normative part of the standard. Further formatting changes and boilerplate additions were executed by ANSI in their process of producing the standard, but these have no technical implications.

dpANS3 was shared freely to all interested parties. and while only published ANSI Standard is considered to be a definitive reference (and not hyperspec!), according to Franz's blurb above the only changes between dpans3 and the standard are cosmetic.

Later Kent Pitman while still working at Harlequin (which became Lispworks) programmatically converted dpANS to html, and Harlequin/Lispworks own copyright on that effort. Because they distributed it freely and were the first ones to produce it, it was also the most widely used standard equivalent. Franz has their own version of the conversion, https://franz.com/support/documentation/current/ansicl/ansicl.htm which is (c) franz inc. They explain the details here https://franz.com/search/search-ansi-about.lhtml which is also where I got the blurb above. Compare for example a random page of Hyperspec http://www.lispworks.com/documentation/HyperSpec/Body/03_bd.htm and corresponding Franz's section https://franz.com/support/documentation/current/ansicl/subsecti/literalo.htm

So Hyperspec, dpANS, and ANSI spec are all identical: same chapters, same form descriptions, same examples, etc. etc. Hyperspec is "copyrighted" Lispworks, dpANS is public domain, and ANSI spec is "copyrighted" ANSI.

You can grab dpANS from here https://github.com/xach/dpans. It's written in TeX using custom macro definitions. There is pdf of its output https://franz.com/support/documentation/cl-ansi-standard-draft-w-sidebar.pdf (NOT copyrighted franz). There is a custom parser for it https://github.com/robert-strandh/dpANS-parser, a converter to Texinfo https://github.com/rebcabin/dpans2texi and I believe there was an effort to do a "modernized" pdf by hacking up dpANS macros a little bit, but I can't seem to find it.

7 2020-07-30 23:27

>>1

For navigation it really helps to download [1] the hyperspec and write a script that looks up a symbol in the symbol index which is the most common use case. For example Data/Map_Sym.txt can be parsed for that purpose.

[1]: ftp://ftp.lispworks.com/pub/software_tools/reference/HyperSpec-7-0.tar.gz

8 2020-07-31 03:36

>>7 there's already hyperspec.el for emacs, that can be poached for the mapping. there's both a version for modern hyperspec (with truncated, windows friendly filenames) which is included with SLIME, and the original one that uses unix files http://naggum.no/emacs/hyperspec.el

9 2020-07-31 12:32

>>8

;; if only we had had packages or hash tables..., but let's fake it.

Didn't know that hash tables in Elisp aren't even 20-something years old.

10 2020-07-31 13:14

>>9
What's funny is how slow the hash tables still are alists with a symbol as a key still outperform them for less than two hundred elements, and the performance doesn't get much better after that. I imagine that with emacs native this would change rather dramatically however.

11 2020-07-31 16:52

>>9
They were first included in Emacs 21.1, in 2001. If you are interested in the history of Emacs Lisp, this is a pretty nice and comprehensive paper on the topic: https://dl.acm.org/doi/abs/10.1145/3386324

12 2020-08-06 09:30

What would be really nice, was a lisp implementation with some kind of HyperSpec / Standard integration in the documentation function. I find that the output of that (in SBCL at least) is hardly useful enough for what you are trying to find out although it is a great feature.

13 2020-08-06 16:18

>>12 the unfortunate aspect of "common" in common lisp is that a lot of existing functionality was left behind, because each vendor already had some kind of elaborate, incompatible in details but similar in spirit solution to various IDE problems. genera's repl for example allowed you to enter human readable commands in addition to lisp code. one of such commands is Show Documentation, which would pull formatted docs for pretty much anything in the system, and dump them straight in the repl. i think texinfo's original intent was to support something like that on an emacs machine, and i believe there's already enough tooling to make emacs give you texinfo documentation for a symbol at point.

14 2020-08-07 13:16

>>13
It’s a real shame that none of the Common Lisp implementations of Emacs ever really caught on. It’s pretty easy to imagine a Hemlock decendent, or similar project being a pretty exceptional development environment.

15 2020-08-10 02:06 *

>>14 i've used hemlock fulltime for a year. the unsatisfying aspect of the "emacs" paradigm is that the original lisp machines didn't really have everything living inside the editor. editor was just another, smart, widget that you could integrate into programs. hemlock makes it obvious: typeout, exception handling, various lisp integration features are better off living outside, but there's no framework to support this outside. mcclim and friends is simultaneously anemic compared to the real deal, and over engineered. emacs to some extent is the ultimate worse is better slap in the face: it even at being good enough lisp machine because it's such a hack.

16 2020-08-10 13:03 *

>>15
I've certainly noticed that GNU Emacs is one big hack, the more you embrace it the more painfully obvious this is. I was also aware that ZEmacs was just an application for Lisp Machines. Your comments really tell me that I should take the time to research McCLIM, and gain a better understanding of Lisp Machines overall though.

17 2022-04-14 02:34

If you don't need the complete standard, the quick reference should serve you as well as it did me.
http://clqr.boundp.org/

18 2022-04-14 06:39

>>1
If you do not like the HyperSpec, you could use a PDF of the last draft of the Common Lisp standard instead: https://franz.com/support/documentation/cl-ansi-standard-draft-w-sidebar.pdf

That PDF comes from this project: https://gitlab.com/vancan1ty/clstandard_build

19 2022-04-14 09:24

>>17
I find the quick reference to be very helpful when trying to get an overview over a group of functions or some topic like the type system, the loop macro, etc. As such I have it printed out next to my desk, in form of a A4/2 booklet. But eventually you have to fall back to the Hyperspec or something else (since at least to my knowledge SLIME cannot provide sensible online documentation), when having to deal with the details or edge-cases.

20 2022-05-01 15:40

There's also the Simplified Common Lisp reference https://jtra.cz/stuff/lisp/sclr/index.html

21 2022-05-09 15:44

>>1

it was hard to find what one wanted to know

When using the HyperSpec as a reference, I tend to use the Alphabetical Symbol Index (Front/X_AllSym.htm) and the Non-Aphabetical Index (Front/X_Mast_9.htm) to find the parts I want to read.

22 2022-05-17 08:40

>>1

it is still kind of sad that one of the canonical references of the Lisp "community" is a non-free, not even any Creative Commons document, that cannot be updated or maintained by said users.

You could use the last draft of the ANSI Common Lisp standard instead. The last draft is probably in the public domain. You could update and build upon that instead. Look up "Version 15.17R, X3J13/94-101R" of the proposed ANSI Common Lisp standard.

23


VIP:

do not edit these