Skip to content

Commit

Permalink
edit readme.
Browse files Browse the repository at this point in the history
  • Loading branch information
MoserMichael committed Feb 7, 2021
1 parent 3c072a3 commit 35e50ef
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
5 changes: 3 additions & 2 deletions README-eof.md.template
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ On the downside: kotlin doesn't have a pattern matching feature similar to that

Overall there are quite a lot of changes in JDK land. Some ten years ago Java seemed to be old and settled in its ways, now suddenly everything looks quite different - when I look at it after a ten years brake

Also I learned that Scala is adding a lot of information into the bytecode by adding it's own annotation: scala.reflect.ScalaSignature - this annotation takes the signature type and pickles it into the annotation text. quite a hack that allows to make the scala language more expressive as type information about the added features is pushed into this annotation, however it doesn't help with java interoperability. See [link](https://stackoverflow.com/questions/29267199/what-is-a-scalasignature). I think that's an interesting detail of the jdk language wars....
Also I learned that Scala is adding a lot of type information into the bytecode, scala has a type system that has more features than java; this is done by adding its own annotation class: scala.reflect.ScalaSignature - the scala compiler uses this annotation to encode the scala signature in pickled form, so that the annotation value includes binary data. This is a bit of a hack that allows to make the scala language more expressive, as type information about the added features is pushed into this annotation, however it doesn't help with java interoperability. See [link](https://stackoverflow.com/questions/29267199/what-is-a-scalasignature). I think that's an interesting detail of the jdk language wars.

Also interesting that all the newer languages like Scala and Kotlin are all getting rid of Java primitive types like int and long; in both Scala and Kotlin everything is an object. Now this change apparentlty makes it impossible to have compact in memory data structures: without primitive types each class member becomes a reference to a different object! That would result in much more processor cache misses in stuff written in the newer jdk languages.

Also interesting that all the newer languages like Scala and Kotlin are all getting rid of Java primitive types like int and long; in both Scala and Kotlin everything is an object. Now it will be more difficult to have compact data structures without primitive types, as each object field has to carry the otherhead of being an Object; I don't know if that makes much of a difference in this niche: right now one would still try to stick with languages that don't need garbage collection for performance critical stuff
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -668,6 +668,7 @@ On the downside: kotlin doesn't have a pattern matching feature similar to that

Overall there are quite a lot of changes in JDK land. Some ten years ago Java seemed to be old and settled in its ways, now suddenly everything looks quite different - when I look at it after a ten years brake

Also I learned that Scala is adding a lot of information into the bytecode by adding it's own annotation: scala.reflect.ScalaSignature - this annotation takes the signature type and pickles it into the annotation text. quite a hack that allows to make the scala language more expressive as type information about the added features is pushed into this annotation, however it doesn't help with java interoperability. See [link](https://stackoverflow.com/questions/29267199/what-is-a-scalasignature). I think that's an interesting detail of the jdk language wars....
Also I learned that Scala is adding a lot of type information into the bytecode, scala has a type system that has more features than java; this is done by adding its own annotation class: scala.reflect.ScalaSignature - the scala compiler uses this annotation to encode the scala signature in pickled form, so that the annotation value includes binary data. This is a bit of a hack that allows to make the scala language more expressive, as type information about the added features is pushed into this annotation, however it doesn't help with java interoperability. See [link](https://stackoverflow.com/questions/29267199/what-is-a-scalasignature). I think that's an interesting detail of the jdk language wars.

Also interesting that all the newer languages like Scala and Kotlin are all getting rid of Java primitive types like int and long; in both Scala and Kotlin everything is an object. Now this change apparentlty makes it impossible to have compact in memory data structures: without primitive types each class member becomes a reference to a different object! That would result in much more processor cache misses in stuff written in the newer jdk languages.

Also interesting that all the newer languages like Scala and Kotlin are all getting rid of Java primitive types like int and long; in both Scala and Kotlin everything is an object. Now it will be more difficult to have compact data structures without primitive types, as each object field has to carry the otherhead of being an Object; I don't know if that makes much of a difference in this niche: right now one would still try to stick with languages that don't need garbage collection for performance critical stuff

0 comments on commit 35e50ef

Please sign in to comment.