Refactored core_ext