On Wed, Mar 6, 2019 at 10:22 AM Arthur A. Gleckler <xxxxxx@speechcode.com> wrote:
  
This should be fun, and a good learning exercise for us all.

My experiments have been informative.  I started off convinced that a little bit of HTML formatting would go a long way, and in many cases, that turned out to be true.  Indeed, updating SRFI 59 was easy.  I was able to make the page look exactly as before, and successfully used pup and jq to extract procedure names, argument names, and even an optional argument that I added for the purpose of the experiment.

However, once I turned to SRFI 1, things got more complicated.  Not only does SRFI 1 use ellipses to express variable numbers of arguments, but it also already uses <var> for return types as well as for arguments.  I worked through that by adding a class for return types that I could use to exclude them from the argument list.  I also had to add a class to record whether an argument was optional and another to record whether it was repeated.  For example, consider this signature:
list object ... -> list

The argument object has an ellipsis after it, so I used <var class="repeated">object</var> to convey that it could be repeated.

There was another complication.  Consider the signature for cons*:
cons* elt1 elt2 ... -> object

Subscripts are used to distinguish variables that have the same base name.  I used <var name="elt1">elt<sub>1</sub></var> to provide the name "elt1" for use indexes.

The more I go through this process, the less convinced I am that HTML markup is a good solution.  HTML just isn't a great medium, especially when we're using a language with a great printed meta-representation like S-expressions.

I'm going to stop now.  I don't think working through the rest of the SRFIs I selected is going to tell me much more.

Ciprian and Lassi, I'm eager to see how your experiments turn out.