DEV Community

Discussion on: Everything is an Object!

Collapse
 
craigbrad profile image
Craig Bradley • Edited

I'm not trying to explain the differences between statically/dynamically typed languages. This is more of a general observation and may not be true for every static/dynamic language and yes, I know Java is statically typed (Not sure what your point is here). My point was - Not everything in statically typed languages are objects, they can't be unless you remove primitives. i.e types are checked at compile time, no objects exist at compile time.

Again, Method objects represent a given method. They're some variation of a Proc that wrap the underlying implementation. This is a nicety that ruby has, allowing you to pass around a wrapped method.