Sure, but this isn't all that different than what you get with "tags" (dynamic types) in a dynamically-typed language, even if some of those languages have some construct for runtime type testing (Erlang doesn't, but has pattern matching which seems to provide more than dynamtic-type-testing-specific functionality would.)
If the complaint is just Erlang-lacks-static-typing, I can agree that that's a fact, but I don't see how what Erlang does give you is less useful (even though the particular structure is different) than what you get in other languages that lack static typing.
"but I don't see how what Erlang does give you is less useful (even though the particular structure is different) than what you get in other languages that lack static typing."
Well, this gets into quasi-religious debates about type systems. All I can really do is point you to the Python or Ruby class systems and ask you to compare it to Erlang. And also observe that I'm pretty tired of dynamic typing in general, and Erlang is even farther in the direction that I'm tired of than Python/Ruby/etc.
Erlang has static types, they're just (a) always open and (b) always optional. It's more or less the most dynamic static typing regime imaginable. In personal use, it's highly valuable from a documentation standpoint, but does almost nothing for safety or restricting abuse of power.
Comments
Sure, but this isn't all that different than what you get with "tags" (dynamic types) in a dynamically-typed language, even if some of those languages have some construct for runtime type testing (Erlang doesn't, but has pattern matching which seems to provide more than dynamtic-type-testing-specific functionality would.)
If the complaint is just Erlang-lacks-static-typing, I can agree that that's a fact, but I don't see how what Erlang does give you is less useful (even though the particular structure is different) than what you get in other languages that lack static typing.
"but I don't see how what Erlang does give you is less useful (even though the particular structure is different) than what you get in other languages that lack static typing."
Well, this gets into quasi-religious debates about type systems. All I can really do is point you to the Python or Ruby class systems and ask you to compare it to Erlang. And also observe that I'm pretty tired of dynamic typing in general, and Erlang is even farther in the direction that I'm tired of than Python/Ruby/etc.
Erlang has static types, they're just (a) always open and (b) always optional. It's more or less the most dynamic static typing regime imaginable. In personal use, it's highly valuable from a documentation standpoint, but does almost nothing for safety or restricting abuse of power.
Here's a recent Erlang type annoyance:
Given two tuples with 3 integers, {X, Y, Z}, without knowing it a priori, you can't tell which one is an erlang:now() and which is an erlang:date().