See class Integer
:
Integer.class
=> Class
It also seems like it's a method, at the same time it's a class:
Integer 10.5
=> 10
How is this possible in Ruby? Where is this method defined? What mechanisms does Ruby use to know if I'm calling the method or the class?