Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I think a common misconception amongst many scala developers, those at EPFL (and yourself, Kevin) is that <em>"scala is a simple language"</em>. The argument usually goes something like this:</p> <ul> <li>scala has <strong>few keywords</strong></li> <li>scala reuses the same <strong>few constructs</strong> (e.g. <em>PartialFunction syntax</em> is used as the body of a catch block) </li> <li>scala has a few <strong>simple rules</strong> which allow you to create library code (which may appear as if the language has special keywords/constructs). I'm thinking here of implicits; methods containing colons; allowed identifier symbols; the equivalence of <code>X(a, b)</code> and <code>a X b</code> with extractors. And so on</li> <li>scala's <strong>declaration-site</strong> variance means that the type system just gets out of your way. No more wildcards and <code>? super T</code></li> </ul> <p>My personal opinion is that <strong>this argument is completely and utterly bogus</strong>. Scala's type system taken together with implicits allows one to write <a href="https://github.com/svn2github/old-scalaz/blob/master/continuous/2010-01-02%2B8321.4049s/example/scalaz/ExampleKleisli.scala" rel="nofollow noreferrer">frankly impenetrable code for the <em>average</em> developer</a>. Any suggestion otherwise is just preposterous, regardless of what the above "metrics" might lead you to think. (<em>Note here that those who I've seen scoffing at the non-complexity of Java on Twitter and elsewhere happen to be uber-clever types who, it sometimes seems, had a grasp of monads, functors and arrows before they were out of short pants</em>).</p> <p>The obvious arguments against this are (of course):</p> <ol> <li>you don't <em>have</em> to write code like this</li> <li>you don't have to pander to the <em>average</em> developer</li> </ol> <p>Of these, it seems to me that only #2 is valid. Whether or not you write code quite as complex as <a href="https://github.com/scalaz/scalaz" rel="nofollow noreferrer">scalaz</a>, I think it's just silly to use the language (and continue to use it) with no real understanding of the type system. How else can one get the best out of the language?</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload