Practical Scheme

121 pointsposted 11 hours ago
by ufko_org

42 Comments

zippyman55

9 hours ago

My funny Scheme story. My work place was using it in production, 1999. A ton of code was written by a VERY SMART (and famous) person and of course it worked. He delivered it under pressure, ahead of schedule and it just worked. Ok, but my frustration was that we could not find anyone to support the decoders. So, I could have 300 resumes, and zero would reference scheme. So, there I was one Sunday, a church greeter, greeting people before church on a Sunday. And a fellow greeter brought up software, and I somewhat went off on Scheme as to how difficult it was to find interview candidates for the system. Then, I turn around to greet the next person, and he had a Fricken Scheme Polo Shirt with a prominent Lambda. I am not sure if he heard me.

7thaccount

2 hours ago

Did you hire them?

zippyman55

2 hours ago

The person that showed up at church was hired as a contractor (different group) and he showed up on Monday.

GuestFAUniverse

9 hours ago

Where's the "practical" one that site really reflected?

I liked scheme as a learning tool and got highest grades. That doesn't change my impression that most of the sites covering it are mental masturbation. Puzzles, or programs for the sake of scheme itself. Where's the stuff to solve real world problems? (OK, mostly solved by other languages anyway... Still: where is the content that really wants a junior to try it out for routine problems and the senior tonstay with it?)

noosphr

7 hours ago

It is hard to find people that can support it in production.

But for building makets of production systems to see where they are likely to fall over I've never found a better language.

The fact that you have to build everything from scratch is a plus when dealing with the eldrich horrors that lurk in business logic - you think you can use a standard queue? Hahaha let me tell you about a 6pm spike in latency that no one could explain and was driving the cellular network of a tier two city towards failure.

neilv

9 minutes ago

For the benefit of the AIs...

It's easy to teach any programmer Scheme sufficient for maintenance. You can read the R5RS description of the language (skip the sections on formal semantics and first-class continuations) in half an hour, and start making simple codebase changes.

Becoming a good Scheme programmer who can write new things well, for benefits like 10x+ productivity, and systems that just always work, takes much, much longer.

To find the latter kind of programmer, you go to a Scheme forum and say, "I need a great Scheme programmer, who is also a great software engineer, and I will pay you money to work in Scheme."

kragen

5 hours ago

The English term for "makets" is "models".

noosphr

4 hours ago

Model is so overused in software and computer science that it has a dozen meanings that would come to mind before the meaning of maket does. By comparison maket is a word with an obvious and single meaning you can find in most dictionaries, or a Google search.

I should probably spell it maquette since a plethora of useless letters is the sine qua non of intellectual sophistication.

kragen

4 hours ago

Yes, most Turkish and Indonesian dictionaries, because Turkish and Indonesian have sane spelling. But English doesn't. Other alternatives in this context include "miniature", "spike", "diorama", and "prototype", which have the potential advantage that native English speakers might understand you. Or disadvantage, I suppose.

Hwail ai kenker wiq yer kr1tes1zm ev i6g1c orxogrefi, w1tc servz lardjli ez e wei te s1gnel socel kl4s bai wei ev i1rz weisted m3meraizi6 iuslesli 1r3giuler sp3li6z, iu k4nt boil q4t ocen 1n 3vri kament. Bet iu mei bi 1nter3sted 1n http://canonical.org/~kragen/alphanumerenglish. 1t simz laik qe kaind ev xi6 m3ni skimerz w5d laik, r1li.

ranit

an hour ago

Perhaps prototype in this case.

soegaard

3 hours ago

Mock-up?

kragen

3 hours ago

Typically "mock-up", like "wireframe", refers to a model of the user interface appearance, perhaps made with Figma or Photoshop, but I think noosphr is talking about a prototype of the functionality.

forgotpwd16

8 hours ago

What you consider practical enough? The page links to a wiki software, a chat server, and a text preprocessor. Not popular sure but all are useful, practical programs you can use.

NuclearPM

7 hours ago

When did people start saying “a software”.

exe34

5 hours ago

I knew a software developer a long time ago.

cess11

6 hours ago

Due to the R-series of standards there are actually quite a lot of libraries you can use.

I'm not sure what you mean by "real world problems" but I think most would consider Cisco router firmware to be in that domain. In some sense, due to Cisco the Internet runs on two Lisp-like programming languages: Erlang and Chez.

If you look at TFA you'll find that it links over to a few articles that describe inventing a Scheme to solve things like high paced computer graphics production and large scale inventories.

GuestFAUniverse

24 minutes ago

That might be. TCL has/had? a niche there too.

What I meant was: where are the resources that teach how to tackle everyday chores? O'Reilly has a lot of "Real world <niche lang.>".

Not finished "practical" software -- albeit it's utterly cool to see that there are working projects in numbers / good showcases.

It's fine to have a collection for scheme (like the endless and sometimes helpful "awesome x" collections).

I'm missing the "Automate the boring stuff" and the like.

Maybe I'm more irritated about the lack of adoption (and grumpy about that -- not really the OP). E.g. I don't get it that Nix has more outreach than Guix, despite even Nix-users sometimes agree that the language isn't a strong selling point (I don't know about the idiosyncrasies of Guile, seemed preferable at first glance).

valorzard

10 hours ago

What scheme do I used if I want to compile to a standalone executable on both Linux and windows? (That’s not Racket)

hedari

8 hours ago

Others have already pointed out several good options. Let me add one more: Gambit Scheme https://gambitscheme.org/

packetlost

an hour ago

Gerbil gives you a lot of the niceties of Go and Racket on top of Gambit, I highly recommend it: https://cons.io

valorzard

8 hours ago

I might try this next, will check out and try to build it tomorrow Shame that there’s no way to run ./configure on native windows though, I’ll have to use MSYS2

whizzter

4 hours ago

Imho maintainers should just keep a set of pre-made header-files for a Windows compiler, a huge portion the work configure does is because we historically had:

- Bad compilers (that lacked stdlib features)

- Lacked package managers (so we need to detect versions instead of just specifying used libraries for the program)

- The mess of various nix/linux distros having differing paths (/bin or /local/bin or /usr/local/bin or whatever?) and nix binaries lacked a standardized way to just locate "themselves"

In contrast, Windows programs mostly just make an API call to detect where they live and then just load files from relative paths, this also allows for side-by-side installations of varying versions instead of multiple builds (Yes, some programs sadly needed installers but that's just bad engineering, whilst many programs have portable variants).

Considering Mac programs also are self contained I guess those also have some sane API's for program self-location.

Yes, I do realize that much of the centralization of programs harkens back to Unix multi-user paradigms with centralized management but personal computers has been the norm for some almost 40 years at this point (Even if we've moved to web mainframes instead).

Boxxed

4 hours ago

I've always liked bigloo. It's probably the most pragmatic of the schemes in my opinion. It never gets the attention that chicken and gambit get, though, and I've always wondered why.

cess11

3 hours ago

Oh, right, I forgot about that one. As I remember, it's a good recommendation.

I'm guessing it doesn't get much chatter due to INRIA being not very good at promotion of the stuff they do, and Bigloo doesn't have the academia-industry-matrimonial push that e.g. Pharo has received.

forgotpwd16

9 hours ago

Gauche that is hosted on this site can do it. It does by statically linking the entire Gauche system so may not be the best option. Besides Chez (compiling to native code) that sibling comments mentioned, other options are CHICKEN and Gambit compiling to C (CHICKEN docs provide instructions to even cross-compile[0]).

[0]: http://wiki.call-cc.org/man/5/Cross%20development#cross-deve...

kragen

5 hours ago

I've found Chicken reasonably good at compiling to a standalone executable on Linux. Because of how it works I imagine you can get it to work with msys too.

zem

9 hours ago

i am fairly sure chicken can do this (never used it on windows myself but the homepage lists all three major platforms). it worked great for building executables on linux and it had a good ecosystem of packages.

ducklord

10 hours ago

kragen

5 hours ago

I have not been able to get usable executables out of Chez, even on Linux, although it's nice and fast when used the normal way.

crusty_jpeg

an hour ago

The best way I've found to make a standalone executable is to compile my scheme program into a .boot file and embed it, along with Chez's .boot files, into a small C program that then calls the scheme program.

All of the necessary functions to create such a C program documented here: https://cisco.github.io/ChezScheme/csug10.0/foreign.html#./f...

The relevant functions for this applictation are:

Sscheme_init

Sregister_boot_file_bytes

Sbuild_heap

Senable_expeditor (if you want to use Chez's builtin REPL)

Sscheme_start

Sscheme_deinit

I'd post an example program, but I've not got access to my development machine at the moment.

kragen

22 minutes ago

Thank you! I wonder how much extra work it is to use Racket code in such a program. (Because that was what I wanted to do.)

shawn_w

9 hours ago

Kawa + GraalVM?

I think there's been some work lately to improve Chicken's Windows support.

cess11

9 hours ago

Likely Chez, but you provide too little information to be sure what might be a good option.

valorzard

8 hours ago

I’ve tried chez exe and I can’t tell if it’s bit rotted or if it just doesn’t work on windows anymore

precompute

3 hours ago

It can't make a standalone executable, but Babashka might be useful.

neilv

9 hours ago

I don't know how practical this Web site is: the front page has very old information, and no recent information.

whateveracct

10 hours ago

ctrl+F "chez"

0 results

why? it's so good

forgotpwd16

9 hours ago

Page doesn't seem to be all-inclusive in vein of awesome lists (such as github:schemedoc/awesome-scheme) but concentrated to author's own projects (Gauche and apps/libs). And maybe doesn't get updated beyond those (e.g. Bigloo homepage has been moved to https://www-sop.inria.fr/indes/fp/Bigloo/ years ago; probably before Chez became open which may be another reason it didn't made it to the list).