Migrate code to use e4c internally