How to show Elixir to Scala Programmers?

Technically it’s a Scheme and I don’t know if you like its type system but you may want to have a look at Typed Racket.



Interesting.I wonder if we could do such thing in LFE.

1 Like

We could, but do we want to?


Unless you are volunteering - I would’t hold my breath (post):

And I must say that personally type errors are the errors I very rarely make. :smile:

And frankly “programmers” should be comfortable in both statically and dynamically typed languages.

People favouring statically typed languages need to experience the “freedom” that a dynamically typed language can offer - granted that comes at the cost of increased “risk” (of undetected errors) and decreased tooling convenience (refactoring support, catching silly errors early). Sometimes I wonder whether this “demand” for static typing has less to do with type safety and more with the dependency on IDE tool support (which exploits type information).

People favouring dynamically typed languages need to occasionally work in a language with a real type system to train themselves to think in terms of types or “type constraints” - ultimately your code places certain constraints on the “types” that it can deal with and it helps to keep these “virtual types” explicitly in mind even if they don’t explicitly appear in the code.

1 Like

Considering I often program in remote VIM sessions over SSH, entirely for type safety for me. :slight_smile:

Specifically, a decent type system can make making impossible states literally impossible, meaning you never ever have to worry about it. :slight_smile:

On the other hand, nothing stops you from passing a keyword list to a function expecting a map in erlang/elixir, then at runtime boom. :wink:

Dialyzer helps a lot of course, but it does not stop you from making what should be an impossible state truly impossible in code.

1 Like

Maybe we could have an optional lfe_typed? :smiley:

1 Like

I still hold by my quote, I seldom make type errors. And when I do make them they are the easiest to find and fix. I have doing some work with c# and LFE and the strict typing in c# is the least of my problems, it is nothing compared to some of the really weirdo code you see.

I find that I generally know which types I am working so even when I am using lists for example I know what it is a list of. Same with tuples and maps etc. The solution to the problem determines what types we are using.

This means that I find little use for polymorphic modules like Enum as I KNOW which type of enumerations I am using, again the solution to the problem determines this, so I much prefer to use the type specific functions instead. So instead of I prefer lists:map or maps:map. It makes it easier to understand what is going on.

Anyway this is why I think I make relatively few type errors. Enough swearing in church. :grinning:

EDIT: This has very little to do with elixir and scala programmers :wink:


They are, but when it happens at a bad time when it should have been caught at compile-time… :wink:

Oh toss out C#! If you are doing .NET work use F#. :slight_smile:
Being based on OCaml it is typesafe, but you don’t specify types. :wink:

Yeah I entirely agree here, I often use the direct list or map modules instead of enum when they have what I need (self-documenting code after all).


1 Like

I quote:

The Java Way

In 1995, Java was released. It was some kind of revolution. You probably know why, but I’d like to explain my vision of that fact. Here is a list of Java killer features:

  • Runs on any platform (of course JVM is required).
  • A code written once runs anytime (backward compatibility).
  • Garbage collector (no need to manage a memory).
  • Classical object-oriented paradigm.
  • Syntax (almost the same as in C++).

This was all possible for some decades on Smalltalk.
Garbage collection was invited by Lisp and to call the C++ syntax revolutionary seems questionable.
Smalltalk is still today fully implemented in object-oriented ways, while Java is not.

This is exactly the kind of attitude, which lets me vomit to be honest.
Nothing new, nothing innovative, besides repeating crappy concepts - since they are popular at the manager level - and destroying what already works since decades.
Then promoting the own genius based on the work of others and calling it revolutionary.

1 Like

You might like mosh.

1 Like

Already have it installed, though almost never use it… ^.^;

1 Like