#Scheme
#Irish #LGBTQ+ #couples #excluded from #statefunded #fertilitytreatment #scheme: ‘A huge #disappointment’.
However, #LGBTQ+ #couples and #single #female #patients still find themselves #restricted when it comes to #fertilitycare, since #patients using a #sperm or #egg #donor will not be #eligible for #state #funding.
#Women #Transgender #LGBTQ #LGBTQIA #Ireland #fertility #Healthcare #Hate #Bigotry #Discrimination #Misogyny #Homophobia #Transphobia
https://www.thepinknews.com/2023/09/27/irish-lgbtq-couples-fertility-treatment/
Me, trying to explain how guile-nrepl utilizes guile-fibers for asyncronous interruptible evaluation.
BTW, I've commited and pushed all the recent local changes. It's not ready for everyday usage, but If you are curious and want to try it out type `make server` and use an nrepl client of your choice (monroe or rail for example).
https://git.sr.ht/~abcdw/guile-nrepl
https://github.com/Sasanidas/Rail

Is it Modern Scheme REPL?
- Interruptible evaluation in remote Scheme process? ✔
- Immediately seeing stdout and stderr of remotely evaluated expression? ✔
- Readable exception messages? ✔
A couple things still bother me:
- How to intercept access to stdin (current-input-port)? Need to make custom ports?
- Evaluation happens in a fresh thread every time: 1. constantly creating new threads is not optimal 2. it doesn't allow to invoke previously saved continuation.

5 Concurrency Patterns for Guile Scheme I extracted during my recent work on asyncronous system for guile-nrepl.
Congress leader Rahul Gandhi on Monday travelled by a train from Chhattisgarh's Bilaspur district, where he addressed an event, to state capital Raipur and interacted with passengers on board.
#RahulGandhi #Scheme
https://www.ndtv.com/india-news/rahul-gandhi-travels-in-train-after-launching-scheme-in-chhattisgarh-4422890
Lisp & Scheme recap for week 38/2023
https://discu.eu/weekly/lisp/2023/38/
#clojure #lisp #programming #racket #scheme
Get RSS feeds and support this bot with the premium plan: https://discu.eu/premium
Lokke: Clojure for Guile Scheme
https://github.com/lokke-org/lokke
Discussions: https://discu.eu/q/https://github.com/lokke-org/lokke
Keynote: Delimited Continuations, Demystified by Alexis King | Lambda Da...
#scheme has been very prompt on adopting research work
Apparently it just didnt care about those adoptions being adopted
I mean the first thing I stumbled at after learning about curry Howard correspondence upon googling long long ago , was haskell monads and a terrible book #lyah , also i wasnt very serious about #learntocode thing , before i could figure out the economic incubation of my own labor , didnt start lime that.
That aside , despite trying #emacs in a whim to get away from browser in 2014 ( long after that ) first thing i stumbled at was #pubshell
again no #functionalprogramming , while ema s started to replace nearly everything i used till then , for a long time i saw #elisp as an easy to use config lang with a huge relative value preposition some functions, some calls and a compile env (based on gcc? ( as it was a program?) and a bit of #git ( again no orgit till then .. i was using org-publish though , but without #cd , again not into devops and yes broken org-emacs was an issue then, besides reproducility issues 1 and i present eve now, which helped in seeing #nix primarily as a config language with types, functions and options . It took me a year till i focused on creating my own serious symlinks with home.file . which took me to focus on flakes , modules and nix the language, till then it was more a config language for #nixos (I was not alone and nor fully wrong 2 which fascinated me with its build options also at that time i started to dabble into #ohw and was trying to free myself of commercial stuff since 2014
, then it was time to care about my representation on #socialmedia and integrity of the ab\use of my identity thanks to #cambridgeanalytica and #netflix , as it neared the real life experiences , thanks to the local socio economics and i saw nix as to #selfhost my infra. Dabbling into #typetheory #prooftheory bits of #haskell and #agda is still on ..lets see , where it all goes ( if anywhere at all).
Summary = i ve been more a plt guy than a pl guy per se.
Upside As, I write this I am working to get my emacs config to load some of my nix paths. :meta #introduction post, this also changes , how is see #nixpkgs sets
what next[experimental ] also try to to do it with dotfiles instead of dotconfig dir 3 , although i prefer home.file and I guess , I ll for my own reasons notes - * src = builtins.filterSource(path: type: type != "directory" || baseNameOf path != ".svn")./source-dir;Thus, the first argument e1 must be a predicate function that is called for each regular file, directory or symlink in the source tree e2. If the function returns true, the file is copied to the Nix store, otherwise it is omitted. The function is called with two arguments. The first is the full path of the file. The second is a string that identifies the type of the file, which is either "regular", "directory", "symlink" or "unknown" (for other kinds of files such as device nodes or fifos — but note that those cannot be copied to the Nix store, so if the predicate returns true for them, the copy will fail). If you exclude a directory, the entire corresponding subtree of e2 will be excluded.4When an interpolated string evaluates to a path, the path is first copied into the Nix store and the resulting string is the store path of the newly created store object.
For instance, evaluating "${./foo.txt}" will cause foo.txt in the current directory to be copied into the Nix store and result in the string "/nix/store/-foo.txt".
Note that the Nix language assumes that all input files will remain unchanged while evaluating a Nix expression. For example, assume you used a file path in an interpolated string during a nix repl session. Later in the same session, after having changed the file contents, evaluating the interpolated string with the file path again might not return a new store path, since Nix might not re-read the file contents. 5
criticism , feedback, hat tips welcome
I've been in the computer programming game for about thirty-five years, FWIW, and my considered opinion is that we should have all just used #Lisp.
Programming languages are video games for smarties. There is no good reason to use anything other than Lisp.
(I'm not even a Lisp programmer. I wrote a #Scheme program last month and that's about it.)
The Autumn Lisp Game Jam starts on October 20th. Get ready! #lisp #scheme #gamedev https://itch.io/jam/autumn-lisp-game-jam-2023
A proof checker for Axiomatic Language
http://www.axiomaticlanguage.org/proof_checker.htm
Not only Clojure – Chez Scheme: Lisp with native code speed
Some really interesting way for sharing values between home services with monads:
https://git.sr.ht/~krevedkokun/dotfiles/tree/master/item/config/modules/home/wm.scm#L65
Did you know that you can follow sourcehut repos via RSS?
This is how 30 hours of my work on guile-nrepl this week looks like:
https://git.sr.ht/~abcdw/guile-nrepl/log/master/rss.xml
@ramin_hal9001 There's a #Scheme implemented in #CommonLisp: https://gitlab.com/mbabich/airship-scheme/. I haven't tried it, but maybe that's for you.
I am a bit surprised to hear that ECL works well with C++, as C++ interop was the main motivation for Clasp (https://github.com/clasp-developers/clasp), which is a #CommonLisp implementation on top of #LLVM.
STklos 2.0 released
https://stklos.net/download.html
Discussions: https://discu.eu/q/https://stklos.net/download.html
Learning some insights about Typed Racket at Amal Ahmed’s talk at #strangeloop
Here is another example, this time demonstrating single and multiple inheritance. student and worker both extend person. student-worker extends both student and worker.
(define make-person
(lambda (name age)
(let-values (((name new-name) (call/cc (lambda (k) (values name k))))
((age new-age) (call/cc (lambda (k) (values age k)))))
(let ((get-name (lambda () name))
(get-age (lambda () age))
(age-year (lambda () (new-age (+ age 1) new-age))))
(values get-name
get-age
age-year)))))
; extend person
(define make-student
(lambda (name age school)
(let-values (((get-name get-age age-year) (make-person name age)) ; super constructor
((school new-school) (call/cc (lambda (k) (values school k)))))
(let ((get-school (lambda () school))
(transfer-schools (lambda (school) (new-school school new-school))))
(values get-name
get-age
age-year
get-school
transfer-schools)))))
; extend person
(define make-worker
(lambda (name age occupation employer)
(let-values (((get-name get-age age-year) (make-person name age)) ; super constructor
((occupation new-occupation) (call/cc (lambda (k) (values occupation k))))
((employer new-employer) (call/cc (lambda (k) (values employer k)))))
(let ((get-occupation (lambda () occupation))
(change-occupation (lambda (occupation) (new-occupation occupation new-occupation)))
(get-employer (lambda () employer))
(change-employer (lambda (employer) (new-employer employer new-employer))))
(values get-name
get-age
age-year
get-occupation
change-occupation
change-employer)))))
; extend both student and worker
(define make-student-worker
(lambda (name age school occupation employer)
(let-values (((get-name get-age age-year get-school transfer-school)
(make-student name age school)) ; super constructor
((_get-name _get-age _age-year get-occupation change-occupation change-employer)
(make-worker name age occupation employer))) ; super constructor; ignore overloaded procedures
(values get-name
get-age
age-year
get-school
transfer-school
get-occupation
change-occupation
change-employer))))
One flaw here with the multiple inheritance is that the state that is extended from the root common parent is not reflected in both immediate parents (student and worker). This would be an issue if, for example, the return value of get-occupation
was depended on the value of get-age
. When age-year
is applied to a student-worker here, it only increments the age of the student object, but not the worker. This can be solved by writing a procedure for student-worker
that will keep both synchronized.
(define make-student-worker
(lambda (name age school occupation employer)
(let-values (((s:get-name s:get-age s:age-year get-school transfer-school)
(make-student name age school)) ; super constructor
((w:get-name w:get-age w:age-year get-occupation change-occupation change-employer)
(make-worker name age occupation employer))) ; super constructor
(let ((get-name s:get-name) ; or w:get-name
(get-age s:get-age) ;or w:get-age
(age-year (lambda () (s:age-year) (w:age-year))))
(values get-name
get-age
age-year
get-school
transfer-school
get-occupation
change-occupation
change-employer)))))
An interesting thing about this is that it’s not possible to apply a method to an object that does not support it, because the object is entirely hidden by the “method” by being inside the closure.
Another interesting thing about this is that an object that extends another object can actually have fewer public methods than the parent object, because every procedure must be explicitly returned. If, for example, I did not want the student-worker to be able to transfer schools, I could just not return the transfer-school
procedure. Otherwise it would retain the behavior of a student
object, like get-school
.
So I feel like I just discovered something pretty fundamental about Scheme and continuations ???
I’m not sure exactly what I uncovered but this is neat. It’s basically OOP but instead of mutating the state of the object, I just return a bunch of procedures to interface with the “new” object. The old procedures exist if you would like to back track your “mutations” and reference a previous state of the object.
(define make-person
(lambda (name age occupation)
(let-values (((name new-name) (call/cc (lambda (k) (values name k))))
((age new-age) (call/cc (lambda (k) (values age k))))
((occupation new-occupation) (call/cc (lambda (k) (values occupation k)))))
(let ((get-name (lambda () name))
(get-age (lambda () age))
(age-year (lambda () (new-age (+ age 1) new-age)))
(get-occupation (lambda () occupation))
(change-occupation (lambda (new) (new-occupation new new-occupation))))
(values get-name get-age age-year get-occupation change-occupation)))))
Example usage
scheme@(guile-user)> make-person
$47 = #<procedure make-person (name age occupation)>
scheme@(guile-user)> (make-person "Robby" 24 "Software Engineer")
$48 = #<procedure get-name ()>
$49 = #<procedure get-age ()>
$50 = #<procedure age-year ()>
$51 = #<procedure get-occupation ()>
$52 = #<procedure change-occupation (new)>
scheme@(guile-user)> ($48) ; Show the initial state of the object
$53 = "Robby"
scheme@(guile-user)> ($49)
$54 = 24
scheme@(guile-user)> ($51)
$55 = "Software Engineer"
scheme@(guile-user)> ($50) ; "Mutate" the object by aging a year
$56 = #<procedure get-name ()>
$57 = #<procedure get-age ()>
$58 = #<procedure age-year ()>
$59 = #<procedure get-occupation ()>
$60 = #<procedure change-occupation (new)>
scheme@(guile-user)> ($56)
$61 = "Robby"
scheme@(guile-user)> ($57) ; New state is accessible with new procedure
$62 = 25
scheme@(guile-user)> ($59)
$63 = "Software Engineer"
scheme@(guile-user)> ($60 "Potato Farmer") ; Mutate the state with arguments
$64 = #<procedure get-name ()>
$65 = #<procedure get-age ()>
$66 = #<procedure age-year ()>
$67 = #<procedure get-occupation ()>
$68 = #<procedure change-occupation (new)>
scheme@(guile-user)> ($65) ;
$69 = 25
scheme@(guile-user)> ($67) ; New state is accessible on top of the previous state change (aging)
$70 = "Potato Farmer"
scheme@(guile-user)> ($49) ; Old state is still accessible by using the previous procedures.
$71 = 24
2 #Gay #Dads Helped #Uncover $767,000 #Embezzlement #Scheme in #Texas #Town Where ‘#Officials Called Them #Homophobic #Slurs’
It all started after the dads moved to #Aurora, #Texas and opened a #taco #shop. It ended with #cityhall #mysteriously #burningdown.
#Women #Transgender #LGBTQ #LGBTQIA #Texas #Conservatives #Extremism #RepublicanParty #Hate #Bigotry #Violence #Genocide #Discrimination #Homophobia #Transphobia #ThePartyOfHate
@donkeyblam chez is the smallest of all the major implementations I believe. Chibi, the simplest to embed in application, while also fully featured with the largest SRFI set of any other except maybe gauche is about 25mb. Gauche is a fully featured implementation that is probably the closest to a full implementation of #r7rs-large (red) aimed at extending other applications and is ~85mb. gambit, the second fastest, is ~140mb. Guile is very fast (performance has never been a hangup in my extensive experience) and probably boasts the most extensive tooling beyond racket, and is ~80mb. Guile also ships with libguile, a simple interpreter written in C that is just a few mb and dead simple to embed in applications, but its features are quite limited.
And then #loko, the new kid on the block that is climbing the #scheme benchmarks at breakneck speed and I believe currently tailing racket after gambit and chez, which is also a microkernel operating system with #ConcurrentML style multicore based on Guile's fibers, as well as its own #wayland-style WIP compositor ("valand"), is a mere 9mb, with no dependencies whatsoever. It bootstraps from sprinkles of hand written assembly, which makes up a mere %0.2 of the code in the repository. Extremely impressive project. The author also makes the #akku scheme package manager, which is starting to make cross-implementation compatibility possible among r6/r7rs implementations.
Lawvere's Conceptual #Mathematics. Friedman's The Little Schemer. These two books provide playful approach to their subject matter, toying with camp while stealthily introducing the reader to advanced concepts that they will only later in their journey recognize (#topos theory for CM, #compilers for TLS).
I consider them to be truly masterful & singular pedagogic demonstrations. What other works fit into this category?
#bitsyntax: a binary pattern matcher inspired by #Erlang's (which is an incredible feature that every language should consider implementing) for #racket
https://docs.racket-lang.org/bitsyntax/index.html#(part._.Pattern-matching_bit_strings)
wreckto-verso: experiments with the #verse calculus in #minikanren from Will Byrd
(here using #chez #scheme)
https://github.com/webyrd/wreckto-verseo
Lisp & Scheme recap for week 37/2023
https://discu.eu/weekly/lisp/2023/37/
#clojure #lisp #programming #racket #scheme
Get RSS feeds and support this bot with the premium plan: https://discu.eu/premium
One more reason why it's hard to use alists as associative data structure: There is no built-in destructuring capabilities for it. It seems (ice-9 match) is no help here. Situation becomes even worse if we have a nested data structure.
Going to stack a bunch of let+assoc-ref's I guess.

https://medium.com/@volodymyrpavlyshyn/javascript-son-scheme-and-self-how-does-javascript-end-oop-vs-functional-wars-3135e9b3cb0b How #javascript married #OOP and #FP . the son of #self #smalltalk and #scheme and #lisp.
I really hope Daphne Preston-Kendal comes to replace John Cowan on the #scheme steering committee. She's really nice to listen to, seems cool and comes from a similarly transdisciplinary background as John's, and it's time to break up the boy's club.
https://www.youtube.com/watch?v=y8qaitWSDW0
Gerbil Release Roadmap: the road to v1.0
https://github.com/mighty-gerbils/gerbil/discussions/853
Discussions: https://discu.eu/q/https://github.com/mighty-gerbils/gerbil/discussions/853
> Sometimes you would like to evaluate code that comes from an untrusted party. The safest way to do this is to buy a new computer, evaluate the code on that computer, then throw the machine away. [0]
I love it! <3 :) #lol #guile #scheme
- [0] https://www.gnu.org/software/guile/manual/html_node/Sandboxed-Evaluation.html
Guix and RDE on unixporn:
https://www.reddit.com/r/unixporn/comments/16ea0kh/dwlguile_elegant_weapons_for_a_morecivilized_age/
:guix: :emacs: :wayland: :lisp:
Kudos to screenshot author and rde co-maintainer: @migalmoreno
dwl-guile and dtoa-guile authors: @engstrand and Fredrik Engstrand
and thousands of people bringing all that beatiful software to us.
I think #Agda is by far the nicest purely at the language level (I'd probably consider Agda the prettiest language after Scheme), but 2gb is a lot of space, especially for someone like me that has lots of large 3D scene files, with massive textures, and am constantly making space on my laptop. #Coq is smaller then Lean, but a lot of OCaml also bleeds through, which is a great language, but not the most elegant, and I'm just trying to grill.
#Idris is really great and the one I've spent the most time with; I was even split between diving deep into either Idris or #Scheme a few years ago and chose the latter, as Edwin Brady's book is one of the best general introductions to FP I have read. But what I'm ultimately interested in exploring is Lean's hygienic macro system, and I'm overall really digging the lispyness hiding within Lean's mixfix notation
[Announcement] New chair of Working Group 2 (R7RS)
https://groups.google.com/g/scheme-reports-wg2/c/46bdsdpYRt8
Discussions: https://discu.eu/q/https://groups.google.com/g/scheme-reports-wg2/c/46bdsdpYRt8
Lisp & Scheme recap for week 36/2023
https://discu.eu/weekly/lisp/2023/36/
#clojure #lisp #programming #racket #scheme
Get RSS feeds and support this bot with the premium plan: https://discu.eu/premium
Announcement 🥁🥁🥁
New #London #Guix #meetup scheduled for Monday 25th September, from 6pm. More info and registrations here:
https://mobilizon.fr/events/552977a1-3398-47bf-a7c1-ee5afee211d9
See you there! 🎉
Those of you who remember the #Fluxus #livecoding environment might be interested to know that part of its DNA lives on in @thentrythis's (flx) WebGL 3D Game Engine:
"A fully featured browser based game engine used for FoAM Kernow projects such as our Butterfly hunting citizen science games, Viruscraft, Penelope tablet weaving livecoding system and the Royal Society Summer exhibition Malaria games."
And people say open-source software is unapproachable and difficult for the average user!
(Yes, expecting them to write Lisp-like code is "simple" according to the Gnu IMP documentation...)
#OpenSource #FreeSoftware #GIMP #documentation #UI #easy #simple #lisp #scheme #BatchMode
Bintracker: "A #Chiptune Audio Workstation for the 21st Century" . And it's obviusly written in #Scheme! <3 https://bintracker.org/
🔴 Today on #SystemCrafters Live, we'll learn how to use Guile Hall, Guix and Emacs to develop new Guile Scheme libraries! With these tools you can scaffold new projects with everything you need to start hacking.
As an experiment, we'll use them to prototype a simple URL route handling library!
Join us on YouTube or Twitch:
- https://youtube.com/live/o-keXs2Uh7w
- https://twitch.tv/SystemCrafters
- https://systemcrafters.net/live-streams/september-1-2023/
🕐 in your time zone: https://time.is/compare/1800_in_Athens
Found a nice talk on concurrency. It has a very brief comparison of different concurrency models, like Erlang's Actors, Hoare's CSP, Go's goroutines, Clojure's core.async, Concurrent ML (aka Fibers in Guile).
Primary focus on Concurrent ML (but examples are in Scheme with type annotations ><).
#go #golang #clojure #lisp #guile #scheme #ocaml #concurrency #erlang
A neat book on designing a compiler for Racket scheme starting from raw x86 https://www.students.cs.ubc.ca/~cs-411/2022w2/chp1_book_top.html #compilers #racket #scheme
3. Section 241 of Title 18 of US Code (deprivation of rights).
The Justice Department and court precedents under Section 241.
As we write:
"Conspiracies to prevent the proper counting of ballots in federal elections ... are within the heartland of Section 241 prosecutions."
United States v. Mosley, the U.S. Supreme Court upheld the indictment of officers of a county election board who conspired to omit certain ballots from the vote count.
(Those facts sound familiar?)
Justice Oliver Wendell Holmes, wrote this about Section 241.👇
Those facts should sound familiar.
Because criminal defendant trump's premeditated plan to try to "stop the count" of ballots fits like a hand in glove with that and other Section 241 prosecutions.
Outline the factual chronology in depth in our article.
https://www.justsecurity.org/87435/an-overlooked-january-6-charge-the-stop-the-count-scheme/
#TheBigLie #scheme #felonies
🧵
Experts, have focused on false electors, DOJ pressure, Pence pressure, and Capitol attack.
But there was a #scheme that preceded all these, and #DoJ can charge it. The scheme was the effort to "stop the count" on election night.
2. Donald Trump was told he would lose by his campaign before the election, he knew early counts would show him leading, he knew he would falsely claim victory before the votes were counted to spread his lies & incite his followers.
3. In a recording of Steve Bannon speaking to a group from China makes it clear that Trump had every intention of installing himself as dictator & subvert the will of the voters.
Listen to the plan, the #conspiracy to defraud the United States and it's citizens. #TheBigLie
I am currently experimenting with #Guix for building a reproducible evaluation environment for an upcoming paper, and must say that I am really happy with Guix for this purpose. It's a huge improvement over my previous setups, which were mostly based on awful Docker images. Also, if you know a thing or two about #Scheme, it's a lot of fun to use!
A bunch of links to cool Scheme projects:
https://github.com/schemedoc/awesome-scheme
#Guix succeeds because #Scheme is, in my opinion, a better DSL and language than this weird, not very well documented, #Haskell-like derivative #nix
https://news.ycombinator.com/item?id=27369960
Damn, this is pretty cool, and kinda similar to what I want to do with Mesche:
What makes the #Guix System so cool is that almost all of it is just #Scheme code. This opens up a LOT of possibilities, like for example quickly writing a web interface for package-management.
You can see this idea in action in guix.el, which lets you manage all your Guix packages through a powerful #Emacs interface.
In ~1hr, 000UTC
#lisp y #oldComputerChallenge #gopher show.
Gopher news:
@logout is updating the bongusta phlog aggregator !
Old computers:
Phlogs ( @gemlog s, wlogs) on https:/occ.deadnet.se
I have been excited to read gopher://booji.mutated.net 's Sun Sparc Ultra 10 so far!
In #fediverse / #lisp news, @jackdaniel the #EmbeddableCommonLisp current developer on (optimize size)ing #ecl
What I want to see now is
#ecl packages exposed to @cwebber #SpritelyGoblins #Guile #scheme as #c & #wasm
I have quite a lot more followers than I did when I first wrote my introduction, so it’s only fair that I’m writing a new one, bump up the major version.
#introduction #intro #introductions
Hi! o/
I am Ștefan (ș as sh, I also accept Stephan or the equivalent in your language). I’m 21 years old, ♑, he/him, proud #leftist and soon to graduate CS @ UVABc. Sort of proudly living in #romania. My native language is Romanian, fairly proficient at English, slowly learning #finnish (and #italian).
Tried a lot of programming languages in my childhood up until now, a non-chronological list of ones that stuck with me for one reason or another being: VB6 (that’s what I started on at 8 years old), #pascal (+ #freepascal and #delphi), #perl (+ #raku), #tcl #tcltk, #lisp (usually #scheme, on a good day #elisp #emacslisp and #commonlisp), #elixir, #php, #forth, #lua, #oberon, #modula-2, #cpp #c++, #ocaml, #fsharp, #smalltalk (+ #squeak #pharo #self), #ada, #powershell, #dart, #matlab, #rlang, #zig, #nim, #cobol and #julia. I don’t claim full proficiency in all of these, but I’m familiar enough with these (+ some others not mentioned here) that I could get along just fine with 2 weeks at most of studying and looking through cookbooks and examples). I’m flexible in learning new languages and technologies if needed.
I also do #sudoku and #math for fun (especially functional equations and number theory problems, sometimes calculus and geometric algebra). I am interested in #linguists, #conlangs (#lojban and #esperanto) and #nlp, contemporary (post-‘45, usually post-‘89 for me) history, #balkan history, lower-level stuff (I like to learn about how tools around me work, I’m most interested in #compilers, #emulators and #microcontrollers), #typography and #latex, #linux + #bsd, #msdos, #amiga, #oberon, #plan9, #philosophy, #astronomy (especially in a worldbuilding context) and #philosophy, along with other less notable interests.
I engage in #politics relatively often irl, although I’m not inserting it in absolutely every scenario in my life. As I mentioned, I’m a #leftist and #progressive (or… um… #woke) (Nazis and fascists can have a merry fuck off, DNI with me). I am also a spiritual person, a #deist (if you really want to put it that way, an agnostic, although it’s not quite true) and I find #astrology and #tarot interesting (I’ll let you guess my moon and ascendant, let’s see how close you are).
With that being said, I hope I’m welcome here, you can pick your subset of things that interest you from this list, you have plenty of options. :P Quite a bit longer than last time, but oh well…
Number three: #lisp. This is spicy enough, so:
- Lisp syntax is painful (and the classical Lots of Irritating Small Parentheses stab). For those who don’t know (and why I put this at #0), what other languages might write as
5*a+3
is(+ (* 5 a) 3)
. However, in spite of the fact that it may look initially a little funny to the unaccustomed, there are some sound technical reasons why Lisp syntax exists:- Easy to teach: grouping of operators and associativity is obvious.
5 * a + 3
is(+ (* 5 a) 3)
, while5 * (a + 3)
is(* 5 (+ a 3))
; - Easy to parse: you don’t have to bend the language to understand your new function, everything works the same;
- Maps nicely to an underlying data structure: Lisp is a living and breathing AST. Having this syntax makes macros possible. When you teach someone about macros, it’s obvious what the internal representation of a Lisp expression is because it looks just like Lisp program data. You can thus fit Lisp to anything you want. Lisp programmers focus on the content, Lisp haters focus on the parentheses.
- Easy to teach: grouping of operators and associativity is obvious.
-
Lisp is old. No? There are modern dialects of Lisp such as #Clojure, #Racket and the myriad of R{5,6,7}RS #scheme implementations. We’re still going strong, thank you. If anything else, #AutoCAD is still a thing and that has AutoLISP, so it definitely lives on.
-
Lisp is slow. I have actually heard this from a teacher live (along with the Lots of Irritating Small Parentheses stab). I asked them when was the last time they’ve tried Lisp. He tried it 30 years ago. Before doing his PhD in #Haskell 98 (which was fresh in #Romania, nobody has heard of it, I still have great respect for him). When all datatypes are appropriately declared, a typical commercial (and even some non-commercial) Lisp compilers produce native machine code on par with C++. It was true back when Lisp ran on the IBM 704 because they could barely handle the GC, but over times the compilers improved a lot. To equate 1960s (or even 1980s) Lisps to modern Lisp compilers is like claiming C is slow because the only time you’ve tried it is with a C compiler on the PDP-11.
-
Lisp is big. First of all, I find this really funny because Scheme (a branch of the Lisp family) is minimalist yet powerful in its nature. This myth started around the 1980s when Lisp was indeed big (because it packed a lot of useful functionality and there was a limit to how small that functionality could be made). Lisp vendors noticed that and nowadays Lisp is one of the few programming languages in recent years that has not been allowed to grow in size by leaps and bounds with every release. At this point, this point is (excuse my Chinese) fucking bullshit, people are happily running Electron-apps and they don’t care at all about resource usages because they’re all running the latest and greatest hardware anyway. Languages are getting more and more bloated (ahemc++ahem) and so Lisp actually ends up looking like a compact alternative.
-
Lisp has no arrays. This is also BS, we’ve had an array datatype for at least 30 years. Even though the Lis of Lisp is from, shocking, List, it doesn’t mean that it’s the only data type. Lisp offers powerful support for single and multi-dimensional arrays, arrays of varying element type, and array access that provides transparent access to fixed size arrays, arrays displaced to other arrays, and arrays whose size is expected to dynamically grow and shrink.
-
Lisp has no compiler. It… does? Since its earliest days Lisp implementations have been variously interpreted or compiled, and often both. Much important work in the theory of program compilation has been done using Lisp and so Lisp benefited from that. All modern Lisps have a compiler (and also a REPL which allows for interactive debugging, thank us for that and much more at the end of this post).
-
Lisp is not standard. Let me present ANSI X3.226/1994 (first ANSI standard for any OO language btw) and RnRS (5 <= n <= 7 nowadays). The Common Lisp HyperSpec (CLHS) is a webbed adaptation of the ANSI Common Lisp standard made by LispWorks, heavily cross-indexed with a lot of indices.
-
Lisp doesn’t talk to other programs… Um, most serious Lisp dialects and implementations definitely have FFI, most even have easy access to TCP, CORBA, COM, databases etc. This is a really weird point that I’ve actually heard, people think Lisp is isolated from everything.
- Lisp GC is slow. It may have been true in the past when computers could barely handle GC, but a lot of progress has been made since then and it’s now on par with other popular GC languages.
Lisp haters should give Lisp more credit. It pioneered a lot of features that people take for granted such as REPLs (which are trivial in Lisp, literally (loop (print (eval (read))))
(in Lisp-ish pseudocode), GC with mark-and-sweep, AST as a tree structure, if
(yes, not even FORTRAN had conditionals), a function type, recursion, programs composed of expressions, a symbol type, a notation for code using trees of symbols and constants, and the concept of having the whole language there all the time. What I mean by the last point is that there’s no real distinction between read-time, compile-time, and runtime. You can compile or run code while reading, read or run code while compiling, and read or compile code at runtime). This lets you reprogram Lisp’s syntax; running code at compile-time is the basis of macros; compiling at runtime is the basis of Lisp’s use as an extension language in programs like Emacs; and reading at runtime enables programs to communicate using s-expressions, an idea reinvented as XML.
Lisp is pretty nifty after all, huh?
Writing some Guile code yesterday. Got stuck on an exception…
foo is a list of strings, like '("183" "43,5" "3,1E-06")
(map locale-string->inexact foo) threw the following :
ice-9/boot-9.scm:1685:16: In procedure raise-exception:
Invalid read access of chars of wide string: "183"
🤷♂️
Recordings for Bobkonf 2023 are finally published:
https://bobkonf.de/2023/en/program.html
There are at least a few talks I want to watch (in no particular order):
- WebAssembly for the rest of us by @wingo.
- Re-thinking Modules for the Web by @codehag.
- Writing Powerful Macros in #Scheme by Marc Nieper-Wißkirchen.
- Cloud, done the #nix way (+ #unison) by Julian Arni.
- Structuring effectful programs by @kosmikus.
- VCS in the age of distributed computing by @nuempe.
Guile Scheme really needs something like https://clojuredocs.org, or at least something like the Common Lisp HyperSpec.
As of now grepping through the Guile source is the most efficient way to understand functions/macros you don't know, which is definitely NOT beginner-friendly.
#guile #scheme #lisp #gnu
🔴 Today on #SystemCrafters Live, we'll experiment with writing a true graphical installation UI for GNU Guix using Guile Scheme and GTK!
We probably won't make it very far, but I want to try to prove that it can be done!
Join us on YouTube or Twitch:
- https://youtube.com/live/TuBy-0DmS4E
- https://twitch.tv/SystemCrafters
- https://systemcrafters.net/live-streams/june-30-2023/
🕐 in your time zone: https://time.is/compare/1800_in_Athens
@mianmoreno made a thread on real-world rde configurations examples. Don't hesitate to press reply to thread button and share your.
There is a config by authors of dwl-guile and a few more quite interesting ones.
A Realtek RTL8139 wifi driver written in #r6rs #scheme for the #loko kernel & operating system
Loko's concurrency is based on #Guile's Fibers implementation of ConcurrentML.
https://gitlab.com/weinholt/loko/-/raw/master/drivers/net/rtl8139.sls