Updated #safe to not blow up JRuby and Rubinius.
Updated #behavior to support subclassing and module includes.