Re: Sockets Layer Counter Proposal
John Cowan 11 Oct 2012 03:18 UTC
Shiro Kawai scripsit:
> If you don't like all-caps names, I'd suggest to use
> a *consistent* rule to convert well-established names
> to schemey-names. E.g. SOCK_STREAM -> *sock-stream*
The cl-posix-generalities page on Cliki has this set of mapping rules:
A symbol name is derived from the C binding's name, by:
1) uppercasing, then
2) replacing underscore (#\_) characters with the hyphen (#\-)
3) where the fields of a C structure all have a common prefix
(for example, "st_"), we omit it.
4) constant names get prefix and suffix '+'s.
No other changes to "Lispify" symbol names are made, so creat()
becomes CREAT, not CREATE.
Rule 1 would not be relevant to Scheme, of course. +...+ names are
valid in R7RS but not in R6RS or earlier.
Fortran 95 bindings to Posix do similar things. Ada, however, provides
higher-level bindings.
--
John Cowan <xxxxxx@ccil.org>
http://www.ccil.org/~cowan
.e'osai ko sarji la lojban.
Please support Lojban! http://www.lojban.org