anchor.diff:        if (wireNameMapping.isEmpty) {
           // No wire names. Just use the enum names directly.
           return '''
  -class _\$${name}Serializer implements PrimitiveSerializer<$genericName> {
  +class $serializerImplName implements PrimitiveSerializer<$genericName> {
     @override
     final Iterable<Type> types = const <Type>[$name];
     @override
  
positive.code:   CompilationUnitElement get compilationUnit =>
        element.library.definingCompilationUnit;
  
    Iterable<String> computeErrors() {
      var result = <String>[];
  
      if (!serializerSettings.custom) {
        final camelCaseName =
            name.substring(0, 1).toLowerCase() + name.substring(1);
  
        final expectedSerializerDeclaration =
            'static Serializer<$genericName> get serializer => '
            '_\$${camelCaseName}Serializer;';
        // We used to recommend raw types; recommend the full type now, but still
        // allow raw types.
        final expectedSerializerDeclarationRaw =
            'static Serializer<$name> get serializer => '
            '_\$${camelCaseName}Serializer;';
        if (serializerDeclaration != expectedSerializerDeclaration &&
            serializerDeclaration != expectedSerializerDeclarationRaw) {
          result.add('Declare $name.serializer as: '
  
negative.code:          };''';
  
          return '''
  class $serializerImplName implements PrimitiveSerializer<$genericName> {
    $toWire
    $fromWire
  
  