2 ms·
Other people have mentioned some real languages, but I'd like to point out something different. Xcb, a replacement for Xlib for interacting with an X11 server,
by davexunit 10y ago
Other people have mentioned some real languages, but I'd like to point out something different. Xcb, a replacement for Xlib for interacting with an X11 server, has a complete XML spec that describes the API. What's nice about this is that bindings can be programmatically generated based on the spec. You can do this in any language by writing a program that reads in the XML and outputs text that is the source for the target language that the maintainer would check into their repo. Guile's Xcb bindings[0] takes a different approach. It uses Guile's compiler tower to read the XML spec as source code and compiles it to Scheme. From there, the existing Scheme compiler is used to compile to Guile bytecode. I think it's a very elegant solution and a testament to the power of Guile's compiler tower.
[0] https://github.com/mwitmer/guile-xcb https://github.com/mwitmer/guile-xcb