isTrait() is only available in >= 5.4