Honestly, reading that snippet … suggests to me that make-parser might not 
actually be useful without all of the other internal ssax functions, and that 
perhaps make-parser really shouldn’t be exported, after all :). Is it possible 
to formulate productive uses of make-parser that don’t require a bunch of other 
functions in the ssax module?

Alternatively, perhaps we can come up with good documentation for a whole suite 
of useful functions, and expose them all?

John

> On May 16, 2018, at 11:57 PM, N. Raghavendra <nyraghu27...@gmail.com> wrote:
> 
> At 2018-05-16T14:56:00-04:00, John Clements wrote:
> 
>> In a quick scan of the existing quasi-documentation for ssax.rkt,
>> make-parser was the only one that looked to me like it might
>> productively be used from outside.
> 
> `ssax:read-pi-body-as-string' is another identifier from sxml/ssax/ssax,
> which I am finding useful.  Here is a usage adapted from
> 
> https://github.com/bernied/ssax/blob/master/SSAX/examples/ssax-extraction.scm
> 
> (define (outline-pi port pi-tag seed)
>  ;; Read the body of PI and ignore it.
>  (let ((dummy (ssax:read-pi-body-as-string port)))
>    seed))
> 
> This procedure can then be specified as a handler for processing
> instructions (PIs) in the document, which just ignores them.  Without
> such a dummy handler, one gets a warning message from ssax:make-parser
> that PIs are being left unprocessed.
> 
> However, I am not advocating a full export of ssax from sxml.  I am fine
> with importing ssax separately in my files.  I just thought that it is
> good to keep a record of its useful identifiers.
> 
> Raghu.
> 
> --
> N. Raghavendra <ra...@hri.res.in>, http://www.retrotexts.net/
> Harish-Chandra Research Institute, http://www.hri.res.in/
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.



-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to