HackerLangs
TopNewTrendsCommentsPastAskShowJobs

mechanicum

193 karmajoined 11 ปีที่แล้ว
https://www.tomwaddington.dev/

comments

mechanicum
·เมื่อวาน·discuss
> I've found LLMs to be bad at balancing parenthesis.

I think that was true last year. In my experience, it’s no longer the case with Claude Code or Codex.
mechanicum
·เดือนที่แล้ว·discuss
Last year, I thought it was awful. Even Opus would reliably unbalance parentheses on practically every edit and then enter a doom spiral of making things worse as it tried to figure out the right place to put a `)`.

Recently, I’ve been quite impressed, at least with Claude. At some point they figured out the parens issue, and the code is largely solid and idiomatic. I’ve mostly used it with Polylith apps, so the context for any given change is naturally well-defined. Usual issues with failing to reuse existing functions or make sound decisions about architecture, but no more so than I’ve seen with TypeScript or Rust.

I think there are a few points in its favour: it’s a very concise language, the documentation is terse but precise and comprehensive, and while there’s obviously nowhere near as much Clojure out there as there is JavaScript or Python, there is a lot. As the Clojure demographic skews toward experienced, senior programmers, I’d guess the quality of that corpus is probably well above average.

Java stack trace errors might even be an advantage now.
mechanicum
·เดือนที่แล้ว·discuss
I can believe it’s much improved and I wouldn’t look down on anyone for using it.

But it’s still never going to be a language I like, and I’m yet to encounter any of these modern codebases in the wild. It’s invariably a crusty old relic, much closer to the PHP of 2006 than the PHP of 2026.
mechanicum
·เดือนที่แล้ว·discuss
> Eh? That's completely lifted from CL.

Clojure’s abstraction is a bit more far-reaching than Common Lisp’s SEQUENCE, implemented as interfaces rather than types.

A Clojure sequence is anything “seqable” (either implements the Seqable interface, or special case handling for host platform collections), not just lists and vectors. Hash maps, sets, Java Iterables, etc. are all seqable and work with the same standard collection functions.

e.g. you can `(map (fn [[k v]] …) {:a 1 :b 2})`, rather than needing a separate MAPHASH function.
mechanicum
·เดือนที่แล้ว·discuss
Short answer: “a type system centered on the use of set-theoretic types (unions, intersections, negations) that satisfy the commutativity and distributivity properties of the corresponding set-theoretic operations”.

Long answer, well, there are blog posts[0], the Design Principles of the Elixir Type System paper[1] and related presentations[2, 3, 4] that talk about it at length. Giuseppe Castagna’s site has many more related papers: https://www.irif.fr/~gc/topics.en.html

[0]: https://elixir-lang.org/blog/2022/10/05/my-future-with-elixi...

[1]: https://www.irif.fr/~gc/papers/elixir-type-design.pdf

[2]: https://www.youtube.com/watch?v=gJJH7a2J9O8

[3]: https://www.youtube.com/watch?v=VYmo867YF6g

[4]: https://www.youtube.com/watch?v=giYbq4HmfGA
mechanicum
·เดือนที่แล้ว·discuss
FYI, that’s currently available in a Humble Bundle with 16 other PragProg functional programming books: https://www.humblebundle.com/books/ultimate-functional-progr...
mechanicum
·2 เดือนที่ผ่านมา·discuss
I think describing Kakoune/Helix as vi-inspired with “slightly different keybindings” is rather missing the point.

The most important difference is that they invert the editing model from verb-noun to noun-verb. Meaning you always see exactly what you’re going to be operating on before you do it.

The second most important difference is that they were designed from the ground up around multi-selection editing as a primitive, rather than a plugin or late addition.

That model is typically less efficient purely in terms of keystrokes, for some operations significantly so, but it’s somewhat mitigated if having the state on-screen rather than in your head means you undo less often.

I wouldn’t suggest either approach is superior. I suspect most people (“most people” in the subset of people who jibe with modal editing to begin with, anyway) will find that one just fits their brain better than the other.

Personally, even having used Vim almost daily since finding it on a Fish Disk sometime in the mid-90s, I still turned out to be in the kak/hx group. I can still use vi quite comfortably when I need to, but Helix removed a bit of friction I’d barely been aware of.

There’s a steady stream of NeoVim exiles to Helix forums, I think who mostly found its Lua-based config too complex/brittle, asking why the devs don’t add settings to make it work like Vim, include a *Vim keymap as standard, etc.

It’s kind of wild to me that people would choose their editor based on how minimalist its config/how batteries-included it is, rather than its fundamental editing paradigm.
mechanicum
·2 เดือนที่ผ่านมา·discuss
Last week I actually did dig out my UK launch PSP-1000 from 2005 (a gift from Games Workshop for being Design Studio Employee of the Year, I think to the bafflement of almost everyone in the department, not least me – at the time, I was the bloke who kept the websites running, after most of the US-based team had left on 2 weeks’ notice in March).

Not out of any particular nostalgia for the device itself, nor because I’ve seen anyone else with one. I just had a sudden hankering to play a Ridge Racer, and it turned out my PS3 is stuck in some kind of update loop.

I was pleasantly surprised by how well it’s held up. And by that, I mean this specific unit: over 20 years old, left in the back of a drawer for at least the last 10, but seemingly as good as new. The screen is obviously a bit dim by modern standards, but the battery still holds a charge for hours. If I treated a smartphone like that, I’d be afraid of it swelling to the size of a football and setting fire to the building.

By contrast, the DS Lite I found in the same drawer no longer recognises anything in either cartridge slot and the screens have developed a brownish gradient running top to bottom, although the clock had only drifted by ~40 minutes.

For me, that era of portable gaming coincided with a lot of travel for work, holidays, gigs and music festivals. I’ve probably spent more time playing games on those two consoles than I have on every mobile device released before or since put together.

It’ll probably end up back in the drawer sooner rather than later, but I had a fun Saturday evening working my way through a shoebox of UMDs, checking out save files mostly timestamped 2006-2008. And maybe I’ll finish another run through Jeanne d’Arc first.
mechanicum
·2 เดือนที่ผ่านมา·discuss
It’s trivially easy to do in Clojure (literally one line of code to start an nREPL server, after deps/requires), and often very useful in dev and personal, local projects. In practice, I’ve never once used it in a user-facing production system, in 16 years of writing Clojure.

Out of the box, there’s zero security or audit trail. Building that properly isn’t trivial and, even with it in place, many corporate infosec teams would have fits if you suggested that engineers can make arbitrary inspections/modifications to a running production system.

Where it could be appropriate, often you’re running the code in autoscaling containers or something similar. Modifying one instance then is rarely anything but a terrible idea.

Where I have used it is for things like long-running internal batch systems that run a single instance and never touch any sensitive data. Connecting a REPL in those cases is much more flexible and powerful than, say, building a dashboard UI or a control API over http, and you get it for free.
mechanicum
·6 เดือนที่ผ่านมา·discuss
Maybe Subscribe with Reeder[0], 1Password[1], Userscripts[2]. The RSS and HTML icons are obviously fairly generic, so not 100% sure.

[0]: https://reederapp.com

[1]: https://1password.com

[2]: https://github.com/quoid/userscripts
mechanicum
·8 เดือนที่ผ่านมา·discuss
Their video on YouTube, in English: https://www.youtube.com/watch?v=9vW12gQ4Klc
mechanicum
·8 เดือนที่ผ่านมา·discuss
More than two, e.g. there’s also the Inline Images Protocol supported by iTerm2 and WezTerm.

Kovid documented his rationale at some length here: https://github.com/kovidgoyal/kitty/issues/33
mechanicum
·9 เดือนที่ผ่านมา·discuss
Definitely S01E01, @ ~55-58 minutes. I just watched it.
mechanicum
·9 เดือนที่ผ่านมา·discuss
I mean, 25 years and 27 inches later, and only reappearing after the queen Hudson served had died, with no tale of exactly where he’d been or how he got back… the cynical explanation would be that he was simply a different man claiming to be Hudson in the hope of a handout from the restored monarchy.
mechanicum
·9 เดือนที่ผ่านมา·discuss
These have been available since mid-2022:

  :insert-output Run shell command, inserting output before each selection.
  :append-output Run shell command, appending output after each selection.
  :pipe, :| Pipe each selection to the shell command.
  :pipe-to Pipe each selection to the shell command, ignoring output.
  :run-shell-command, :sh, :! Run a shell command
The placeholder for the current file is %{buffer_name} (not as bad as it looks, the command line has tab completion for basically everything).
mechanicum
·9 เดือนที่ผ่านมา·discuss
Cmd + click places multiple carets on macOS. Apparently – I never touch the mouse when I’m editing in Helix. I don’t know which modifier it is on other platforms.

I’m not sure if replicating Sublime’s Ctrl + D is possible or not, but there are other ways to achieve every use case for it I can immediately think of. e.g. I think I’d typically be doing `<space>h` to select every instance of the symbol under the cursor, or using `s`elect to reduce a selection to a match, possibly yanked and pasted.
mechanicum
·10 เดือนที่ผ่านมา·discuss
It uses old style figures rather than lining, if that’s what you mean by “higgledy-piggledy”. See https://practicaltypography.com/alternate-figures.html#oldst...
mechanicum
·10 เดือนที่ผ่านมา·discuss
I don’t think so, no. This is how it works today: https://www.gov.uk/check-job-applicant-right-to-work

If your new hire is a British or Irish citizen, you ask for their passport on their first day and retain a photo/scan. In most cases this means that a layperson has to verify that the (possibly foreign) document is genuine, but I don’t think fake passports are a statistically meaningful problem.

If they have a visa or, probably most likely in recent years, EU right to remain, they will have a share code for online verification. That takes you to a page with their details and a passport-style photo that you can download as PDF for your records.

Identifying whether someone has the right to work has never been a problem. If somebody is working illegally, it’s because the employer is either knowingly employing them illegally, or doesn’t care/bother to check (or even know that they’re legally required to do so – a perennial problem with early stage startups in London, in my experience).
mechanicum
·10 เดือนที่ผ่านมา·discuss
A small practical example of how you might use this: https://imgur.com/mTS0vHO

Helix on the left and a Clojure repl at top-right in terminal panes. Portal data viewer in a browser pane at bottom-right.
mechanicum
·10 เดือนที่ผ่านมา·discuss
You can have that. Cmd-Opt-Shift-V or H to split with a different profile, or use the move/swap options in the context menu to put any panes in the same tab after creation.