2 ms·
This looks awesome! Two questions: 1. How does process failure and recovery work? 2. Are there any plans to add binary patterns? That's one thing I'm sure I
by panic 11y ago
This looks awesome! Two questions:
1. How does process failure and recovery work?
2. Are there any plans to add binary patterns? That's one thing I'm sure I'd miss from Erlang if I wanted to write a server in this language.
- 0cachecoherency 11y ago1. Because Pony is both type and exception safe, actors (the Pony equivalent of an Erlang process) don't fail in the catastrophic sense. Right now, if an actor wants to report that it can't go on to some other actor, it just sends out messages. Obviously, we are big fans of Erlang, and big fans of the Erlang supervisor pattern, so we'll be writing a Pony package that puts a nice interface around this. 2. Yes! Pony has first class pattern matching already (along with algebraic data types, i.e. tuple types, union types, and intersection types, to make pattern matching really useful). It allows matching both on type and on standard or programmer defined structural equality. As I mentioned, we're big Erlang fans, so we definitely won't ignore stuff like this.
- al2o3cr 11y ago"actors don't fail in the catastrophic sense" Bonus: if this language thing doesn't work out you can just pivot to selling the unlimited-resource and failure-free hardware and operating system you've invented... Snark aside, a system that always assumes "clean shutdown" is going to massively simpler to design. It's also going to be unusable in real-world environments.