以下截錄:
Developers coding in one of the 5 most popular languages (Java, C, C++, PHP, Ruby) are most likely to switch to Python with approx. 22% chance on average.
Besides, according to Erik’s matrix, people switch from Ojective-C to Swift and back with greater probabilities - 24% and 19% accordingly.
Similarly, a Visual Basic developer has more chance (24%) to move to C# while Erik’s is almost sure in this transition with 92% chance.
Users of Clojure, C# and, above all, Scala would rather switch to Java with respectively 22, 29 and 40% chance.
People using numerical and statistical environments such as Fortran (36 %), Matlab (33 %) or R (40 %) are most likely to switch to Python in contrast to Erik’s matrix which predicts C as their future language.
One common point I found with Erik’s results about Go is that it attracts people who gave up studying Rust.
看一看 spring application 就是一堆 annotation 堆起來的,不管是什麼 JVM 語言。 所以這比較變得有點沒意義 (比哪個語言 annotation 怎麼擺嗎?)
annotation annotation
web --------------> model ---------------> database
只要 model 夾在中間,上下的連接處都還是要處理,以前是 xml,現在是 annotation,有些 functional 語言會用 function 接,但其實只是不同寫法而已。
語言本身真正能使上力的,還是 model 本身的撰寫,這裡才是能較量的所在。
Red Hat 一直都不贊成啊,詳情可以看一下這篇 InfoQ 報導1
倒是沒想到這次 IBM 居然投贊成票...
我猜跟 Proposal: Allow illegal reflective access by default in JDK 91 有關?
JDK 9 預設會用 --illegal-access=permit
,這樣行為就跟之前一樣,等於是多給大家兩年來 migrate 自己的 application...
其實 scala 就有了,現在 kotlin 語法一大半源也是自於它。前幾年 Java 開發者也是峰湧到 scala 去,那時的開發者就有差不多的經驗吧。
但是 Scala 難寫難懂,紅沒多久又被大家放掉了。語言功能多又強,但找不到合適的平衡,沒有有力的後盾,沒有 commitment,最終那些功能都是白作功,沒人用。
sealed class Event
data class BroadCastEvent(
val payload: Payload
): Event()
data class OneToOneEvent(
val destination: Destination,
val payload: Payload,
val secret:Boolean = false
): Event()
然後在 messenger.send 這個 function 做 pattern matching
這樣就只有在 OneToOne 的時候才能使用 secret 選項,不會寫錯
這個設計還是會發生像下面的呼叫:
messenger.send(Topic("foo"), Text("secret"), OneToOneOption(secret=true))
然後 runtime 時就爆了