anchor.diff:      %% save also the unprocessed parse results.
       [#'DescriptorProto'{
           name            = atom_to_ustring(MsgName),
  -        field           = field_defs_to_mgstype_fields(Fields),
  +        field           = field_defs_to_mgstype_fields(Fields, AllOneofs),
           extension       = [],
           nested_type     = [],
           enum_type       = [],
           extension_range = [],
  -        options         = undefined
  +        options         = undefined,
  +        oneof_decl      = oneof_decl(AllOneofs)
          }
        || {{msg,MsgName}, Fields} <- Defs].
   
  -field_defs_to_mgstype_fields(Fields) ->
  +field_defs_to_mgstype_fields(Fields, AllOneofs) ->
  +    lists:append([field_def_to_msgtype_field(Field, AllOneofs)
  +                  || Field <- Fields]).
  +
  +field_def_to_msgtype_field(#?gpb_field{name=FName,
  +                                       fnum=FNum,
  +                                       type=Type,
  +                                       occurrence=Occurrence,
  +                                       opts=Opts}=Field,
  +                           _AllOneofs) ->
       [#'FieldDescriptorProto'{
           name          = atom_to_ustring(FName),
           number        = FNum,
  
positive.code:        source_code_info = undefined  %% #'SourceCodeInfo'{} | undefined
        }.
  
  defs_to_package(Defs) ->
      %% There can be at most 1 package definition
      %% The parser will reject any multiple package definitions
  
negative.code:                  || {EName, EValue} <- Enumerators]}
       || {{enum,EnumName}, Enumerators} <- Defs].
  
  oneof_decl(AllOneofs) ->
      [#'OneofDescriptorProto'{name=atom_to_ustring(Name)} || Name <- AllOneofs].
  
  atom_to_ustring(A) ->
      Utf8Str = atom_to_list(A),
      unicode:characters_to_list(list_to_binary(Utf8Str), utf8).
  