I've been using Roc for the past two years and it's been a blast! The compilation speed is great, hot-reloading gives you a really nice development experience, and the error-handling is sweet :)
If you're into web apps and The Elm Architecture, then check out https://github.com/niclas-ahden/joy I built Joy so that I could use Roc on a daily basis for client work, and it's been awesome! Now it's growing into a full-stack web framework with full type-safety from the database to the browser. Hope you'll like it too! :D
Clients are paying you to build apps in a pre-release language?
niclas-ahden 21 hours ago [-]
Yes, and it's been a journey! I've built billing systems, business systems, marketing automation etc. for businesses I'd already worked with for a long time and who trust me to deliver. I've maintained these systems for 1–2 years now, and have extracted as many packages as I can from what I've built, so we now have a bunch of useful Roc packages for "serious business use" :)
I'm not saying everyone should be doing this, but it was an opportunity for me to be able to use Roc while contributing a lot to the community. It did take a lot of work, but seeing where we are now, I'm thrilled with how it has turned out :)
Heh, I almost posted a link to a public-facing Roc app here, but that's not a great idea :P DM me on Zulip (https://roc.zulipchat.com/) if you want to see an example of an actual business running full-stack web apps in Roc!
tasuki 21 hours ago [-]
You are surprised, eh? And I'm surprised clients are paying ppl to build apps in languages where all errors are runtime...
oDot 1 days ago [-]
I'm the developer behind the screenwriting software mentioned in the post.
Roc has been so pleasant to use considered it's still so early.
I've read elsewhere a comment by Richard where he said that naive programming in Roc should result in fast code. That is very true. I basically enforce software design and architecture that allow for speed, and I don't have to worry about finagling the language into running fast.
It's very well thought out.
As a result Bliss Writer is correct and stable software, even in beta. I have a large suite of E2E tests that spin up a real TUI and they almost never fail.
Who knew you could have the correctness of FP and speed.
Basically you can handle the errors you want to handle and propagate everything else upstream because the error value is a union of all propagated errors. In other (typed) languages you either need to handle all errors or map the different types into a single one.
stefanka 1 days ago [-]
Have a look at the eros crate for rust. It implements a convenient error set mechanism mostly without macros
Groxx 1 days ago [-]
That looks almost exactly like what I've wanted from rust errors - thanks! Sadly I hadn't seen that before.
Groxx 1 days ago [-]
y = U64.from_str(b) ? InvalidSecond
# returns Err(InvalidSecond(BadNumStr))
Ooo, I like that syntax. Implicit wrapping, but it gives you a type you control so you can <do stuff> if needed.
rixed 22 hours ago [-]
Isn't that how exceptions work, as the union of all possible defined exceptions?
gdotdesign 19 hours ago [-]
I differs that exceptions are hidden and you don't experience them until something happens so it's easier to forget to handle them (at least that is my experience). Here they are up front and visible and forces us to either handle or propagate them.
guenthert 1 days ago [-]
No recovery / restarts though.
ylisav 1 days ago [-]
There is a special place in my heart for people who work on hard software tech such as programming languages. Especially in times of AI and slopification.
ordinaryradical 1 days ago [-]
In some ways it’s never been a better time to launch a new programming language. LLMs make adoption much more about developer preferences than familiarity. LLMs can help with the learning curve of new language paradigms. And they greatly de-risk the long term costs of picking the wrong language given their facility with rewriting.
I think new languages have more freedom than ever to be bold and take risks. We are not nearly so confined by culture or technical debt as we used to be and freedom to experiment has probably never been better.
ashkankiani 21 hours ago [-]
While I agree that LLMs can point you in the right direction of topics for something like a compiler's architecture, I think that this is extremely optimistic. I say this as I tried to do the same thing to see how well it would work (and I've been programming for almost 20 years now), and I quickly remembered why we have compiler courses.
The breadth of topics and how much they interplay is a lot more complicated than your typical software, and there's hundreds of small decisions you have to make along the way which you can only really understand how to design/steer if you understand the whole pipeline.
Your type system affects your syntax, and your syntax affects the complexity of types you can represent ergonomically, and your type system affects your runtime memory model and lowering, and so on and so on.
If you're willing to just let the LLM do all of the work and only judge it from the outside (observational correctness, but otherwise a black box), then sure, maybe you can get something. But I think that's:
1. going to lead to holes in your language design that you don't understand how to fix.
2. robbing you of the opportunity to learn. Learning design via one of the harder problems that exists, and also learning how to learn. You're forced to organize your approach to understanding the topics in a way that you can't just bruteforce components out of order and piecemeal unless you have an insane capacity to memorize things.
raddan 16 hours ago [-]
I don’t disagree with you at all (I am a PL researcher), but I think the parent poster was referring to users of a language, not the designers. Language design is hard for all the reasons you describe. It’s a strange combination of hard CS problems with a strong sense of aesthetics. That’s why I love it. But it’s also true that using an unfamiliar language is easier these days—if you use an LLM “the right way” you can focus on the necessary difficulties of learning a new language (e.g., “what is a borrow checker?”) from the unnecessary ones (e.g., “why do all of the tutorials for begunners assume I understand how dependent types work?”).
0c3ca83 1 days ago [-]
Why would you care about which language you're using if you don't care to get familiar with it?
ordinaryradical 1 days ago [-]
What if you DO care but you couldn’t get the thumbs up from the team before because “what if we end up having to rewrite?”
I’m saying the opportunity cost of trying new languages has never been lower.
ojkelly 1 days ago [-]
the language, and the ecosystem of tooling and packages, you choose for a project will have a massive influence on the outcome.
all languages excel at something to the detriment of something else, no language can be good at everything.
the language also defines the terms for which you can reason about a problem.
even if you're not writing it, you're (hopefully) still reading it.
There's a good reason we're not writing web servers in assembly or SQL.
raddan 15 hours ago [-]
I disagree with the downvotes you’re getting. The Principles of PL course I am currently teaching essentially makes the same point. We even make that claim in the course description—because it’s true! Maybe the HN crowd needs to go read Beating the Averages again.
0c3ca83 1 days ago [-]
And this language has more mature tooling and a larger base of packages? And while I avoid LLMs unless I'm paid a shitload of money to deal with them, it's obvious none of my coworkers read their generated code; as LLMs get better, this obviously expands.
pjmlp 1 days ago [-]
LLMs make programming languages irrelevant, it is the dream of 4GLs finally becoming widespread.
rickydroll 24 hours ago [-]
I disagree. I speak my development and don't touch the keyboard for any programming tasks except maybe the up and down arrow keys.
For me, there are 2 or 3 different levels to modeling what's going on. The first phase is the architecture; the second phase is the design, although some claim those two are merged. And then there's the modeling of the implementation, and that is driven by the programming language. Even though an LLM is generating all my code, I still read it; I still try to understand it so that when I debug it, I'm not going WTF quite as often.
pjmlp 24 hours ago [-]
Ah, that is the early steps when joining an offshoring project, the early days to review each PR that gets in from the offshoring team, until a couple of months later down the line, as long as it fits the customer requirements, it is good enough.
The only difference is that now the offshoring team is out of luck, replaced by gremlins in the box.
rickydroll 20 hours ago [-]
You're probably right. It's attention fatigue. way too many moons ago, I was a dev on a project that required scanning a bunch of existing documents (close to a million pages, all for gov projects), and we needed a person to sit there and look at every single page to approve it. We found that within 10, 15 minutes, people's eyes glazed over, and they just hit accept.
I'm sure the same thing will happen to me after a while, like about a half hour from now.
arcanemachiner 1 days ago [-]
> A fourth-generation programming language (4GL) is a high-level, often domain-specific language that uses human-like syntax and focuses on what result to achieve rather than how to execute every step.
0c3ca83 1 days ago [-]
This is, by now, fully being written by AI. If you're not interested in slop, you may want to look elsewhere.
ModernMech 1 days ago [-]
I don’t think it’s useful to collapse all ai output to “slop” unless you’re trying to make an ideological statement. We’ve been working with these things long enough that we can identify shades of grey.
It’s like calling clay pottery lumps of mud. Maybe technically accurate but you’ve lost the helpful nuance. Turns out people can shape and mold the slop into useful tools. At that point “slop” becomes less of a pejorative.
keybored 23 hours ago [-]
It’s in the word. AI output has no provenance. It’s historically (I don’t know about the “self-improving” kind) a mashup of everything. But you can’t tell where any particular thing came from.
You could have a “nuanced” analysis of what the output is like. But there is no analysis to be had of where it came from. Like a car wholly made from stolen parts where no part has any serial number.
ModernMech 23 hours ago [-]
The codebase has plenty of provenance, it didn't come from nothing, and there are people behind it with a reputation. And what does it matter whether a particular line of code originated in a human mind or an artificial one? The measure of worth here is not on any line of code and where it came from, but what all the lines of code do as an aggregate, regardless of their origin. That absolutely has provenance here -- we can look at the 8 year history of this project, which of course predates mainstream agentic coding.
keybored 23 hours ago [-]
> And what does it matter whether a particular line of code originated in a human mind or an artificial one?
Pff.
> That absolutely has provenance here -- we can look at the 8 year history of this project, which of course predates mainstream agentic coding.
You would have to take that up with OP. The “slop” part, whether it started a week ago or a year ago, has no provenance.
ethin 20 hours ago [-]
> The “slop” part... has no provenance.
Then how exactly can you or anyone else claim that the so-called slop (which clearly is so nebulous of a term that we need to debate said definition... Which probably means we shouldn't be throwing it around so casually...) was stolen? Saying something is stolen implies you know where the output actually came from.
ModernMech 21 hours ago [-]
> The “slop” part... has no provenance.
You'll have to define "slop" then. For instance, code written by hand and then translated by an LLM has provenance, so is that slop?
If your definition of "slop" is "any generated code without provenance", then people can work to show provenance.
If your definition of "slop" is "any generated code" then the word is more of a shibboleth. And that's how people seem to use it, which is why I'm saying it's not useful anymore unless you're trying to promote an ideology.
crowdhailer 1 days ago [-]
I've been following Roc quite closely while I build (EYG lang) another functional language for my own use. I'm super impressed with the performance results they share. I thought that would be a distraction while developing. And maybe it was as it took 8 years.
I don't love the result of purity tracking rather than a full effect system. I was quite enamored with proper effect tracking and have labeled effects in EYG.
I think my holiday hacking might have to be try something real in Roc and see if I learn to love this approach to effects
commandersaki 1 days ago [-]
This is quite compelling.
I am always reluctant to try languages in their infancy though, not because of stability. I just don't know to what extent you can write sophisticated software such as a web server, a GUI application, etc.
I also notice that this Odin language is taking off. Never heard of it before but it's being used for the Rex client (superlogical) on Windows.
That is to say, I usually start paying attention when serious software is being made. (not a criticism of Roc though)
niclas-ahden 22 hours ago [-]
Glad you like it, I do too :)
If it's any help, I've been writing "serious business apps" in Roc for the past two years, so you can already do quite a bit! I write mostly web apps and had to write my own web framework (https://github.com/niclas-ahden/joy) since it was such early days. I've been extracting and releasing as many packages as I can to help build out the ecosystem for people like you. I hope you'll have a great time when you decide to try it :)
If there's anything specific you need or are unsure about, post on https://roc.zulipchat.com/ and we'll help you!
codemastercpp 2 hours ago [-]
Since roc is functional, and focused on perf, how does it match programs that work best with something like arena allocation? Would it get outshined even by languages like go/java or is there some sort of trick?
tarr11 1 days ago [-]
The timing of this is interesting to me. I have always been a fan of Elm.
I have been building an app platform on top of Rust for a few months, and have run into a series of problems and I sometimes wish I could use something more purely functional such as this. It offers a lot of guarantees that I want such as memory safety and side-effect-free code, and have had to try and build myself (probably poorly) in my own thing.
Looking forward to trying this out and congrats to Evan and team on the release
idoubtit 1 days ago [-]
> Looking forward to trying this out and congrats to Evan and team on the release
You probably meant "congrats to Richard" who is Roc's BDFN (Benevolent Dictator for Now) https://www.roc-lang.org/bdfn
I'm pretty sure the BDFL of elm did not contribute to Roc.
ifh-hn 22 hours ago [-]
I don't really get the application/platform thing. I've read the docs and asked AI to explain it but I'm still not clear on really what they are or the point. Platforms just seem to mean using another programming language to do the hard bits. Might as well just use those languages to finish it off.
I'd love to understand the point.
niclas-ahden 22 hours ago [-]
Platforms are what give you all of the effectful functions you need. It could be a "webserver platform" which lets you answer web requests and talk to a database, or it could be a "TUI platform" which lets you read keyboard input etc. Without a platform you'd just have pure functions, because unlike many other languages, Roc doesn't offer any effectful functions in its std lib. My mind was blown when I realized that! :'D
Another way to look at it is a practical comparison: JavaScript is a language, but it needs to run on something. If you run it in the browser, you get access to browser APIs. If you run it on the server with Node/Deno/Bun you get different APIs that are useful for web servers. In that scenario, the browser or Node/Deno/Bun is the platform.
The example above isn't apples-to-apples, but it's a good way to visualize the difference!
Does that help? :)
ifh-hn 22 hours ago [-]
Somewhat, but it's the fact it doesn't really cut it. Because this could be similar to say the java VM, except the VM has a much bigger scope than a roc platform.
To me it just seems like roc can't function without other languages to make them useful.
Please don't take this on a bad way I'm just unable to describe it better.
niclas-ahden 21 hours ago [-]
Yeah, I mean, that's just factually true! No harm in that :)
Roc needs a platform written in another language, but you as a Roc author don't have to read or write that language. You don't even need to know which language a platform is written in.
Someone else (like me!) writes a platform, shares it, and you use it. That means you get whatever platform you want: maybe with the concurrency of Go? Or the performance of Zig? Or the memory safety of Rust? And the platform can give you access to their entire ecosystem. All that with no effort on your part, and you get to read and write only Roc. Sweet deal, right? ;D
ifh-hn 20 hours ago [-]
Yeah I don't know, there's a lot of trust there though. It just feels weird to me that roc can't run without something written in another language. How do you debug it is the fault lies in the platform, written in a language you don't know? It also seems to say purely functional languages can't do much without a none functional layer. Maybe I'm still not understanding.
Maybe it's just something I need to get used to.
Thanks for taking the time to explain though. If you're the guy that created the joy web framework (platform?) for roc, then I watched and enjoyed your talk about it.
niclas-ahden 20 hours ago [-]
>It also seems to say purely functional languages can't do much without a none functional layer.
Well, you could write your platform in a functional language :) What it is saying is that separating pure vs. effectful/impure comes with some nice benefits, and we're seeing that in the platforms concept. I think if you try it you may see it differently :)
>If you're the guy that created the joy web framework (platform?) for roc, then I watched and enjoyed your talk about it.
Yeah, that's me! Thank you so much! PS. I call it a "framework" just because it spans more than one platform. Not really an important :P
Numeric1137 13 hours ago [-]
> It also seems to say purely functional languages can't do much without a none functional layer
Exactly. At some point, your pure FP code has to hand off a description of some effect (open this file, make this network request, write to std out), otherwise all it can do is maybe heat up your computer.
rixed 13 hours ago [-]
Most if not all of programming languages you have used recently can't run without a C "platform", ie most of them ultimately link to the C stdlib.
grayrest 22 hours ago [-]
Platforms serve roughly the same role as a framework in another language with the difference being that a Roc platform must provide all side effects and therefore tends to include things that would be standard library elsewhere. In one of his talks, Richard mentioned that a starting point for the language design was typed, functional Lua and that motivation shows up in the platform concept.
The main advantage it provides is restrictions. Roc cannot perform any side effects outside the ones provided by the platform and has no provision for unsafe behavior. This allows for very aggressive inlining at the language level which winds up being pretty close to what I've done with macros and compile time programming in other languages. In terms of system design, you can know that the app code can't break the abstraction boundary and design accordingly. I made an experimental web platform that had full and automatic cache invalidation which worked off a combination of sqlx-style compile time inspection of queries combined with SQLite's security hook callbacks and I never would have done the design without having to deal with platform design. Neither of these are doable if the entire thing is in Rust.
asibahi 22 hours ago [-]
My understanding is the idea is that Roc is safer/more pleasant to use than the language you'd right the platform is. Also you could just use someone else's platform.
Someone in this thread described it an app framework that provides the IO primitives.
I have not used Roc at all just my impression of what's going on
marcelr 22 hours ago [-]
With a platform, your application code remains pure functional, while a minimal imperative shell can be understood and maintained separately
Using zig or rust or something you lose the roc specific features of a high performance pure functional language
Much better than FFI where usage is not tracked in the type system
ifh-hn 22 hours ago [-]
I think my main point is that to use roc for anything I need to know roc and a second language. Or import the functionality written in that secondary language. I'm aware that you do this with other languages, pandas and numpy aren't written in python, I really just don't get why rocs way is better...
niclas-ahden 21 hours ago [-]
>I think my main point is that to use roc for anything I need to know roc and a second language
You could just pick up Roc, pick a platform, and start writing Roc right away without knowing any other language :) There are already a number of platforms to use for CLI apps, web servers, web apps, native GUIs etc.
However, if you want to write your own platform you can. That's a great power to be able to reach for if you want to but it's not typical.
Going back to the JavaScript example: most JS developers just pick a platform, like Bun, and start writing JS. In the same way, you'd pick a Roc platform and start writing Roc.
Sure, if Bun wasn't good enough the JS dev may write their own platform (Bum? :P), and then they'd need a second language. That's the same thing you could do in Roc if you wanted a custom platform :)
Numeric1137 13 hours ago [-]
AFAIK there's two things.
1. The platform defines what effects your code can run. For certain use cases, it makes sense to have some but not the other. For example, a terminal app, a GUI, and a webserver need different primitives. Same with powering a UI for a smart fridge VS embedding into a text editor.
2. Most high level languages "drop down" to systems languages like C/C++ already, for example, Python.
> Might as well just use those languages to finish it off.
Different languages give you different things. Most people wouldn't want to write their entire app in C, for all the obvious reasons. Think about the Apache web server approach - it's a fast server written at the systems level, but passes the final piece off to whatever language you want. You can use a higher level language here for your business logic, without sacrificing all the speed.
At the end of the day, everything has to drop down to assembly to make a syscall, but that doesn't mean you want to write your whole app in assembly.
jkl5xx 1 days ago [-]
Been following Roc for awhile and really love a lot of the concepts (like Platforms). Got a bit nervous they were losing the thread when they went for a big rewrite, but it looks like it’s panning out!
stingraycharles 1 days ago [-]
Reminds me a lot of Elixir actually, which I really enjoyed but was, in the end, not fast enough.
The syntax looks friendly.
Does it have multiple dispatch for functions based on arguments? I always loved how easy that was to do in Haskell and Erlang/Elixir, and missed it in languages like Clojure.
masijo 1 days ago [-]
>missed it in languages like Clojure
I'm not sure about Haskell and Erlang/Elixir since I haven't used them much, but aren't multimethods the Clojure solution for this?
stingraycharles 1 days ago [-]
Not really, what Haskell / Erlang offer is that you can do pattern matching in the function signature.
So you can, say, have a definition for when the value of n is 0, n is 1, etc.
This is a nice example in Haskell:
compress :: Eq a => [a] -> [a]
compress [] = []
compress [x] = [x]
compress (x:ys@(y:_))
| x == y = compress ys
| otherwise = x : compress ys
Basically it enables you to use recursion more elegantly because the pattern matching is folded into the function signature.
wk_end 1 days ago [-]
So, for the sake of pedantry, in the programming language world "multiple dispatch" (and "[dynamic] dispatch" in general) typically refers to late binding - the function that's called is determined at runtime, and the caller doesn't actually need to know about the implementation being called.
What Haskell is doing there is basically just a kind of syntactic sugar around a pattern match, which is (to a very rough approximation) basically a super-powerful switch. Like a switch, the compress function knows about all of the branches statically, even if at runtime it dynamically selects which branch to take based on the structure of its arguments. And the structure of its arguments is "closed": it knows at compile-time all the different forms they can take.
Haskell achieves dynamic dispatch through typeclasses, and it can do multiple dispatch with the MultiParamTypeClasses extension. With these a caller doesn't need to know about the implementation it's invoking, and it doesn't need to know in advance anything about the possible values of its arguments beyond that they have an implementation that can be used - typeclasses are open, you can always define new implementations without updating every caller that uses them.
stingraycharles 1 days ago [-]
I agree with that, I tried to look for the correct term to describe this but the best thing I could find was multiple dispatch.
It's not just Haskell, though. Like I said, Erlang/Elixer also support this, and it enables writing some really elegant code.
jaspingrobus 1 days ago [-]
I think you can do this in Clojure:
(defn greet
([] "Hello!")
([name] (str "Hello, " name "!"))
([name title] (str "Hello, " title " " name "!")))
Which one could argue is cleaner for multiple arguments, but you can't pattern match on arguments themselves this way (but you can using multimethod)
stingraycharles 15 hours ago [-]
That’s just function arity, not actual pattern matching. Multimethods also aren’t pattern matching.
Congratulations.
Lots in there for a 0.1!
I hope Roc gathers serious momentum.
roblh 1 days ago [-]
Looks neat, it checks basically every box for desirable features from modern languages all in one. What about the age old question of function colouring? Whats the async story here, and between that and effectful functions, are you not setting yourself up for potentially 4 different colours? It seems like the effect functions would be likely to infect everything all the way up in a lot of different types of programs. But maybe there’s a more structural solution to that that I’m not aware of after just a glance.
rtfeldman 1 days ago [-]
The short answer is that it's like Go - Roc's effectful functions can be "silently nonblocking," so they can have the runtime characteristics of async without having to label functions as async (or call them with await).
That's why both Go and Roc are able to be competitive with languages that have async/await on webserver throughput benchmarks!
vipshek 1 days ago [-]
Very interesting. In practice, I wonder if most platforms will end up implementing some kind of async data structure to represent a deferred result? How have platforms generally approached this so far?
I think this question about how async/deferred results are handled will be a common one, and it was surprisingly hard to find any info about it in the docs. Maybe worth adding in a more obvious place?
The Platform concept feels incredibly powerful, but it feels like the Roc API each platform creates will be core to the ergonomics of using the language. Might be helpful to include docs from some of the most common platforms you expect folks to use to understand the end-to-end picture. The Stdout examples were helpful but I'd be curious to see others with more complexity.
theflyinghorse 1 days ago [-]
Where do you read the async specifications? I can't find much on the language site other than mentioning that "Roc application is built on exactly one platform, and that platform (not Roc's standard library) provides all of the application's I/O primitives" which is very confusing.
Fervicus 1 days ago [-]
I have been keeping an eye on this language. Maybe it's time to dive into it and give it a proper try. Any recommendations for good learning resources?
pil0u 1 days ago [-]
adventofcode.com starts tomorrow : )
Fervicus 23 hours ago [-]
Hopefully someone is doing a roc live stream :)
stronglikedan 1 days ago [-]
> Any recommendations for good learning resources?
"hey Claude, teach me Roc"
sondr3 1 days ago [-]
Maybe I should check this out for Advent of Code this year, would be fun to compare against Haskell which I usually use.
rtfeldman 1 days ago [-]
Awesome! There's an Advent of Code thread going on Roc Zulip with beginner advice that may be helpful:
Same! I was thinking this is perfectly timed for Advent of Code.
zem 16 hours ago [-]
I'd love to see a head to head comparison with ocaml, since roc seems to be targeting the same space and potentially the same users.
cma256 22 hours ago [-]
@rtfeldman Earlier in Roc's development it had a much stronger resemblance to Elm. Now it resembles Rust more strongly. My understanding is that this was driven by need and not aesthetic preference. Has the syntax for Roc stabilized? Will it change in the future? You're likely the most experienced Roc programmer in the world so I'd like to know if you find writing Roc to be a pleasant experience.
Edit: Happy for the 0.1.0 release. I look forward to using it!
lwboswell 19 hours ago [-]
I can answer this question... the syntax changes were driven from user experience and our goals for a fast/friendly/functional compiler. There are benefits for parsing if you use parens and commas for example. We tried many different designs looking for a good balance, simple tools that compose really nicely.
The syntax is now very stable and hasn't changed for a long time. Getting everything under that working really well, like the specialising pipeline or the native backends, and all the platform/package ecosystem has really been a bigger focus this year.
I've written a lot of Roc over the years, and I think the experience is wonderful.
lemming 21 hours ago [-]
What is Roc’s memory safety story? Is it pure GC, or does it do static analysis to bake manual memory management into the program in combination with reference counting, like Lobster or (I believe) Koka? Maybe I’m blind but I couldn’t see this in the doc after a quick scan.
jscully2 20 hours ago [-]
Reference counting plus a few efficiency tricks
culi 12 hours ago [-]
I wonder if Roc development is now in a rush since Elm development has seemingly resumed
This is kind of unfortunate for Roc because they were using the name first. But Rocq is a much bigger project so the mindshare is with them.
OskarS 1 days ago [-]
On the other hand, seems to me like theorem provers that aren’t called ”Lean” are having a pretty rough go of it as well.
andrewl-hn 1 days ago [-]
Hard to say. Lean has its moment right now in mathematics, but Rocq grows in verified software space thanks to early industrial success with a verified C compiler, OS kernel, etc. that received certifications for automotive. Iris - a Rocq framework for proving concurrent code - really blew up in recent years, too.
And it’s not a Zero-sum game: multiple languages for theorem proving and software verification can blossom and grow the overall field together. To me it seems like Rocq, TLA+, and Lean have very bright future.
I'm still pretty upset about Elm, and I'm not sure if that means I should avoid Roc or give Roc a try.
niclas-ahden 22 hours ago [-]
I was an avid Elm user, used it in several projects, and even recruited a great Elm developer to work with me. I was sad about the situation that ensued and had to move on to other languages. Now that Roc is here, I'm just so thoroughly happy. It's hard to put into words, but I was on the brink of quitting programming due to burnout (for different reasons), and Roc reinvigorated my joy of programming. Perhaps you can relate in some way? I can't say Roc will make the sun shine brighter, but I've really enjoyed writing Roc and being part of the community over the past years :) You're very welcome if you'd want to try it out!
culi 11 hours ago [-]
Elm's made 2 posts in 2026 about the roadmap to v1.0 btw
If it's the personality cult, the banning, the gaslighting, and the double standards? Then I would be hesitant about Roc since Feldman was doing a lot of the gaslighting and double standards.
If it was that it was that it's super dead, then Roc looks more promising. By a lot.
kunley 1 days ago [-]
Pretty bold claims, so, citation needed
ahf8Aithaex7Nai 1 days ago [-]
For those of us who witnessed that mess, no citation is necessary. I wish Roc all the best, but I’m not touching anything that comes from the people in Elm’s inner circle anymore. At least not until it has been made unmistakably and credibly clear that a change in mindset has taken place.
The downvotes speak for themselves! :-D
christophilus 1 days ago [-]
Didn’t downvote, but I’ve followed Richard Feldman off and on for a long time. He seems like a genuinely good guy. I think Roc is going well, and don’t think Elm’s history should influence anyone’s opinions about Roc.
boxed 12 hours ago [-]
If you are on the good side of bad people, they seem really nice. That's not how you tell if someone is nice.
boxed 1 days ago [-]
The trick with banning and deleting comments is that you get rid of the evidence.
I was personally banned without warning by a rule they made up to specifically target me after the fact. A rule which 100% applies to Feldman, but he was in the inner circle so obviously that rule didn't apply to him. It's still the only rule they explicitly have written down actually.
Yea, it is weird isn't it? I'm of the opinion that we NEED strong arguments in order to come to good conclusions. Banning people who care about technical details mean you only have people who don't care about technical details left and that's really not what you want for a programming language.
kunley 19 hours ago [-]
Yeah ok, so two questions:
- was Feldman a bad guy in the Elm story?
- he left Elm community 6 years ago, but the comment up here suggests he's bad guy also now, with Roc; that's the general impression, so, what is this about?
boxed 12 hours ago [-]
> - was Feldman a bad guy in the Elm story?
Yes.
> - he left Elm community 6 years ago, but the comment up here suggests he's bad guy also now, with Roc; that's the general impression, so, what is this about?
There are two types of second chances: redemption, and "fool me twice, shame on me". Normally the redemption arc implies the party articulates how they changed their mind. I haven't seen anything like this.
GortashWasRight 24 hours ago [-]
Maybe slightly off-topic, but I just realized how much I used to enjoy stuff like this.
I was a type astronaut by definition. I loved talking about higher-level abstractions, different programming paradigms, Monads, Scala, Haskell, all of it. With the rise of LLMs, it feels like none of that matters anymore, almost as if I poured a chunk of my life into something that lost its value overnight. A few years ago, I was super enthusiastic about Roc; nowadays, I wonder what my lead would think if I even casually mentioned migrating away from Go to it. It probably doesn't matter at all anymore.
sowhat1 23 hours ago [-]
Yep we need modern languages for agents, not humans. These would prioritize performance, lower token usage, etc. There would still be a lot of overlap with what humans want.
Numeric1137 13 hours ago [-]
At the end of the day, both humans and agents benefit from fast feedback loops
Kind of love the fact that Roc is fast,memory safe and compiles really fast.
This sort of combination is probably gonna take some developers. I have definitely heard of rust's compile time speed being a bottleneck in many aspects.
I want to know how to build cross-platform (preferably android,iOS as well with the normal linux,macOS and windows)applications with roc.
I just want something where I can easily and fastly iterate upon creating cross-platform applications. Waiting for rust to finish was a real issue that I sort of observed during one of my tinkering experiments.
Another thing that I am thinking right now is one Hackernews comment[0] that I had seen sometime ago which talked about having an android application (I think written in python), and they can basically change the code live and it will automatically reflect. I imagine that if roc is fast-enough, some sort of live development system could also be created.
Overall, I think that if AI can rewrite code or start writing code from scratch in almost any language good enough, then there are lots of experiments which can be conducted at scale which previously were not so feasible. Though one might ask what's the point as to the rewrite, I think that some of the features roc provides could be interesting to many sort of projects.
Also the language just looks elegant to me and more approachable than rust and C/C++ (from my first glance), so kudos for making a fast (functional) language which looks like something that I want to use myself!
> I want to know how to build cross-platform (preferably android,iOS as well with the normal linux,macOS and windows) applications with roc.
This is mediated by the Roc platform (i.e. app framework) and as for mechanics it works the same way the platform host language would work. I do have a Roc GUI platform written in Rust running on mac and android but it's built using just the OS drawing/input APIs and not using the rest of the platform's GUI stack so in practice they work closer to web apps with native performance/overhead. I've leaned into this so the apps are Elm Architecture, the styling is very similar to Tailwind, and things are generally web-app shaped. The LLMs are pretty good at web apps so the process of bringing up a new app is pretty straightforward.
Imustaskforhelp 1 days ago [-]
> This is mediated by the Roc platform (i.e. app framework) and as for mechanics it works the same way the platform host language would work. I do have a Roc GUI platform written in Rust running on mac and android but it's built using just the OS drawing/input APIs and not using the rest of the platform's GUI stack so in practice they work closer to web apps with native performance/overhead. I've leaned into this so the apps are Elm Architecture, the styling is very similar to Tailwind, and things are generally web-app shaped. The LLMs are pretty good at web apps so the process of bringing up a new app is pretty straightforward.
Is the app open source? I'd love to tinker around that.
But also, my question is that since it's using rust, wouldn't there be an issue of rust compilation coming into place perhaps once again?
And would there be any advantages in having a Roc UI framework whose rust layers could be extremely small if not nil perhaps (again, I am not too familiar with the internals of Roc as in how the Roc platform works which I still have to explore but still, suggesting this idea)
I just want fast cross-portable (small) apps with fast compile speed/iteration speed. Golang really fails in some sense and rust loses on the cross-portable part. I really want a language within this space, I am gonna explore roc for this but do you have any other languages in suggestion as well?
grayrest 23 hours ago [-]
> Is the app open source? I'd love to tinker around that.
It's open source [1] but not currently documented and therefore not "really" released. I've had several people ask me to just put it out without docs but not sure how useful it is to others.
> Since it's using rust, wouldn't there be an issue of rust compilation coming into place perhaps once again?
App-level use compiles Rust once up front and is then on the Roc iteration loop. If you're messing with the platform then there's the normal Rust compilation cycle which is dependent on how deep you're making changes in the crate dependency graph.
> would there be any advantages in having a Roc UI framework whose rust layers could be extremely small if not nil perhaps
There are several other Roc platforms attempting this. I believe the most developed is Terroccotta.
My project places the app/platform boundary at the "web browser" level because I have an alternate backend that allows apps to run in the browser using DOM/CSS/WASM. Anything that would be in the browser in a webapp is in the platform and a large fraction of the browser's feature set with regards to app development is implemented (flex/grid layout, text decoration, borders, shadows, transitions, animation, etc).
> do you have any other languages in suggestion as well?
I do not. I'm about 2000 hours and almost half a million lines of Rust+Roc into this project because I wanted something like Electron/Tauri that would run with native app perf/resource consumption and work on my android devices.
cptmurphy 1 days ago [-]
Why there are no managed typed effects? Only naming functions by convention
I mean typed algebraic effects. They are not tracked in types. I don't see how you can define a custom effect, you have only pure and not pure functions, how to type a specific side effect?
desireco42 18 hours ago [-]
Several people mentioned AI and sloppification, but let me say one thing. I use Gleam a lot and using languages like this with AI, especially using AI to write in them.
It takes AI a little bit longer, like multiples time longer, but when it writes code is rock solid and it's easier to follow because it's much smaller code base.
So I would say that there is huge benefits in using AI to write in languages like this and of course you can write it always the artisanal way anytime of whenever you want.
Plus codebase in Roc is much more pleasurable to examine and watch, even if you write it with AI,then anything you can produce in Typescript or Rust.
Mond_ 21 hours ago [-]
LET'S GOOOOOOOO
aaronvg 24 hours ago [-]
interested to see when concurrency primitives would launch
1: ELF 64-bit LSB pie executable, x86-64, version 1 (SYSV), static-pie linked, for NetBSD 8.0, BuildID[sha1]=f9032032100b247585d25c60741307495f94a094, stripped
8.1K 1
It seems that --no-cache does not work when using --target
rtfeldman 23 hours ago [-]
> 275.4M roc
The `roc` binary size is almost all LLVM (and a bit of LLD on top of that). The actual Roc-specific logic is a very small fraction of the binary's contents. (You can see this by going to roc-lang.org and looking at the compiler we use in there for the in-browser repl; it doesn't bundle LLVM or LLD and it's otherwise the entire compiler, and last time I checked it weighed in at about 5mb of wasm uncompressed.)
We plan to replace both LLVM and LLD with smaller alternatives, but we don't want to sacrifice performance of optimized Roc code, so the transition won't be quick.
esafak 1 days ago [-]
1. Do LLMs write it well?
2. What are the suggested substitutes for OOP idioms like interfaces?
grayrest 1 days ago [-]
> Do LLMs write it well?
Yes. Most if not all the examples in the community section of the post are LLM authored. A large part of the reason is because there's been breaking changes most weeks for months. This comes with the territory for a pre-0.1 language and the Roc team says they've put in all the breaking changes they had on the roadmap so hopefully with the increased stability of a numbered release we'll see more non-LLM projects.
The only thing I've particularly needed to kick the LLM on is error handling idioms. It reaches for `match` when something shorter would suffice.
> What are the suggested substitutes for OOP idioms like interfaces?
This is beyond the scope of a comment post but interfaces play an outsized role in most OOP system designs due to the need to nominally type everything in hierarchies. The closest mechanism would be using a `where` clause[1].
Sad this is probably one of the last projects we’ll see that are handcrafted and made with love instead of machines…
stock_toaster 1 days ago [-]
Nah, there are still dozens of us still making things by hand because we enjoy it!
I imagine there is a similar corollary where hobbyist woodworking didn't go away with the advent of assembly-line manufacturing.
dzonga 1 days ago [-]
rich is a nice guy. language makers called rich are nice people.
elm is where I learnt functional programming - concepts were easier to grasp for someone like me compared to oop.
sadly now with llms the art of programming languages might be forgotten since llms now write all the code n review it :(
rgoulter 1 days ago [-]
> sadly now with llms the art of programming languages might be forgotten since llms now write all the code
I've noticed that e.g. people who were JS devs before LLMs continue writing code in JS. Or Python in Python, and so on.
My experience with LLMs has been there's a vast difference between driving an LLM in a context you're familiar with, and an unfamiliar context. -- I can get an LLM to give me something pretty good if I know what to ask for, but I can only get an LLM to give me something okay-ish if I'm unfamiliar.
I tend to think programming languages & arguments will continue to matter just as much.
> [and LLMs do all the] review it :(
"LLMs are so strong that you won't need to read the code" I think this still allows that there should still be value in reading code.
I tend to think: an LLM is going to work more efficiently when the codebase is well organised compared to if it's disorganised.
I think that's more likely than, for example, "LLMs will be so good at coding, but only in a way that they produce unreadable spaghetti code that you can't understand". -- Surely if LLMs are so proficient at coding that you don't need to read the code, the LLM can also make the code easy to understand.
AeroNotix 1 days ago [-]
I think the unfortunate outcome will be that the aesthetics, organisation and other non-functional properties of code will no longer matter.
myth_drannon 1 days ago [-]
more like the art of programming languages for humans has less focus.
I certainly see an uptick in work on programming languages for AI/agents.
yewenjie 1 days ago [-]
I used to be super excited about Roc, around 2020 I guess. I distinctly remember at around GPT-3 thinking "alas, all this amazing developments in programming language design will never really matter in a few years".
master004 1 days ago [-]
How many more programming languages do we need?
brainzap 1 days ago [-]
create a new language but keeping the pipe characters, is a mystery to me
ahf8Aithaex7Nai 1 days ago [-]
I haven't been programming in Elm for a few years now (for unfortunate reasons), but I still use the pipe operators (and TEA).
rixed 12 hours ago [-]
What's wrong specifically with that character?
Rendered at 18:58:42 GMT+0000 (Coordinated Universal Time) with Vercel.
If you're into web apps and The Elm Architecture, then check out https://github.com/niclas-ahden/joy I built Joy so that I could use Roc on a daily basis for client work, and it's been awesome! Now it's growing into a full-stack web framework with full type-safety from the database to the browser. Hope you'll like it too! :D
If you're curious about Roc, then join us on the Zulip (https://roc.zulipchat.com/). Welcome in!
I'm not saying everyone should be doing this, but it was an opportunity for me to be able to use Roc while contributing a lot to the community. It did take a lot of work, but seeing where we are now, I'm thrilled with how it has turned out :)
Heh, I almost posted a link to a public-facing Roc app here, but that's not a great idea :P DM me on Zulip (https://roc.zulipchat.com/) if you want to see an example of an actual business running full-stack web apps in Roc!
Roc has been so pleasant to use considered it's still so early.
I've read elsewhere a comment by Richard where he said that naive programming in Roc should result in fast code. That is very true. I basically enforce software design and architecture that allow for speed, and I don't have to worry about finagling the language into running fast.
It's very well thought out.
As a result Bliss Writer is correct and stable software, even in beta. I have a large suite of E2E tests that spin up a real TUI and they almost never fail.
Who knew you could have the correctness of FP and speed.
Basically you can handle the errors you want to handle and propagate everything else upstream because the error value is a union of all propagated errors. In other (typed) languages you either need to handle all errors or map the different types into a single one.
I think new languages have more freedom than ever to be bold and take risks. We are not nearly so confined by culture or technical debt as we used to be and freedom to experiment has probably never been better.
The breadth of topics and how much they interplay is a lot more complicated than your typical software, and there's hundreds of small decisions you have to make along the way which you can only really understand how to design/steer if you understand the whole pipeline.
Your type system affects your syntax, and your syntax affects the complexity of types you can represent ergonomically, and your type system affects your runtime memory model and lowering, and so on and so on.
If you're willing to just let the LLM do all of the work and only judge it from the outside (observational correctness, but otherwise a black box), then sure, maybe you can get something. But I think that's:
1. going to lead to holes in your language design that you don't understand how to fix.
2. robbing you of the opportunity to learn. Learning design via one of the harder problems that exists, and also learning how to learn. You're forced to organize your approach to understanding the topics in a way that you can't just bruteforce components out of order and piecemeal unless you have an insane capacity to memorize things.
I’m saying the opportunity cost of trying new languages has never been lower.
all languages excel at something to the detriment of something else, no language can be good at everything.
the language also defines the terms for which you can reason about a problem.
even if you're not writing it, you're (hopefully) still reading it.
There's a good reason we're not writing web servers in assembly or SQL.
For me, there are 2 or 3 different levels to modeling what's going on. The first phase is the architecture; the second phase is the design, although some claim those two are merged. And then there's the modeling of the implementation, and that is driven by the programming language. Even though an LLM is generating all my code, I still read it; I still try to understand it so that when I debug it, I'm not going WTF quite as often.
The only difference is that now the offshoring team is out of luck, replaced by gremlins in the box.
I'm sure the same thing will happen to me after a while, like about a half hour from now.
It’s like calling clay pottery lumps of mud. Maybe technically accurate but you’ve lost the helpful nuance. Turns out people can shape and mold the slop into useful tools. At that point “slop” becomes less of a pejorative.
You could have a “nuanced” analysis of what the output is like. But there is no analysis to be had of where it came from. Like a car wholly made from stolen parts where no part has any serial number.
Pff.
> That absolutely has provenance here -- we can look at the 8 year history of this project, which of course predates mainstream agentic coding.
You would have to take that up with OP. The “slop” part, whether it started a week ago or a year ago, has no provenance.
Then how exactly can you or anyone else claim that the so-called slop (which clearly is so nebulous of a term that we need to debate said definition... Which probably means we shouldn't be throwing it around so casually...) was stolen? Saying something is stolen implies you know where the output actually came from.
You'll have to define "slop" then. For instance, code written by hand and then translated by an LLM has provenance, so is that slop?
If your definition of "slop" is "any generated code without provenance", then people can work to show provenance.
If your definition of "slop" is "any generated code" then the word is more of a shibboleth. And that's how people seem to use it, which is why I'm saying it's not useful anymore unless you're trying to promote an ideology.
I am always reluctant to try languages in their infancy though, not because of stability. I just don't know to what extent you can write sophisticated software such as a web server, a GUI application, etc.
I also notice that this Odin language is taking off. Never heard of it before but it's being used for the Rex client (superlogical) on Windows.
That is to say, I usually start paying attention when serious software is being made. (not a criticism of Roc though)
If it's any help, I've been writing "serious business apps" in Roc for the past two years, so you can already do quite a bit! I write mostly web apps and had to write my own web framework (https://github.com/niclas-ahden/joy) since it was such early days. I've been extracting and releasing as many packages as I can to help build out the ecosystem for people like you. I hope you'll have a great time when you decide to try it :)
If there's anything specific you need or are unsure about, post on https://roc.zulipchat.com/ and we'll help you!
I have been building an app platform on top of Rust for a few months, and have run into a series of problems and I sometimes wish I could use something more purely functional such as this. It offers a lot of guarantees that I want such as memory safety and side-effect-free code, and have had to try and build myself (probably poorly) in my own thing.
I am also glad to see to see that this language has addressed native code in a more robust way than Elm https://www.roc-lang.org/docs/main/langref/platforms/
Looking forward to trying this out and congrats to Evan and team on the release
You probably meant "congrats to Richard" who is Roc's BDFN (Benevolent Dictator for Now) https://www.roc-lang.org/bdfn
I'm pretty sure the BDFL of elm did not contribute to Roc.
I'd love to understand the point.
Another way to look at it is a practical comparison: JavaScript is a language, but it needs to run on something. If you run it in the browser, you get access to browser APIs. If you run it on the server with Node/Deno/Bun you get different APIs that are useful for web servers. In that scenario, the browser or Node/Deno/Bun is the platform.
The example above isn't apples-to-apples, but it's a good way to visualize the difference!
Does that help? :)
To me it just seems like roc can't function without other languages to make them useful.
Please don't take this on a bad way I'm just unable to describe it better.
Roc needs a platform written in another language, but you as a Roc author don't have to read or write that language. You don't even need to know which language a platform is written in.
Someone else (like me!) writes a platform, shares it, and you use it. That means you get whatever platform you want: maybe with the concurrency of Go? Or the performance of Zig? Or the memory safety of Rust? And the platform can give you access to their entire ecosystem. All that with no effort on your part, and you get to read and write only Roc. Sweet deal, right? ;D
Maybe it's just something I need to get used to.
Thanks for taking the time to explain though. If you're the guy that created the joy web framework (platform?) for roc, then I watched and enjoyed your talk about it.
Well, you could write your platform in a functional language :) What it is saying is that separating pure vs. effectful/impure comes with some nice benefits, and we're seeing that in the platforms concept. I think if you try it you may see it differently :)
>If you're the guy that created the joy web framework (platform?) for roc, then I watched and enjoyed your talk about it.
Yeah, that's me! Thank you so much! PS. I call it a "framework" just because it spans more than one platform. Not really an important :P
Exactly. At some point, your pure FP code has to hand off a description of some effect (open this file, make this network request, write to std out), otherwise all it can do is maybe heat up your computer.
The main advantage it provides is restrictions. Roc cannot perform any side effects outside the ones provided by the platform and has no provision for unsafe behavior. This allows for very aggressive inlining at the language level which winds up being pretty close to what I've done with macros and compile time programming in other languages. In terms of system design, you can know that the app code can't break the abstraction boundary and design accordingly. I made an experimental web platform that had full and automatic cache invalidation which worked off a combination of sqlx-style compile time inspection of queries combined with SQLite's security hook callbacks and I never would have done the design without having to deal with platform design. Neither of these are doable if the entire thing is in Rust.
Someone in this thread described it an app framework that provides the IO primitives.
I have not used Roc at all just my impression of what's going on
Using zig or rust or something you lose the roc specific features of a high performance pure functional language
Much better than FFI where usage is not tracked in the type system
You could just pick up Roc, pick a platform, and start writing Roc right away without knowing any other language :) There are already a number of platforms to use for CLI apps, web servers, web apps, native GUIs etc.
However, if you want to write your own platform you can. That's a great power to be able to reach for if you want to but it's not typical.
Going back to the JavaScript example: most JS developers just pick a platform, like Bun, and start writing JS. In the same way, you'd pick a Roc platform and start writing Roc.
Sure, if Bun wasn't good enough the JS dev may write their own platform (Bum? :P), and then they'd need a second language. That's the same thing you could do in Roc if you wanted a custom platform :)
1. The platform defines what effects your code can run. For certain use cases, it makes sense to have some but not the other. For example, a terminal app, a GUI, and a webserver need different primitives. Same with powering a UI for a smart fridge VS embedding into a text editor.
2. Most high level languages "drop down" to systems languages like C/C++ already, for example, Python.
> Might as well just use those languages to finish it off.
Different languages give you different things. Most people wouldn't want to write their entire app in C, for all the obvious reasons. Think about the Apache web server approach - it's a fast server written at the systems level, but passes the final piece off to whatever language you want. You can use a higher level language here for your business logic, without sacrificing all the speed.
At the end of the day, everything has to drop down to assembly to make a syscall, but that doesn't mean you want to write your whole app in assembly.
The syntax looks friendly.
Does it have multiple dispatch for functions based on arguments? I always loved how easy that was to do in Haskell and Erlang/Elixir, and missed it in languages like Clojure.
I'm not sure about Haskell and Erlang/Elixir since I haven't used them much, but aren't multimethods the Clojure solution for this?
So you can, say, have a definition for when the value of n is 0, n is 1, etc.
This is a nice example in Haskell:
Basically it enables you to use recursion more elegantly because the pattern matching is folded into the function signature.What Haskell is doing there is basically just a kind of syntactic sugar around a pattern match, which is (to a very rough approximation) basically a super-powerful switch. Like a switch, the compress function knows about all of the branches statically, even if at runtime it dynamically selects which branch to take based on the structure of its arguments. And the structure of its arguments is "closed": it knows at compile-time all the different forms they can take.
Haskell achieves dynamic dispatch through typeclasses, and it can do multiple dispatch with the MultiParamTypeClasses extension. With these a caller doesn't need to know about the implementation it's invoking, and it doesn't need to know in advance anything about the possible values of its arguments beyond that they have an implementation that can be used - typeclasses are open, you can always define new implementations without updating every caller that uses them.
It's not just Haskell, though. Like I said, Erlang/Elixer also support this, and it enables writing some really elegant code.
multi sub compress([]) { () }
multi sub compress([$x]) { $x }
multi sub compress([$x, @ys [$y, *]]) {
That's why both Go and Roc are able to be competitive with languages that have async/await on webserver throughput benchmarks!
I think this question about how async/deferred results are handled will be a common one, and it was surprisingly hard to find any info about it in the docs. Maybe worth adding in a more obvious place?
The Platform concept feels incredibly powerful, but it feels like the Roc API each platform creates will be core to the ergonomics of using the language. Might be helpful to include docs from some of the most common platforms you expect folks to use to understand the end-to-end picture. The Stdout examples were helpful but I'd be curious to see others with more complexity.
"hey Claude, teach me Roc"
https://roc.zulipchat.com/#narrow/channel/358903-advent-of-c...
Edit: Happy for the 0.1.0 release. I look forward to using it!
The syntax is now very stable and hasn't changed for a long time. Getting everything under that working really well, like the specialising pipeline or the native backends, and all the platform/package ecosystem has really been a bigger focus this year.
I've written a lot of Roc over the years, and I think the experience is wonderful.
And it’s not a Zero-sum game: multiple languages for theorem proving and software verification can blossom and grow the overall field together. To me it seems like Rocq, TLA+, and Lean have very bright future.
--
originally replied at the wrong level
https://elm-lang.org/news
If it's the personality cult, the banning, the gaslighting, and the double standards? Then I would be hesitant about Roc since Feldman was doing a lot of the gaslighting and double standards.
If it was that it was that it's super dead, then Roc looks more promising. By a lot.
The downvotes speak for themselves! :-D
There's more, you can just google "elm cult".
I was personally banned without warning by a rule they made up to specifically target me after the fact. A rule which 100% applies to Feldman, but he was in the inner circle so obviously that rule didn't apply to him. It's still the only rule they explicitly have written down actually.
[Edit:] Perhaps https://github.com/elm/forum-rules ? That actually is pretty weird!
- was Feldman a bad guy in the Elm story?
- he left Elm community 6 years ago, but the comment up here suggests he's bad guy also now, with Roc; that's the general impression, so, what is this about?
Yes.
> - he left Elm community 6 years ago, but the comment up here suggests he's bad guy also now, with Roc; that's the general impression, so, what is this about?
There are two types of second chances: redemption, and "fool me twice, shame on me". Normally the redemption arc implies the party articulates how they changed their mind. I haven't seen anything like this.
I was a type astronaut by definition. I loved talking about higher-level abstractions, different programming paradigms, Monads, Scala, Haskell, all of it. With the rise of LLMs, it feels like none of that matters anymore, almost as if I poured a chunk of my life into something that lost its value overnight. A few years ago, I was super enthusiastic about Roc; nowadays, I wonder what my lead would think if I even casually mentioned migrating away from Go to it. It probably doesn't matter at all anymore.
This sort of combination is probably gonna take some developers. I have definitely heard of rust's compile time speed being a bottleneck in many aspects.
I want to know how to build cross-platform (preferably android,iOS as well with the normal linux,macOS and windows)applications with roc.
I just want something where I can easily and fastly iterate upon creating cross-platform applications. Waiting for rust to finish was a real issue that I sort of observed during one of my tinkering experiments.
Another thing that I am thinking right now is one Hackernews comment[0] that I had seen sometime ago which talked about having an android application (I think written in python), and they can basically change the code live and it will automatically reflect. I imagine that if roc is fast-enough, some sort of live development system could also be created.
Overall, I think that if AI can rewrite code or start writing code from scratch in almost any language good enough, then there are lots of experiments which can be conducted at scale which previously were not so feasible. Though one might ask what's the point as to the rewrite, I think that some of the features roc provides could be interesting to many sort of projects.
Also the language just looks elegant to me and more approachable than rust and C/C++ (from my first glance), so kudos for making a fast (functional) language which looks like something that I want to use myself!
[0]: https://news.ycombinator.com/item?id=50678306
This is mediated by the Roc platform (i.e. app framework) and as for mechanics it works the same way the platform host language would work. I do have a Roc GUI platform written in Rust running on mac and android but it's built using just the OS drawing/input APIs and not using the rest of the platform's GUI stack so in practice they work closer to web apps with native performance/overhead. I've leaned into this so the apps are Elm Architecture, the styling is very similar to Tailwind, and things are generally web-app shaped. The LLMs are pretty good at web apps so the process of bringing up a new app is pretty straightforward.
Is the app open source? I'd love to tinker around that.
But also, my question is that since it's using rust, wouldn't there be an issue of rust compilation coming into place perhaps once again?
And would there be any advantages in having a Roc UI framework whose rust layers could be extremely small if not nil perhaps (again, I am not too familiar with the internals of Roc as in how the Roc platform works which I still have to explore but still, suggesting this idea)
I just want fast cross-portable (small) apps with fast compile speed/iteration speed. Golang really fails in some sense and rust loses on the cross-portable part. I really want a language within this space, I am gonna explore roc for this but do you have any other languages in suggestion as well?
It's open source [1] but not currently documented and therefore not "really" released. I've had several people ask me to just put it out without docs but not sure how useful it is to others.
[1] https://github.com/grayrest/kite
> Since it's using rust, wouldn't there be an issue of rust compilation coming into place perhaps once again?
App-level use compiles Rust once up front and is then on the Roc iteration loop. If you're messing with the platform then there's the normal Rust compilation cycle which is dependent on how deep you're making changes in the crate dependency graph.
> would there be any advantages in having a Roc UI framework whose rust layers could be extremely small if not nil perhaps
There are several other Roc platforms attempting this. I believe the most developed is Terroccotta.
My project places the app/platform boundary at the "web browser" level because I have an alternate backend that allows apps to run in the browser using DOM/CSS/WASM. Anything that would be in the browser in a webapp is in the platform and a large fraction of the browser's feature set with regards to app development is implemented (flex/grid layout, text decoration, borders, shadows, transitions, animation, etc).
> do you have any other languages in suggestion as well?
I do not. I'm about 2000 hours and almost half a million lines of Rust+Roc into this project because I wanted something like Electron/Tauri that would run with native app perf/resource consumption and work on my android devices.
https://www.roc-lang.org/docs/main/langref/functions/#effect...
It takes AI a little bit longer, like multiples time longer, but when it writes code is rock solid and it's easier to follow because it's much smaller code base.
So I would say that there is huge benefits in using AI to write in languages like this and of course you can write it always the artisanal way anytime of whenever you want.
Plus codebase in Roc is much more pleasurable to examine and watch, even if you write it with AI,then anything you can produce in Typescript or Rust.
I tried Linux x86_64
No glibc, I'm using musl
https://github.com/roc-lang/roc/releases/download/0.1.0/roc-...
275.4M roc
roc: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), statically linked, stripped
By comparison the size of the musl GCC toolchain I use is 242.3M
I've also used a static LLVM toolchain which is 328.8M
https://github.com/rsms/llvmbox/releases/expanded_assets/v15...
roc build --no-cache 1.roc; strip -s 117.5K 1 (with --opt=size result was 18.0K)
1: ELF 64-bit LSB pie executable, x86-64, version 1 (SYSV), static-pie linked, BuildID[sha1]=f44ebb81e1e06241ebccd8bb27a6e78dc07b9336, stripped
roc build --no-cache --opt=size --target=x64v1netbsd 1.roc; strip -s 1
1: ELF 64-bit LSB pie executable, x86-64, version 1 (SYSV), static-pie linked, for NetBSD 8.0, BuildID[sha1]=f9032032100b247585d25c60741307495f94a094, stripped
8.1K 1
It seems that --no-cache does not work when using --target
The `roc` binary size is almost all LLVM (and a bit of LLD on top of that). The actual Roc-specific logic is a very small fraction of the binary's contents. (You can see this by going to roc-lang.org and looking at the compiler we use in there for the in-browser repl; it doesn't bundle LLVM or LLD and it's otherwise the entire compiler, and last time I checked it weighed in at about 5mb of wasm uncompressed.)
We plan to replace both LLVM and LLD with smaller alternatives, but we don't want to sacrifice performance of optimized Roc code, so the transition won't be quick.
2. What are the suggested substitutes for OOP idioms like interfaces?
Yes. Most if not all the examples in the community section of the post are LLM authored. A large part of the reason is because there's been breaking changes most weeks for months. This comes with the territory for a pre-0.1 language and the Roc team says they've put in all the breaking changes they had on the roadmap so hopefully with the increased stability of a numbered release we'll see more non-LLM projects.
The only thing I've particularly needed to kick the LLM on is error handling idioms. It reaches for `match` when something shorter would suffice.
> What are the suggested substitutes for OOP idioms like interfaces?
This is beyond the scope of a comment post but interfaces play an outsized role in most OOP system designs due to the need to nominally type everything in hierarchies. The closest mechanism would be using a `where` clause[1].
[1] https://roc-lang.org/docs/main/langref/static-dispatch/#wher...
I imagine there is a similar corollary where hobbyist woodworking didn't go away with the advent of assembly-line manufacturing.
elm is where I learnt functional programming - concepts were easier to grasp for someone like me compared to oop.
sadly now with llms the art of programming languages might be forgotten since llms now write all the code n review it :(
I've noticed that e.g. people who were JS devs before LLMs continue writing code in JS. Or Python in Python, and so on.
My experience with LLMs has been there's a vast difference between driving an LLM in a context you're familiar with, and an unfamiliar context. -- I can get an LLM to give me something pretty good if I know what to ask for, but I can only get an LLM to give me something okay-ish if I'm unfamiliar.
I tend to think programming languages & arguments will continue to matter just as much.
> [and LLMs do all the] review it :(
"LLMs are so strong that you won't need to read the code" I think this still allows that there should still be value in reading code.
I tend to think: an LLM is going to work more efficiently when the codebase is well organised compared to if it's disorganised.
I think that's more likely than, for example, "LLMs will be so good at coding, but only in a way that they produce unreadable spaghetti code that you can't understand". -- Surely if LLMs are so proficient at coding that you don't need to read the code, the LLM can also make the code easy to understand.