// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: compiler/ir/serialization.common/src/KotlinIr.proto

package org.jetbrains.kotlin.backend.common.serialization.proto;

/**
 * Protobuf type {@code org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase}
 */
public final class IrFunctionBase extends
    org.jetbrains.kotlin.protobuf.GeneratedMessageLite implements
    // @@protoc_insertion_point(message_implements:org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase)
    IrFunctionBaseOrBuilder {
  // Use IrFunctionBase.newBuilder() to construct.
  private IrFunctionBase(org.jetbrains.kotlin.protobuf.GeneratedMessageLite.Builder builder) {
    super(builder);
    this.unknownFields = builder.getUnknownFields();
  }
  private IrFunctionBase(boolean noInit) { this.unknownFields = org.jetbrains.kotlin.protobuf.ByteString.EMPTY;}

  private static final IrFunctionBase defaultInstance;
  public static IrFunctionBase getDefaultInstance() {
    return defaultInstance;
  }

  public IrFunctionBase getDefaultInstanceForType() {
    return defaultInstance;
  }

  private final org.jetbrains.kotlin.protobuf.ByteString unknownFields;
  private IrFunctionBase(
      org.jetbrains.kotlin.protobuf.CodedInputStream input,
      org.jetbrains.kotlin.protobuf.ExtensionRegistryLite extensionRegistry)
      throws org.jetbrains.kotlin.protobuf.InvalidProtocolBufferException {
    initFields();
    int mutable_bitField0_ = 0;
    org.jetbrains.kotlin.protobuf.ByteString.Output unknownFieldsOutput =
        org.jetbrains.kotlin.protobuf.ByteString.newOutput();
    org.jetbrains.kotlin.protobuf.CodedOutputStream unknownFieldsCodedOutput =
        org.jetbrains.kotlin.protobuf.CodedOutputStream.newInstance(
            unknownFieldsOutput, 1);
    try {
      boolean done = false;
      while (!done) {
        int tag = input.readTag();
        switch (tag) {
          case 0:
            done = true;
            break;
          default: {
            if (!parseUnknownField(input, unknownFieldsCodedOutput,
                                   extensionRegistry, tag)) {
              done = true;
            }
            break;
          }
          case 10: {
            org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase.Builder subBuilder = null;
            if (((bitField0_ & 0x00000001) == 0x00000001)) {
              subBuilder = base_.toBuilder();
            }
            base_ = input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase.PARSER, extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom(base_);
              base_ = subBuilder.buildPartial();
            }
            bitField0_ |= 0x00000001;
            break;
          }
          case 16: {
            bitField0_ |= 0x00000002;
            nameType_ = input.readInt64();
            break;
          }
          case 26: {
            if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
              typeParameter_ = new java.util.ArrayList<org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter>();
              mutable_bitField0_ |= 0x00000004;
            }
            typeParameter_.add(input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter.PARSER, extensionRegistry));
            break;
          }
          case 34: {
            org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.Builder subBuilder = null;
            if (((bitField0_ & 0x00000004) == 0x00000004)) {
              subBuilder = dispatchReceiver_.toBuilder();
            }
            dispatchReceiver_ = input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.PARSER, extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom(dispatchReceiver_);
              dispatchReceiver_ = subBuilder.buildPartial();
            }
            bitField0_ |= 0x00000004;
            break;
          }
          case 42: {
            org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.Builder subBuilder = null;
            if (((bitField0_ & 0x00000008) == 0x00000008)) {
              subBuilder = extensionReceiver_.toBuilder();
            }
            extensionReceiver_ = input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.PARSER, extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom(extensionReceiver_);
              extensionReceiver_ = subBuilder.buildPartial();
            }
            bitField0_ |= 0x00000008;
            break;
          }
          case 50: {
            if (!((mutable_bitField0_ & 0x00000040) == 0x00000040)) {
              regularParameter_ = new java.util.ArrayList<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter>();
              mutable_bitField0_ |= 0x00000040;
            }
            regularParameter_.add(input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.PARSER, extensionRegistry));
            break;
          }
          case 56: {
            bitField0_ |= 0x00000010;
            body_ = input.readInt32();
            break;
          }
          case 74: {
            if (!((mutable_bitField0_ & 0x00000010) == 0x00000010)) {
              contextParameter_ = new java.util.ArrayList<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter>();
              mutable_bitField0_ |= 0x00000010;
            }
            contextParameter_.add(input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.PARSER, extensionRegistry));
            break;
          }
        }
      }
    } catch (org.jetbrains.kotlin.protobuf.InvalidProtocolBufferException e) {
      throw e.setUnfinishedMessage(this);
    } catch (java.io.IOException e) {
      throw new org.jetbrains.kotlin.protobuf.InvalidProtocolBufferException(
          e.getMessage()).setUnfinishedMessage(this);
    } finally {
      if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
        typeParameter_ = java.util.Collections.unmodifiableList(typeParameter_);
      }
      if (((mutable_bitField0_ & 0x00000040) == 0x00000040)) {
        regularParameter_ = java.util.Collections.unmodifiableList(regularParameter_);
      }
      if (((mutable_bitField0_ & 0x00000010) == 0x00000010)) {
        contextParameter_ = java.util.Collections.unmodifiableList(contextParameter_);
      }
      try {
        unknownFieldsCodedOutput.flush();
      } catch (java.io.IOException e) {
      // Should not happen
      } finally {
        unknownFields = unknownFieldsOutput.toByteString();
      }
      makeExtensionsImmutable();
    }
  }
  public static org.jetbrains.kotlin.protobuf.Parser<IrFunctionBase> PARSER =
      new org.jetbrains.kotlin.protobuf.AbstractParser<IrFunctionBase>() {
    public IrFunctionBase parsePartialFrom(
        org.jetbrains.kotlin.protobuf.CodedInputStream input,
        org.jetbrains.kotlin.protobuf.ExtensionRegistryLite extensionRegistry)
        throws org.jetbrains.kotlin.protobuf.InvalidProtocolBufferException {
      return new IrFunctionBase(input, extensionRegistry);
    }
  };

  @java.lang.Override
  public org.jetbrains.kotlin.protobuf.Parser<IrFunctionBase> getParserForType() {
    return PARSER;
  }

  private int bitField0_;
  public static final int BASE_FIELD_NUMBER = 1;
  private org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase base_;
  /**
   * <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase base = 1;</code>
   */
  public boolean hasBase() {
    return ((bitField0_ & 0x00000001) == 0x00000001);
  }
  /**
   * <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase base = 1;</code>
   */
  public org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase getBase() {
    return base_;
  }

  public static final int NAME_TYPE_FIELD_NUMBER = 2;
  private long nameType_;
  /**
   * <code>required int64 name_type = 2;</code>
   */
  public boolean hasNameType() {
    return ((bitField0_ & 0x00000002) == 0x00000002);
  }
  /**
   * <code>required int64 name_type = 2;</code>
   */
  public long getNameType() {
    return nameType_;
  }

  public static final int TYPE_PARAMETER_FIELD_NUMBER = 3;
  private java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter> typeParameter_;
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
   */
  public java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter> getTypeParameterList() {
    return typeParameter_;
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
   */
  public java.util.List<? extends org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameterOrBuilder> 
      getTypeParameterOrBuilderList() {
    return typeParameter_;
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
   */
  public int getTypeParameterCount() {
    return typeParameter_.size();
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
   */
  public org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter getTypeParameter(int index) {
    return typeParameter_.get(index);
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
   */
  public org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameterOrBuilder getTypeParameterOrBuilder(
      int index) {
    return typeParameter_.get(index);
  }

  public static final int DISPATCH_RECEIVER_FIELD_NUMBER = 4;
  private org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter dispatchReceiver_;
  /**
   * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter dispatch_receiver = 4;</code>
   */
  public boolean hasDispatchReceiver() {
    return ((bitField0_ & 0x00000004) == 0x00000004);
  }
  /**
   * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter dispatch_receiver = 4;</code>
   */
  public org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter getDispatchReceiver() {
    return dispatchReceiver_;
  }

  public static final int CONTEXT_PARAMETER_FIELD_NUMBER = 9;
  private java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter> contextParameter_;
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
   */
  public java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter> getContextParameterList() {
    return contextParameter_;
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
   */
  public java.util.List<? extends org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameterOrBuilder> 
      getContextParameterOrBuilderList() {
    return contextParameter_;
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
   */
  public int getContextParameterCount() {
    return contextParameter_.size();
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
   */
  public org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter getContextParameter(int index) {
    return contextParameter_.get(index);
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
   */
  public org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameterOrBuilder getContextParameterOrBuilder(
      int index) {
    return contextParameter_.get(index);
  }

  public static final int EXTENSION_RECEIVER_FIELD_NUMBER = 5;
  private org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter extensionReceiver_;
  /**
   * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter extension_receiver = 5;</code>
   */
  public boolean hasExtensionReceiver() {
    return ((bitField0_ & 0x00000008) == 0x00000008);
  }
  /**
   * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter extension_receiver = 5;</code>
   */
  public org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter getExtensionReceiver() {
    return extensionReceiver_;
  }

  public static final int REGULAR_PARAMETER_FIELD_NUMBER = 6;
  private java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter> regularParameter_;
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
   */
  public java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter> getRegularParameterList() {
    return regularParameter_;
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
   */
  public java.util.List<? extends org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameterOrBuilder> 
      getRegularParameterOrBuilderList() {
    return regularParameter_;
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
   */
  public int getRegularParameterCount() {
    return regularParameter_.size();
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
   */
  public org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter getRegularParameter(int index) {
    return regularParameter_.get(index);
  }
  /**
   * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
   */
  public org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameterOrBuilder getRegularParameterOrBuilder(
      int index) {
    return regularParameter_.get(index);
  }

  public static final int BODY_FIELD_NUMBER = 7;
  private int body_;
  /**
   * <code>optional int32 body = 7;</code>
   *
   * <pre>
   *optional int32 context_receiver_parameters_count = 8;
   * </pre>
   */
  public boolean hasBody() {
    return ((bitField0_ & 0x00000010) == 0x00000010);
  }
  /**
   * <code>optional int32 body = 7;</code>
   *
   * <pre>
   *optional int32 context_receiver_parameters_count = 8;
   * </pre>
   */
  public int getBody() {
    return body_;
  }

  private void initFields() {
    base_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase.getDefaultInstance();
    nameType_ = 0L;
    typeParameter_ = java.util.Collections.emptyList();
    dispatchReceiver_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.getDefaultInstance();
    contextParameter_ = java.util.Collections.emptyList();
    extensionReceiver_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.getDefaultInstance();
    regularParameter_ = java.util.Collections.emptyList();
    body_ = 0;
  }
  private byte memoizedIsInitialized = -1;
  public final boolean isInitialized() {
    byte isInitialized = memoizedIsInitialized;
    if (isInitialized == 1) return true;
    if (isInitialized == 0) return false;

    if (!hasBase()) {
      memoizedIsInitialized = 0;
      return false;
    }
    if (!hasNameType()) {
      memoizedIsInitialized = 0;
      return false;
    }
    if (!getBase().isInitialized()) {
      memoizedIsInitialized = 0;
      return false;
    }
    for (int i = 0; i < getTypeParameterCount(); i++) {
      if (!getTypeParameter(i).isInitialized()) {
        memoizedIsInitialized = 0;
        return false;
      }
    }
    if (hasDispatchReceiver()) {
      if (!getDispatchReceiver().isInitialized()) {
        memoizedIsInitialized = 0;
        return false;
      }
    }
    for (int i = 0; i < getContextParameterCount(); i++) {
      if (!getContextParameter(i).isInitialized()) {
        memoizedIsInitialized = 0;
        return false;
      }
    }
    if (hasExtensionReceiver()) {
      if (!getExtensionReceiver().isInitialized()) {
        memoizedIsInitialized = 0;
        return false;
      }
    }
    for (int i = 0; i < getRegularParameterCount(); i++) {
      if (!getRegularParameter(i).isInitialized()) {
        memoizedIsInitialized = 0;
        return false;
      }
    }
    memoizedIsInitialized = 1;
    return true;
  }

  public void writeTo(org.jetbrains.kotlin.protobuf.CodedOutputStream output)
                      throws java.io.IOException {
    getSerializedSize();
    if (((bitField0_ & 0x00000001) == 0x00000001)) {
      output.writeMessage(1, base_);
    }
    if (((bitField0_ & 0x00000002) == 0x00000002)) {
      output.writeInt64(2, nameType_);
    }
    for (int i = 0; i < typeParameter_.size(); i++) {
      output.writeMessage(3, typeParameter_.get(i));
    }
    if (((bitField0_ & 0x00000004) == 0x00000004)) {
      output.writeMessage(4, dispatchReceiver_);
    }
    if (((bitField0_ & 0x00000008) == 0x00000008)) {
      output.writeMessage(5, extensionReceiver_);
    }
    for (int i = 0; i < regularParameter_.size(); i++) {
      output.writeMessage(6, regularParameter_.get(i));
    }
    if (((bitField0_ & 0x00000010) == 0x00000010)) {
      output.writeInt32(7, body_);
    }
    for (int i = 0; i < contextParameter_.size(); i++) {
      output.writeMessage(9, contextParameter_.get(i));
    }
    output.writeRawBytes(unknownFields);
  }

  private int memoizedSerializedSize = -1;
  public int getSerializedSize() {
    int size = memoizedSerializedSize;
    if (size != -1) return size;

    size = 0;
    if (((bitField0_ & 0x00000001) == 0x00000001)) {
      size += org.jetbrains.kotlin.protobuf.CodedOutputStream
        .computeMessageSize(1, base_);
    }
    if (((bitField0_ & 0x00000002) == 0x00000002)) {
      size += org.jetbrains.kotlin.protobuf.CodedOutputStream
        .computeInt64Size(2, nameType_);
    }
    for (int i = 0; i < typeParameter_.size(); i++) {
      size += org.jetbrains.kotlin.protobuf.CodedOutputStream
        .computeMessageSize(3, typeParameter_.get(i));
    }
    if (((bitField0_ & 0x00000004) == 0x00000004)) {
      size += org.jetbrains.kotlin.protobuf.CodedOutputStream
        .computeMessageSize(4, dispatchReceiver_);
    }
    if (((bitField0_ & 0x00000008) == 0x00000008)) {
      size += org.jetbrains.kotlin.protobuf.CodedOutputStream
        .computeMessageSize(5, extensionReceiver_);
    }
    for (int i = 0; i < regularParameter_.size(); i++) {
      size += org.jetbrains.kotlin.protobuf.CodedOutputStream
        .computeMessageSize(6, regularParameter_.get(i));
    }
    if (((bitField0_ & 0x00000010) == 0x00000010)) {
      size += org.jetbrains.kotlin.protobuf.CodedOutputStream
        .computeInt32Size(7, body_);
    }
    for (int i = 0; i < contextParameter_.size(); i++) {
      size += org.jetbrains.kotlin.protobuf.CodedOutputStream
        .computeMessageSize(9, contextParameter_.get(i));
    }
    size += unknownFields.size();
    memoizedSerializedSize = size;
    return size;
  }

  private static final long serialVersionUID = 0L;
  @java.lang.Override
  protected java.lang.Object writeReplace()
      throws java.io.ObjectStreamException {
    return super.writeReplace();
  }

  public static org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parseFrom(
      org.jetbrains.kotlin.protobuf.ByteString data)
      throws org.jetbrains.kotlin.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parseFrom(
      org.jetbrains.kotlin.protobuf.ByteString data,
      org.jetbrains.kotlin.protobuf.ExtensionRegistryLite extensionRegistry)
      throws org.jetbrains.kotlin.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parseFrom(byte[] data)
      throws org.jetbrains.kotlin.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parseFrom(
      byte[] data,
      org.jetbrains.kotlin.protobuf.ExtensionRegistryLite extensionRegistry)
      throws org.jetbrains.kotlin.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return PARSER.parseFrom(input);
  }
  public static org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parseFrom(
      java.io.InputStream input,
      org.jetbrains.kotlin.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return PARSER.parseFrom(input, extensionRegistry);
  }
  public static org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return PARSER.parseDelimitedFrom(input);
  }
  public static org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parseDelimitedFrom(
      java.io.InputStream input,
      org.jetbrains.kotlin.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return PARSER.parseDelimitedFrom(input, extensionRegistry);
  }
  public static org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parseFrom(
      org.jetbrains.kotlin.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return PARSER.parseFrom(input);
  }
  public static org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parseFrom(
      org.jetbrains.kotlin.protobuf.CodedInputStream input,
      org.jetbrains.kotlin.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return PARSER.parseFrom(input, extensionRegistry);
  }

  public static Builder newBuilder() { return Builder.create(); }
  public Builder newBuilderForType() { return newBuilder(); }
  public static Builder newBuilder(org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase prototype) {
    return newBuilder().mergeFrom(prototype);
  }
  public Builder toBuilder() { return newBuilder(this); }

  /**
   * Protobuf type {@code org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase}
   */
  public static final class Builder extends
      org.jetbrains.kotlin.protobuf.GeneratedMessageLite.Builder<
        org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase, Builder>
      implements
      // @@protoc_insertion_point(builder_implements:org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase)
      org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBaseOrBuilder {
    // Construct using org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

    private void maybeForceBuilderInitialization() {
    }
    private static Builder create() {
      return new Builder();
    }

    public Builder clear() {
      super.clear();
      base_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase.getDefaultInstance();
      bitField0_ = (bitField0_ & ~0x00000001);
      nameType_ = 0L;
      bitField0_ = (bitField0_ & ~0x00000002);
      typeParameter_ = java.util.Collections.emptyList();
      bitField0_ = (bitField0_ & ~0x00000004);
      dispatchReceiver_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.getDefaultInstance();
      bitField0_ = (bitField0_ & ~0x00000008);
      contextParameter_ = java.util.Collections.emptyList();
      bitField0_ = (bitField0_ & ~0x00000010);
      extensionReceiver_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.getDefaultInstance();
      bitField0_ = (bitField0_ & ~0x00000020);
      regularParameter_ = java.util.Collections.emptyList();
      bitField0_ = (bitField0_ & ~0x00000040);
      body_ = 0;
      bitField0_ = (bitField0_ & ~0x00000080);
      return this;
    }

    public Builder clone() {
      return create().mergeFrom(buildPartial());
    }

    public org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase getDefaultInstanceForType() {
      return org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase.getDefaultInstance();
    }

    public org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase build() {
      org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    public org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase buildPartial() {
      org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase result = new org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase(this);
      int from_bitField0_ = bitField0_;
      int to_bitField0_ = 0;
      if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
        to_bitField0_ |= 0x00000001;
      }
      result.base_ = base_;
      if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
        to_bitField0_ |= 0x00000002;
      }
      result.nameType_ = nameType_;
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        typeParameter_ = java.util.Collections.unmodifiableList(typeParameter_);
        bitField0_ = (bitField0_ & ~0x00000004);
      }
      result.typeParameter_ = typeParameter_;
      if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
        to_bitField0_ |= 0x00000004;
      }
      result.dispatchReceiver_ = dispatchReceiver_;
      if (((bitField0_ & 0x00000010) == 0x00000010)) {
        contextParameter_ = java.util.Collections.unmodifiableList(contextParameter_);
        bitField0_ = (bitField0_ & ~0x00000010);
      }
      result.contextParameter_ = contextParameter_;
      if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
        to_bitField0_ |= 0x00000008;
      }
      result.extensionReceiver_ = extensionReceiver_;
      if (((bitField0_ & 0x00000040) == 0x00000040)) {
        regularParameter_ = java.util.Collections.unmodifiableList(regularParameter_);
        bitField0_ = (bitField0_ & ~0x00000040);
      }
      result.regularParameter_ = regularParameter_;
      if (((from_bitField0_ & 0x00000080) == 0x00000080)) {
        to_bitField0_ |= 0x00000010;
      }
      result.body_ = body_;
      result.bitField0_ = to_bitField0_;
      return result;
    }

    public Builder mergeFrom(org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase other) {
      if (other == org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase.getDefaultInstance()) return this;
      if (other.hasBase()) {
        mergeBase(other.getBase());
      }
      if (other.hasNameType()) {
        setNameType(other.getNameType());
      }
      if (!other.typeParameter_.isEmpty()) {
        if (typeParameter_.isEmpty()) {
          typeParameter_ = other.typeParameter_;
          bitField0_ = (bitField0_ & ~0x00000004);
        } else {
          ensureTypeParameterIsMutable();
          typeParameter_.addAll(other.typeParameter_);
        }
        
      }
      if (other.hasDispatchReceiver()) {
        mergeDispatchReceiver(other.getDispatchReceiver());
      }
      if (!other.contextParameter_.isEmpty()) {
        if (contextParameter_.isEmpty()) {
          contextParameter_ = other.contextParameter_;
          bitField0_ = (bitField0_ & ~0x00000010);
        } else {
          ensureContextParameterIsMutable();
          contextParameter_.addAll(other.contextParameter_);
        }
        
      }
      if (other.hasExtensionReceiver()) {
        mergeExtensionReceiver(other.getExtensionReceiver());
      }
      if (!other.regularParameter_.isEmpty()) {
        if (regularParameter_.isEmpty()) {
          regularParameter_ = other.regularParameter_;
          bitField0_ = (bitField0_ & ~0x00000040);
        } else {
          ensureRegularParameterIsMutable();
          regularParameter_.addAll(other.regularParameter_);
        }
        
      }
      if (other.hasBody()) {
        setBody(other.getBody());
      }
      setUnknownFields(
          getUnknownFields().concat(other.unknownFields));
      return this;
    }

    public final boolean isInitialized() {
      if (!hasBase()) {
        
        return false;
      }
      if (!hasNameType()) {
        
        return false;
      }
      if (!getBase().isInitialized()) {
        
        return false;
      }
      for (int i = 0; i < getTypeParameterCount(); i++) {
        if (!getTypeParameter(i).isInitialized()) {
          
          return false;
        }
      }
      if (hasDispatchReceiver()) {
        if (!getDispatchReceiver().isInitialized()) {
          
          return false;
        }
      }
      for (int i = 0; i < getContextParameterCount(); i++) {
        if (!getContextParameter(i).isInitialized()) {
          
          return false;
        }
      }
      if (hasExtensionReceiver()) {
        if (!getExtensionReceiver().isInitialized()) {
          
          return false;
        }
      }
      for (int i = 0; i < getRegularParameterCount(); i++) {
        if (!getRegularParameter(i).isInitialized()) {
          
          return false;
        }
      }
      return true;
    }

    public Builder mergeFrom(
        org.jetbrains.kotlin.protobuf.CodedInputStream input,
        org.jetbrains.kotlin.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (org.jetbrains.kotlin.protobuf.InvalidProtocolBufferException e) {
        parsedMessage = (org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase) e.getUnfinishedMessage();
        throw e;
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }
    private int bitField0_;

    private org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase base_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase.getDefaultInstance();
    /**
     * <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase base = 1;</code>
     */
    public boolean hasBase() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase base = 1;</code>
     */
    public org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase getBase() {
      return base_;
    }
    /**
     * <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase base = 1;</code>
     */
    public Builder setBase(org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase value) {
      if (value == null) {
        throw new NullPointerException();
      }
      base_ = value;

      bitField0_ |= 0x00000001;
      return this;
    }
    /**
     * <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase base = 1;</code>
     */
    public Builder setBase(
        org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase.Builder builderForValue) {
      base_ = builderForValue.build();

      bitField0_ |= 0x00000001;
      return this;
    }
    /**
     * <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase base = 1;</code>
     */
    public Builder mergeBase(org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase value) {
      if (((bitField0_ & 0x00000001) == 0x00000001) &&
          base_ != org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase.getDefaultInstance()) {
        base_ =
          org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase.newBuilder(base_).mergeFrom(value).buildPartial();
      } else {
        base_ = value;
      }

      bitField0_ |= 0x00000001;
      return this;
    }
    /**
     * <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase base = 1;</code>
     */
    public Builder clearBase() {
      base_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrDeclarationBase.getDefaultInstance();

      bitField0_ = (bitField0_ & ~0x00000001);
      return this;
    }

    private long nameType_ ;
    /**
     * <code>required int64 name_type = 2;</code>
     */
    public boolean hasNameType() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>required int64 name_type = 2;</code>
     */
    public long getNameType() {
      return nameType_;
    }
    /**
     * <code>required int64 name_type = 2;</code>
     */
    public Builder setNameType(long value) {
      bitField0_ |= 0x00000002;
      nameType_ = value;
      
      return this;
    }
    /**
     * <code>required int64 name_type = 2;</code>
     */
    public Builder clearNameType() {
      bitField0_ = (bitField0_ & ~0x00000002);
      nameType_ = 0L;
      
      return this;
    }

    private java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter> typeParameter_ =
      java.util.Collections.emptyList();
    private void ensureTypeParameterIsMutable() {
      if (!((bitField0_ & 0x00000004) == 0x00000004)) {
        typeParameter_ = new java.util.ArrayList<org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter>(typeParameter_);
        bitField0_ |= 0x00000004;
       }
    }

    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter> getTypeParameterList() {
      return java.util.Collections.unmodifiableList(typeParameter_);
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public int getTypeParameterCount() {
      return typeParameter_.size();
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter getTypeParameter(int index) {
      return typeParameter_.get(index);
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public Builder setTypeParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureTypeParameterIsMutable();
      typeParameter_.set(index, value);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public Builder setTypeParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter.Builder builderForValue) {
      ensureTypeParameterIsMutable();
      typeParameter_.set(index, builderForValue.build());

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public Builder addTypeParameter(org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureTypeParameterIsMutable();
      typeParameter_.add(value);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public Builder addTypeParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureTypeParameterIsMutable();
      typeParameter_.add(index, value);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public Builder addTypeParameter(
        org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter.Builder builderForValue) {
      ensureTypeParameterIsMutable();
      typeParameter_.add(builderForValue.build());

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public Builder addTypeParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter.Builder builderForValue) {
      ensureTypeParameterIsMutable();
      typeParameter_.add(index, builderForValue.build());

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public Builder addAllTypeParameter(
        java.lang.Iterable<? extends org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter> values) {
      ensureTypeParameterIsMutable();
      org.jetbrains.kotlin.protobuf.AbstractMessageLite.Builder.addAll(
          values, typeParameter_);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public Builder clearTypeParameter() {
      typeParameter_ = java.util.Collections.emptyList();
      bitField0_ = (bitField0_ & ~0x00000004);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrTypeParameter type_parameter = 3;</code>
     */
    public Builder removeTypeParameter(int index) {
      ensureTypeParameterIsMutable();
      typeParameter_.remove(index);

      return this;
    }

    private org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter dispatchReceiver_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.getDefaultInstance();
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter dispatch_receiver = 4;</code>
     */
    public boolean hasDispatchReceiver() {
      return ((bitField0_ & 0x00000008) == 0x00000008);
    }
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter dispatch_receiver = 4;</code>
     */
    public org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter getDispatchReceiver() {
      return dispatchReceiver_;
    }
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter dispatch_receiver = 4;</code>
     */
    public Builder setDispatchReceiver(org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      dispatchReceiver_ = value;

      bitField0_ |= 0x00000008;
      return this;
    }
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter dispatch_receiver = 4;</code>
     */
    public Builder setDispatchReceiver(
        org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.Builder builderForValue) {
      dispatchReceiver_ = builderForValue.build();

      bitField0_ |= 0x00000008;
      return this;
    }
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter dispatch_receiver = 4;</code>
     */
    public Builder mergeDispatchReceiver(org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter value) {
      if (((bitField0_ & 0x00000008) == 0x00000008) &&
          dispatchReceiver_ != org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.getDefaultInstance()) {
        dispatchReceiver_ =
          org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.newBuilder(dispatchReceiver_).mergeFrom(value).buildPartial();
      } else {
        dispatchReceiver_ = value;
      }

      bitField0_ |= 0x00000008;
      return this;
    }
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter dispatch_receiver = 4;</code>
     */
    public Builder clearDispatchReceiver() {
      dispatchReceiver_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.getDefaultInstance();

      bitField0_ = (bitField0_ & ~0x00000008);
      return this;
    }

    private java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter> contextParameter_ =
      java.util.Collections.emptyList();
    private void ensureContextParameterIsMutable() {
      if (!((bitField0_ & 0x00000010) == 0x00000010)) {
        contextParameter_ = new java.util.ArrayList<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter>(contextParameter_);
        bitField0_ |= 0x00000010;
       }
    }

    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter> getContextParameterList() {
      return java.util.Collections.unmodifiableList(contextParameter_);
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public int getContextParameterCount() {
      return contextParameter_.size();
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter getContextParameter(int index) {
      return contextParameter_.get(index);
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public Builder setContextParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureContextParameterIsMutable();
      contextParameter_.set(index, value);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public Builder setContextParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.Builder builderForValue) {
      ensureContextParameterIsMutable();
      contextParameter_.set(index, builderForValue.build());

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public Builder addContextParameter(org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureContextParameterIsMutable();
      contextParameter_.add(value);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public Builder addContextParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureContextParameterIsMutable();
      contextParameter_.add(index, value);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public Builder addContextParameter(
        org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.Builder builderForValue) {
      ensureContextParameterIsMutable();
      contextParameter_.add(builderForValue.build());

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public Builder addContextParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.Builder builderForValue) {
      ensureContextParameterIsMutable();
      contextParameter_.add(index, builderForValue.build());

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public Builder addAllContextParameter(
        java.lang.Iterable<? extends org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter> values) {
      ensureContextParameterIsMutable();
      org.jetbrains.kotlin.protobuf.AbstractMessageLite.Builder.addAll(
          values, contextParameter_);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public Builder clearContextParameter() {
      contextParameter_ = java.util.Collections.emptyList();
      bitField0_ = (bitField0_ & ~0x00000010);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter context_parameter = 9;</code>
     */
    public Builder removeContextParameter(int index) {
      ensureContextParameterIsMutable();
      contextParameter_.remove(index);

      return this;
    }

    private org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter extensionReceiver_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.getDefaultInstance();
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter extension_receiver = 5;</code>
     */
    public boolean hasExtensionReceiver() {
      return ((bitField0_ & 0x00000020) == 0x00000020);
    }
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter extension_receiver = 5;</code>
     */
    public org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter getExtensionReceiver() {
      return extensionReceiver_;
    }
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter extension_receiver = 5;</code>
     */
    public Builder setExtensionReceiver(org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      extensionReceiver_ = value;

      bitField0_ |= 0x00000020;
      return this;
    }
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter extension_receiver = 5;</code>
     */
    public Builder setExtensionReceiver(
        org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.Builder builderForValue) {
      extensionReceiver_ = builderForValue.build();

      bitField0_ |= 0x00000020;
      return this;
    }
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter extension_receiver = 5;</code>
     */
    public Builder mergeExtensionReceiver(org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter value) {
      if (((bitField0_ & 0x00000020) == 0x00000020) &&
          extensionReceiver_ != org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.getDefaultInstance()) {
        extensionReceiver_ =
          org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.newBuilder(extensionReceiver_).mergeFrom(value).buildPartial();
      } else {
        extensionReceiver_ = value;
      }

      bitField0_ |= 0x00000020;
      return this;
    }
    /**
     * <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter extension_receiver = 5;</code>
     */
    public Builder clearExtensionReceiver() {
      extensionReceiver_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.getDefaultInstance();

      bitField0_ = (bitField0_ & ~0x00000020);
      return this;
    }

    private java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter> regularParameter_ =
      java.util.Collections.emptyList();
    private void ensureRegularParameterIsMutable() {
      if (!((bitField0_ & 0x00000040) == 0x00000040)) {
        regularParameter_ = new java.util.ArrayList<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter>(regularParameter_);
        bitField0_ |= 0x00000040;
       }
    }

    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public java.util.List<org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter> getRegularParameterList() {
      return java.util.Collections.unmodifiableList(regularParameter_);
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public int getRegularParameterCount() {
      return regularParameter_.size();
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter getRegularParameter(int index) {
      return regularParameter_.get(index);
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public Builder setRegularParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureRegularParameterIsMutable();
      regularParameter_.set(index, value);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public Builder setRegularParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.Builder builderForValue) {
      ensureRegularParameterIsMutable();
      regularParameter_.set(index, builderForValue.build());

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public Builder addRegularParameter(org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureRegularParameterIsMutable();
      regularParameter_.add(value);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public Builder addRegularParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureRegularParameterIsMutable();
      regularParameter_.add(index, value);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public Builder addRegularParameter(
        org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.Builder builderForValue) {
      ensureRegularParameterIsMutable();
      regularParameter_.add(builderForValue.build());

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public Builder addRegularParameter(
        int index, org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter.Builder builderForValue) {
      ensureRegularParameterIsMutable();
      regularParameter_.add(index, builderForValue.build());

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public Builder addAllRegularParameter(
        java.lang.Iterable<? extends org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter> values) {
      ensureRegularParameterIsMutable();
      org.jetbrains.kotlin.protobuf.AbstractMessageLite.Builder.addAll(
          values, regularParameter_);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public Builder clearRegularParameter() {
      regularParameter_ = java.util.Collections.emptyList();
      bitField0_ = (bitField0_ & ~0x00000040);

      return this;
    }
    /**
     * <code>repeated .org.jetbrains.kotlin.backend.common.serialization.proto.IrValueParameter regular_parameter = 6;</code>
     */
    public Builder removeRegularParameter(int index) {
      ensureRegularParameterIsMutable();
      regularParameter_.remove(index);

      return this;
    }

    private int body_ ;
    /**
     * <code>optional int32 body = 7;</code>
     *
     * <pre>
     *optional int32 context_receiver_parameters_count = 8;
     * </pre>
     */
    public boolean hasBody() {
      return ((bitField0_ & 0x00000080) == 0x00000080);
    }
    /**
     * <code>optional int32 body = 7;</code>
     *
     * <pre>
     *optional int32 context_receiver_parameters_count = 8;
     * </pre>
     */
    public int getBody() {
      return body_;
    }
    /**
     * <code>optional int32 body = 7;</code>
     *
     * <pre>
     *optional int32 context_receiver_parameters_count = 8;
     * </pre>
     */
    public Builder setBody(int value) {
      bitField0_ |= 0x00000080;
      body_ = value;
      
      return this;
    }
    /**
     * <code>optional int32 body = 7;</code>
     *
     * <pre>
     *optional int32 context_receiver_parameters_count = 8;
     * </pre>
     */
    public Builder clearBody() {
      bitField0_ = (bitField0_ & ~0x00000080);
      body_ = 0;
      
      return this;
    }

    // @@protoc_insertion_point(builder_scope:org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase)
  }

  static {
    defaultInstance = new IrFunctionBase(true);
    defaultInstance.initFields();
  }

  // @@protoc_insertion_point(class_scope:org.jetbrains.kotlin.backend.common.serialization.proto.IrFunctionBase)
}
