[armedbear-devel] asdf encodings and abcl
Mark Evenson
evenson at panix.com
Wed Apr 11 15:07:09 UTC 2012
On Apr 9, 2012, at 03:21 , Faré wrote:
> Dear ABCL developers,
>
> I'm currently adding source file encoding support to ASDF.
> It will hopefully be part of ASDF 2.21, though the plan is that
> anything but :utf-8 and :default requires an extension :asdf-encodings.
>
> I didn't find any way with ABCL to detect the list of external formats,
> or to determine is a given keyword is an acceptable name for an external format.
>
> How do I do that?
After a quick check, I don't think we define an interface. Nor
could I find something in SBCL to copy. Do you have a reference to an API we can
implement?
Essentially we thunk through to the [JVM Charset implementation][1],
is which each named charset is used as its natural keyword form
(i.e. the JVM charset ISO-8859-1 is specified by passing the :iso-8859-1
keyword).
As an intermediate solution,
(require 'abcl-contrib)
(require 'jss)
(jss:hashmap-to-hashtable (#"availableCharsets" 'java.nio.charset.Charset))
will return a hashtable whose keys will be the allowable names for external formats.
"Intermediate" because I would like to keep ASDF independent of the
abcl-contrib mechanism, as ASDF is a requirement of ABCL-CONTRIB,
so I'd rather that we agree on an API, and I'll implement this with
the Java FFI primitives that JSS is based upon.
[1]: http://docs.oracle.com/javase/6/docs/api/java/nio/charset/Charset.html
--
"A screaming comes across the sky. It has happened before, but there is nothing to compare to it now."
More information about the armedbear-devel
mailing list