Fixed core/data structure for builder.

- Was not consistent, and would not have worked without
  the proto extension registry.