News for hackers. Stuff that matters.
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by egeozcan on Sunday March 07, 2021 @07:30AM (#26375373)
D is another gem (while established in its own circle, it's not mainstream, therefore a "gem") I'd suggest people to give a try. Also Nim for crazy powerful compile-time features.
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by p0nce on Sunday March 07, 2021 @07:48AM (#26375465)
Absolutely, Nim and Zig have proper CTFE and you can parse JSON at compile-time with a normal parser code in all 3 of them IIRC.
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by dunefox on Sunday March 07, 2021 @08:09AM (#26375576)
This all seems cool until you realise that Lisp had full compile time access to the whole language for decades.
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by nepeckman on Sunday March 07, 2021 @11:10AM (#26376977)
There's more to a language than just features and functionality though. Why does Clojure have adoption despite being the least powerful Lisp, created decades after Common Lisp? Its stdlib, default data structures, and even syntax make it compelling (yes, sometimes having a deliminiter other than parentheses is helpful, and no being able to define new syntax via macros is not the same thing because defaults are important). Its not bad to rehash language features that have existed for 50 years if the resulting language has other compelling qualities.
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by michaelcampbell on Sunday March 07, 2021 @09:17AM (#26375989)
Why does a cool thing seem less cool when/if you realize something else is also cool?
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by belval on Sunday March 07, 2021 @10:04AM (#26376328)
Because if lisp has it then we are not moving forward so much as people are creating new languages with the same features.

Don't know if that actually applies to Zig/D, but that's how I read it.

Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by lhorie on Sunday March 07, 2021 @01:58PM (#26378605)
The revolutionary thing about lisp macros was that you could freely manipulate code as data.

What zig offers is completely different: it allows you freely manipulate types as data, while disallowing the ability to manipulate syntax.

Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by cle on Sunday March 07, 2021 @10:21AM (#26376490)
It’s a major step forward if it fixes one of the huge problems with Lisps: adoption.
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by Hizonner on Sunday March 07, 2021 @10:49AM (#26376776)
If the problem is that languages don't have enough adoption, then spreading people out over even more languages is the opposite of useful.
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by cle on Sunday March 07, 2021 @03:15PM (#26379363)
Depends on what you think the cause of the lack of adoption is. If you think it can be fixed by doubling down on existing languages, then sure. But I don't know if that's addressing the cause (because I don't know the cause).

I use Lisps all the time and love them. But I recognize that most people don't like them. At some point we have to meet people where they are, if we want to have broad impact. Ideas on their own aren't good enough, they need to be packaged up in the right way, approachable to the right people, marketed appropriately, etc. The tech itself is just a small part of what it takes for an idea to create impact.

Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by unwind on Sunday March 07, 2021 @01:43PM (#26378451)
I disagree, programming language ergonomics/"feel" is real and Lisp's don't fit everyone.
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by p0nce on Sunday March 07, 2021 @08:37AM (#26375727)
Yes. But you could see the new crop of native languages as: as close to LISP as possible without codegen in the runtime. There is this 2x gap between JIT and AOT. (EDIT: Other than that I'm not sure if any of the new kids can introspect on the content - lines of codes - of a function, like LISP would).
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by pjmlp on Sunday March 07, 2021 @05:09PM (#26380257)
Lisps support AOT compilation since several decades, image tree shaking, and actually having a compiler in the runtime allows for tooling that most languages lack.
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by p0nce on Sunday March 07, 2021 @05:44PM (#26380519)
Can you avoid having a compiler in the runtime?
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by pjmlp on Monday March 08, 2021 @02:46AM (#26383200)
Sure, AOT compilation + tree shaking.

This is one way,

http://www.lispworks.com/documentation/lw70/DV/html/delivery...

Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by p0nce on Monday March 08, 2021 @04:14AM (#26383647)
So a D successor could be a LISP with mainstream syntax and UX?
Re:Why I rewrote my Rust keyboard firmware in Zig: consisten... by pjmlp on Monday March 08, 2021 @05:29AM (#26384200)
Well, there is Dylan.

D doesn't need a successor, rather a better marketing and fixing all lose ends.