.ExtensionWriter extensionWriter =
+ newExtensionWriter();
+ if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ output.writeInt32(1, flags_);
+ }
+ if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ output.writeInt32(2, name_);
+ }
+ for (int i = 0; i < typeParameter_.size(); i++) {
+ output.writeMessage(3, typeParameter_.get(i));
+ }
+ if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ output.writeMessage(4, underlyingType_);
+ }
+ if (((bitField0_ & 0x00000008) == 0x00000008)) {
+ output.writeInt32(5, underlyingTypeId_);
+ }
+ if (((bitField0_ & 0x00000010) == 0x00000010)) {
+ output.writeMessage(6, expandedType_);
+ }
+ if (((bitField0_ & 0x00000020) == 0x00000020)) {
+ output.writeInt32(7, expandedTypeId_);
+ }
+ extensionWriter.writeUntil(200, output);
+ getUnknownFields().writeTo(output);
+ }
+
+ private int memoizedSerializedSize = -1;
+ public int getSerializedSize() {
+ int size = memoizedSerializedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeInt32Size(1, flags_);
+ }
+ if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeInt32Size(2, name_);
+ }
+ for (int i = 0; i < typeParameter_.size(); i++) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(3, typeParameter_.get(i));
+ }
+ if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(4, underlyingType_);
+ }
+ if (((bitField0_ & 0x00000008) == 0x00000008)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeInt32Size(5, underlyingTypeId_);
+ }
+ if (((bitField0_ & 0x00000010) == 0x00000010)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(6, expandedType_);
+ }
+ if (((bitField0_ & 0x00000020) == 0x00000020)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeInt32Size(7, expandedTypeId_);
+ }
+ size += extensionsSerializedSize();
+ size += getUnknownFields().getSerializedSize();
+ 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.serialization.DebugProtoBuf.TypeAlias parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias parseFrom(
+ com.google.protobuf.ByteString data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+ public static org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias parseFrom(
+ byte[] data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+ public static org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias parseFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return PARSER.parseFrom(input);
+ }
+ public static org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias parseFrom(
+ java.io.InputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return PARSER.parseFrom(input, extensionRegistry);
+ }
+ public static org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias parseDelimitedFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return PARSER.parseDelimitedFrom(input);
+ }
+ public static org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias parseDelimitedFrom(
+ java.io.InputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return PARSER.parseDelimitedFrom(input, extensionRegistry);
+ }
+ public static org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias parseFrom(
+ com.google.protobuf.CodedInputStream input)
+ throws java.io.IOException {
+ return PARSER.parseFrom(input);
+ }
+ public static org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias parseFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.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.serialization.DebugProtoBuf.TypeAlias prototype) {
+ return newBuilder().mergeFrom(prototype);
+ }
+ public Builder toBuilder() { return newBuilder(this); }
+
+ @java.lang.Override
+ protected Builder newBuilderForType(
+ com.google.protobuf.GeneratedMessage.BuilderParent parent) {
+ Builder builder = new Builder(parent);
+ return builder;
+ }
+ /**
+ * Protobuf type {@code org.jetbrains.kotlin.serialization.TypeAlias}
+ */
+ public static final class Builder extends
+ com.google.protobuf.GeneratedMessage.ExtendableBuilder<
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias, Builder> implements org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAliasOrBuilder {
+ public static final com.google.protobuf.Descriptors.Descriptor
+ getDescriptor() {
+ return org.jetbrains.kotlin.serialization.DebugProtoBuf.internal_static_org_jetbrains_kotlin_serialization_TypeAlias_descriptor;
+ }
+
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ internalGetFieldAccessorTable() {
+ return org.jetbrains.kotlin.serialization.DebugProtoBuf.internal_static_org_jetbrains_kotlin_serialization_TypeAlias_fieldAccessorTable
+ .ensureFieldAccessorsInitialized(
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias.class, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias.Builder.class);
+ }
+
+ // Construct using org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias.newBuilder()
+ private Builder() {
+ maybeForceBuilderInitialization();
+ }
+
+ private Builder(
+ com.google.protobuf.GeneratedMessage.BuilderParent parent) {
+ super(parent);
+ maybeForceBuilderInitialization();
+ }
+ private void maybeForceBuilderInitialization() {
+ if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
+ getTypeParameterFieldBuilder();
+ getUnderlyingTypeFieldBuilder();
+ getExpandedTypeFieldBuilder();
+ }
+ }
+ private static Builder create() {
+ return new Builder();
+ }
+
+ public Builder clear() {
+ super.clear();
+ flags_ = 0;
+ bitField0_ = (bitField0_ & ~0x00000001);
+ name_ = 0;
+ bitField0_ = (bitField0_ & ~0x00000002);
+ if (typeParameterBuilder_ == null) {
+ typeParameter_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000004);
+ } else {
+ typeParameterBuilder_.clear();
+ }
+ if (underlyingTypeBuilder_ == null) {
+ underlyingType_ = org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.getDefaultInstance();
+ } else {
+ underlyingTypeBuilder_.clear();
+ }
+ bitField0_ = (bitField0_ & ~0x00000008);
+ underlyingTypeId_ = 0;
+ bitField0_ = (bitField0_ & ~0x00000010);
+ if (expandedTypeBuilder_ == null) {
+ expandedType_ = org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.getDefaultInstance();
+ } else {
+ expandedTypeBuilder_.clear();
+ }
+ bitField0_ = (bitField0_ & ~0x00000020);
+ expandedTypeId_ = 0;
+ bitField0_ = (bitField0_ & ~0x00000040);
+ return this;
+ }
+
+ public Builder clone() {
+ return create().mergeFrom(buildPartial());
+ }
+
+ public com.google.protobuf.Descriptors.Descriptor
+ getDescriptorForType() {
+ return org.jetbrains.kotlin.serialization.DebugProtoBuf.internal_static_org_jetbrains_kotlin_serialization_TypeAlias_descriptor;
+ }
+
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias getDefaultInstanceForType() {
+ return org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias.getDefaultInstance();
+ }
+
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias build() {
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias result = buildPartial();
+ if (!result.isInitialized()) {
+ throw newUninitializedMessageException(result);
+ }
+ return result;
+ }
+
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias buildPartial() {
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias result = new org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias(this);
+ int from_bitField0_ = bitField0_;
+ int to_bitField0_ = 0;
+ if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
+ to_bitField0_ |= 0x00000001;
+ }
+ result.flags_ = flags_;
+ if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
+ to_bitField0_ |= 0x00000002;
+ }
+ result.name_ = name_;
+ if (typeParameterBuilder_ == null) {
+ if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ typeParameter_ = java.util.Collections.unmodifiableList(typeParameter_);
+ bitField0_ = (bitField0_ & ~0x00000004);
+ }
+ result.typeParameter_ = typeParameter_;
+ } else {
+ result.typeParameter_ = typeParameterBuilder_.build();
+ }
+ if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
+ to_bitField0_ |= 0x00000004;
+ }
+ if (underlyingTypeBuilder_ == null) {
+ result.underlyingType_ = underlyingType_;
+ } else {
+ result.underlyingType_ = underlyingTypeBuilder_.build();
+ }
+ if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
+ to_bitField0_ |= 0x00000008;
+ }
+ result.underlyingTypeId_ = underlyingTypeId_;
+ if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
+ to_bitField0_ |= 0x00000010;
+ }
+ if (expandedTypeBuilder_ == null) {
+ result.expandedType_ = expandedType_;
+ } else {
+ result.expandedType_ = expandedTypeBuilder_.build();
+ }
+ if (((from_bitField0_ & 0x00000040) == 0x00000040)) {
+ to_bitField0_ |= 0x00000020;
+ }
+ result.expandedTypeId_ = expandedTypeId_;
+ result.bitField0_ = to_bitField0_;
+ onBuilt();
+ return result;
+ }
+
+ public Builder mergeFrom(com.google.protobuf.Message other) {
+ if (other instanceof org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias) {
+ return mergeFrom((org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias)other);
+ } else {
+ super.mergeFrom(other);
+ return this;
+ }
+ }
+
+ public Builder mergeFrom(org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias other) {
+ if (other == org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias.getDefaultInstance()) return this;
+ if (other.hasFlags()) {
+ setFlags(other.getFlags());
+ }
+ if (other.hasName()) {
+ setName(other.getName());
+ }
+ if (typeParameterBuilder_ == null) {
+ if (!other.typeParameter_.isEmpty()) {
+ if (typeParameter_.isEmpty()) {
+ typeParameter_ = other.typeParameter_;
+ bitField0_ = (bitField0_ & ~0x00000004);
+ } else {
+ ensureTypeParameterIsMutable();
+ typeParameter_.addAll(other.typeParameter_);
+ }
+ onChanged();
+ }
+ } else {
+ if (!other.typeParameter_.isEmpty()) {
+ if (typeParameterBuilder_.isEmpty()) {
+ typeParameterBuilder_.dispose();
+ typeParameterBuilder_ = null;
+ typeParameter_ = other.typeParameter_;
+ bitField0_ = (bitField0_ & ~0x00000004);
+ typeParameterBuilder_ =
+ com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
+ getTypeParameterFieldBuilder() : null;
+ } else {
+ typeParameterBuilder_.addAllMessages(other.typeParameter_);
+ }
+ }
+ }
+ if (other.hasUnderlyingType()) {
+ mergeUnderlyingType(other.getUnderlyingType());
+ }
+ if (other.hasUnderlyingTypeId()) {
+ setUnderlyingTypeId(other.getUnderlyingTypeId());
+ }
+ if (other.hasExpandedType()) {
+ mergeExpandedType(other.getExpandedType());
+ }
+ if (other.hasExpandedTypeId()) {
+ setExpandedTypeId(other.getExpandedTypeId());
+ }
+ this.mergeExtensionFields(other);
+ this.mergeUnknownFields(other.getUnknownFields());
+ return this;
+ }
+
+ public final boolean isInitialized() {
+ if (!hasName()) {
+
+ return false;
+ }
+ for (int i = 0; i < getTypeParameterCount(); i++) {
+ if (!getTypeParameter(i).isInitialized()) {
+
+ return false;
+ }
+ }
+ if (hasUnderlyingType()) {
+ if (!getUnderlyingType().isInitialized()) {
+
+ return false;
+ }
+ }
+ if (hasExpandedType()) {
+ if (!getExpandedType().isInitialized()) {
+
+ return false;
+ }
+ }
+ if (!extensionsAreInitialized()) {
+
+ return false;
+ }
+ return true;
+ }
+
+ public Builder mergeFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias parsedMessage = null;
+ try {
+ parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
+ } catch (com.google.protobuf.InvalidProtocolBufferException e) {
+ parsedMessage = (org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeAlias) e.getUnfinishedMessage();
+ throw e;
+ } finally {
+ if (parsedMessage != null) {
+ mergeFrom(parsedMessage);
+ }
+ }
+ return this;
+ }
+ private int bitField0_;
+
+ // optional int32 flags = 1 [default = 0];
+ private int flags_ ;
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ public boolean hasFlags() {
+ return ((bitField0_ & 0x00000001) == 0x00000001);
+ }
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ public int getFlags() {
+ return flags_;
+ }
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ public Builder setFlags(int value) {
+ bitField0_ |= 0x00000001;
+ flags_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ public Builder clearFlags() {
+ bitField0_ = (bitField0_ & ~0x00000001);
+ flags_ = 0;
+ onChanged();
+ return this;
+ }
+
+ // required int32 name = 2;
+ private int name_ ;
+ /**
+ * required int32 name = 2;
+ */
+ public boolean hasName() {
+ return ((bitField0_ & 0x00000002) == 0x00000002);
+ }
+ /**
+ * required int32 name = 2;
+ */
+ public int getName() {
+ return name_;
+ }
+ /**
+ * required int32 name = 2;
+ */
+ public Builder setName(int value) {
+ bitField0_ |= 0x00000002;
+ name_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * required int32 name = 2;
+ */
+ public Builder clearName() {
+ bitField0_ = (bitField0_ & ~0x00000002);
+ name_ = 0;
+ onChanged();
+ return this;
+ }
+
+ // repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ private java.util.List typeParameter_ =
+ java.util.Collections.emptyList();
+ private void ensureTypeParameterIsMutable() {
+ if (!((bitField0_ & 0x00000004) == 0x00000004)) {
+ typeParameter_ = new java.util.ArrayList(typeParameter_);
+ bitField0_ |= 0x00000004;
+ }
+ }
+
+ private com.google.protobuf.RepeatedFieldBuilder<
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.Builder, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameterOrBuilder> typeParameterBuilder_;
+
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public java.util.List getTypeParameterList() {
+ if (typeParameterBuilder_ == null) {
+ return java.util.Collections.unmodifiableList(typeParameter_);
+ } else {
+ return typeParameterBuilder_.getMessageList();
+ }
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public int getTypeParameterCount() {
+ if (typeParameterBuilder_ == null) {
+ return typeParameter_.size();
+ } else {
+ return typeParameterBuilder_.getCount();
+ }
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter getTypeParameter(int index) {
+ if (typeParameterBuilder_ == null) {
+ return typeParameter_.get(index);
+ } else {
+ return typeParameterBuilder_.getMessage(index);
+ }
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder setTypeParameter(
+ int index, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter value) {
+ if (typeParameterBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeParameterIsMutable();
+ typeParameter_.set(index, value);
+ onChanged();
+ } else {
+ typeParameterBuilder_.setMessage(index, value);
+ }
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder setTypeParameter(
+ int index, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.Builder builderForValue) {
+ if (typeParameterBuilder_ == null) {
+ ensureTypeParameterIsMutable();
+ typeParameter_.set(index, builderForValue.build());
+ onChanged();
+ } else {
+ typeParameterBuilder_.setMessage(index, builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder addTypeParameter(org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter value) {
+ if (typeParameterBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeParameterIsMutable();
+ typeParameter_.add(value);
+ onChanged();
+ } else {
+ typeParameterBuilder_.addMessage(value);
+ }
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder addTypeParameter(
+ int index, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter value) {
+ if (typeParameterBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeParameterIsMutable();
+ typeParameter_.add(index, value);
+ onChanged();
+ } else {
+ typeParameterBuilder_.addMessage(index, value);
+ }
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder addTypeParameter(
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.Builder builderForValue) {
+ if (typeParameterBuilder_ == null) {
+ ensureTypeParameterIsMutable();
+ typeParameter_.add(builderForValue.build());
+ onChanged();
+ } else {
+ typeParameterBuilder_.addMessage(builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder addTypeParameter(
+ int index, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.Builder builderForValue) {
+ if (typeParameterBuilder_ == null) {
+ ensureTypeParameterIsMutable();
+ typeParameter_.add(index, builderForValue.build());
+ onChanged();
+ } else {
+ typeParameterBuilder_.addMessage(index, builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder addAllTypeParameter(
+ java.lang.Iterable extends org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter> values) {
+ if (typeParameterBuilder_ == null) {
+ ensureTypeParameterIsMutable();
+ super.addAll(values, typeParameter_);
+ onChanged();
+ } else {
+ typeParameterBuilder_.addAllMessages(values);
+ }
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder clearTypeParameter() {
+ if (typeParameterBuilder_ == null) {
+ typeParameter_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000004);
+ onChanged();
+ } else {
+ typeParameterBuilder_.clear();
+ }
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder removeTypeParameter(int index) {
+ if (typeParameterBuilder_ == null) {
+ ensureTypeParameterIsMutable();
+ typeParameter_.remove(index);
+ onChanged();
+ } else {
+ typeParameterBuilder_.remove(index);
+ }
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.Builder getTypeParameterBuilder(
+ int index) {
+ return getTypeParameterFieldBuilder().getBuilder(index);
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameterOrBuilder getTypeParameterOrBuilder(
+ int index) {
+ if (typeParameterBuilder_ == null) {
+ return typeParameter_.get(index); } else {
+ return typeParameterBuilder_.getMessageOrBuilder(index);
+ }
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public java.util.List extends org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameterOrBuilder>
+ getTypeParameterOrBuilderList() {
+ if (typeParameterBuilder_ != null) {
+ return typeParameterBuilder_.getMessageOrBuilderList();
+ } else {
+ return java.util.Collections.unmodifiableList(typeParameter_);
+ }
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.Builder addTypeParameterBuilder() {
+ return getTypeParameterFieldBuilder().addBuilder(
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.getDefaultInstance());
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.Builder addTypeParameterBuilder(
+ int index) {
+ return getTypeParameterFieldBuilder().addBuilder(
+ index, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.getDefaultInstance());
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public java.util.List
+ getTypeParameterBuilderList() {
+ return getTypeParameterFieldBuilder().getBuilderList();
+ }
+ private com.google.protobuf.RepeatedFieldBuilder<
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.Builder, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameterOrBuilder>
+ getTypeParameterFieldBuilder() {
+ if (typeParameterBuilder_ == null) {
+ typeParameterBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameter.Builder, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeParameterOrBuilder>(
+ typeParameter_,
+ ((bitField0_ & 0x00000004) == 0x00000004),
+ getParentForChildren(),
+ isClean());
+ typeParameter_ = null;
+ }
+ return typeParameterBuilder_;
+ }
+
+ // optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ private org.jetbrains.kotlin.serialization.DebugProtoBuf.Type underlyingType_ = org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.getDefaultInstance();
+ private com.google.protobuf.SingleFieldBuilder<
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.Type, org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.Builder, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeOrBuilder> underlyingTypeBuilder_;
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public boolean hasUnderlyingType() {
+ return ((bitField0_ & 0x00000008) == 0x00000008);
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.Type getUnderlyingType() {
+ if (underlyingTypeBuilder_ == null) {
+ return underlyingType_;
+ } else {
+ return underlyingTypeBuilder_.getMessage();
+ }
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public Builder setUnderlyingType(org.jetbrains.kotlin.serialization.DebugProtoBuf.Type value) {
+ if (underlyingTypeBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ underlyingType_ = value;
+ onChanged();
+ } else {
+ underlyingTypeBuilder_.setMessage(value);
+ }
+ bitField0_ |= 0x00000008;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public Builder setUnderlyingType(
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.Builder builderForValue) {
+ if (underlyingTypeBuilder_ == null) {
+ underlyingType_ = builderForValue.build();
+ onChanged();
+ } else {
+ underlyingTypeBuilder_.setMessage(builderForValue.build());
+ }
+ bitField0_ |= 0x00000008;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public Builder mergeUnderlyingType(org.jetbrains.kotlin.serialization.DebugProtoBuf.Type value) {
+ if (underlyingTypeBuilder_ == null) {
+ if (((bitField0_ & 0x00000008) == 0x00000008) &&
+ underlyingType_ != org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.getDefaultInstance()) {
+ underlyingType_ =
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.newBuilder(underlyingType_).mergeFrom(value).buildPartial();
+ } else {
+ underlyingType_ = value;
+ }
+ onChanged();
+ } else {
+ underlyingTypeBuilder_.mergeFrom(value);
+ }
+ bitField0_ |= 0x00000008;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public Builder clearUnderlyingType() {
+ if (underlyingTypeBuilder_ == null) {
+ underlyingType_ = org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.getDefaultInstance();
+ onChanged();
+ } else {
+ underlyingTypeBuilder_.clear();
+ }
+ bitField0_ = (bitField0_ & ~0x00000008);
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.Builder getUnderlyingTypeBuilder() {
+ bitField0_ |= 0x00000008;
+ onChanged();
+ return getUnderlyingTypeFieldBuilder().getBuilder();
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeOrBuilder getUnderlyingTypeOrBuilder() {
+ if (underlyingTypeBuilder_ != null) {
+ return underlyingTypeBuilder_.getMessageOrBuilder();
+ } else {
+ return underlyingType_;
+ }
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ private com.google.protobuf.SingleFieldBuilder<
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.Type, org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.Builder, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeOrBuilder>
+ getUnderlyingTypeFieldBuilder() {
+ if (underlyingTypeBuilder_ == null) {
+ underlyingTypeBuilder_ = new com.google.protobuf.SingleFieldBuilder<
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.Type, org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.Builder, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeOrBuilder>(
+ underlyingType_,
+ getParentForChildren(),
+ isClean());
+ underlyingType_ = null;
+ }
+ return underlyingTypeBuilder_;
+ }
+
+ // optional int32 underlying_type_id = 5;
+ private int underlyingTypeId_ ;
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ public boolean hasUnderlyingTypeId() {
+ return ((bitField0_ & 0x00000010) == 0x00000010);
+ }
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ public int getUnderlyingTypeId() {
+ return underlyingTypeId_;
+ }
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ public Builder setUnderlyingTypeId(int value) {
+ bitField0_ |= 0x00000010;
+ underlyingTypeId_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ public Builder clearUnderlyingTypeId() {
+ bitField0_ = (bitField0_ & ~0x00000010);
+ underlyingTypeId_ = 0;
+ onChanged();
+ return this;
+ }
+
+ // optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ private org.jetbrains.kotlin.serialization.DebugProtoBuf.Type expandedType_ = org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.getDefaultInstance();
+ private com.google.protobuf.SingleFieldBuilder<
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.Type, org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.Builder, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeOrBuilder> expandedTypeBuilder_;
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public boolean hasExpandedType() {
+ return ((bitField0_ & 0x00000020) == 0x00000020);
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.Type getExpandedType() {
+ if (expandedTypeBuilder_ == null) {
+ return expandedType_;
+ } else {
+ return expandedTypeBuilder_.getMessage();
+ }
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public Builder setExpandedType(org.jetbrains.kotlin.serialization.DebugProtoBuf.Type value) {
+ if (expandedTypeBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ expandedType_ = value;
+ onChanged();
+ } else {
+ expandedTypeBuilder_.setMessage(value);
+ }
+ bitField0_ |= 0x00000020;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public Builder setExpandedType(
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.Builder builderForValue) {
+ if (expandedTypeBuilder_ == null) {
+ expandedType_ = builderForValue.build();
+ onChanged();
+ } else {
+ expandedTypeBuilder_.setMessage(builderForValue.build());
+ }
+ bitField0_ |= 0x00000020;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public Builder mergeExpandedType(org.jetbrains.kotlin.serialization.DebugProtoBuf.Type value) {
+ if (expandedTypeBuilder_ == null) {
+ if (((bitField0_ & 0x00000020) == 0x00000020) &&
+ expandedType_ != org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.getDefaultInstance()) {
+ expandedType_ =
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.newBuilder(expandedType_).mergeFrom(value).buildPartial();
+ } else {
+ expandedType_ = value;
+ }
+ onChanged();
+ } else {
+ expandedTypeBuilder_.mergeFrom(value);
+ }
+ bitField0_ |= 0x00000020;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public Builder clearExpandedType() {
+ if (expandedTypeBuilder_ == null) {
+ expandedType_ = org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.getDefaultInstance();
+ onChanged();
+ } else {
+ expandedTypeBuilder_.clear();
+ }
+ bitField0_ = (bitField0_ & ~0x00000020);
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.Builder getExpandedTypeBuilder() {
+ bitField0_ |= 0x00000020;
+ onChanged();
+ return getExpandedTypeFieldBuilder().getBuilder();
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeOrBuilder getExpandedTypeOrBuilder() {
+ if (expandedTypeBuilder_ != null) {
+ return expandedTypeBuilder_.getMessageOrBuilder();
+ } else {
+ return expandedType_;
+ }
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ private com.google.protobuf.SingleFieldBuilder<
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.Type, org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.Builder, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeOrBuilder>
+ getExpandedTypeFieldBuilder() {
+ if (expandedTypeBuilder_ == null) {
+ expandedTypeBuilder_ = new com.google.protobuf.SingleFieldBuilder<
+ org.jetbrains.kotlin.serialization.DebugProtoBuf.Type, org.jetbrains.kotlin.serialization.DebugProtoBuf.Type.Builder, org.jetbrains.kotlin.serialization.DebugProtoBuf.TypeOrBuilder>(
+ expandedType_,
+ getParentForChildren(),
+ isClean());
+ expandedType_ = null;
+ }
+ return expandedTypeBuilder_;
+ }
+
+ // optional int32 expanded_type_id = 7;
+ private int expandedTypeId_ ;
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ public boolean hasExpandedTypeId() {
+ return ((bitField0_ & 0x00000040) == 0x00000040);
+ }
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ public int getExpandedTypeId() {
+ return expandedTypeId_;
+ }
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ public Builder setExpandedTypeId(int value) {
+ bitField0_ |= 0x00000040;
+ expandedTypeId_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ public Builder clearExpandedTypeId() {
+ bitField0_ = (bitField0_ & ~0x00000040);
+ expandedTypeId_ = 0;
+ onChanged();
+ return this;
+ }
+
+ // @@protoc_insertion_point(builder_scope:org.jetbrains.kotlin.serialization.TypeAlias)
+ }
+
+ static {
+ defaultInstance = new TypeAlias(true);
+ defaultInstance.initFields();
+ }
+
+ // @@protoc_insertion_point(class_scope:org.jetbrains.kotlin.serialization.TypeAlias)
+ }
+
public interface EnumEntryOrBuilder extends
com.google.protobuf.GeneratedMessage.
ExtendableMessageOrBuilder {
@@ -21703,6 +24309,11 @@ public final class DebugProtoBuf {
private static
com.google.protobuf.GeneratedMessage.FieldAccessorTable
internal_static_org_jetbrains_kotlin_serialization_ValueParameter_fieldAccessorTable;
+ private static com.google.protobuf.Descriptors.Descriptor
+ internal_static_org_jetbrains_kotlin_serialization_TypeAlias_descriptor;
+ private static
+ com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ internal_static_org_jetbrains_kotlin_serialization_TypeAlias_fieldAccessorTable;
private static com.google.protobuf.Descriptors.Descriptor
internal_static_org_jetbrains_kotlin_serialization_EnumEntry_descriptor;
private static
@@ -21748,7 +24359,7 @@ public final class DebugProtoBuf {
"\n\004BYTE\020\000\022\010\n\004CHAR\020\001\022\t\n\005SHORT\020\002\022\007\n\003INT\020\003\022\010" +
"\n\004LONG\020\004\022\t\n\005FLOAT\020\005\022\n\n\006DOUBLE\020\006\022\013\n\007BOOLE",
"AN\020\007\022\n\n\006STRING\020\010\022\t\n\005CLASS\020\t\022\010\n\004ENUM\020\n\022\016\n" +
- "\nANNOTATION\020\013\022\t\n\005ARRAY\020\014\"\212\005\n\004Type\022C\n\010arg" +
+ "\nANNOTATION\020\013\022\t\n\005ARRAY\020\014\"\212\006\n\004Type\022C\n\010arg" +
"ument\030\002 \003(\01321.org.jetbrains.kotlin.seria" +
"lization.Type.Argument\022\027\n\010nullable\030\003 \001(\010" +
":\005false\022+\n\035flexible_type_capabilities_id" +
@@ -21757,88 +24368,103 @@ public final class DebugProtoBuf {
"Type\022\037\n\027flexible_upper_bound_id\030\010 \001(\005\022\030\n" +
"\nclass_name\030\006 \001(\005B\004\220\265\030\001\022\026\n\016type_paramete" +
"r\030\007 \001(\005\022!\n\023type_parameter_name\030\t \001(\005B\004\210\265",
- "\030\001\022<\n\nouter_type\030\n \001(\0132(.org.jetbrains.k" +
- "otlin.serialization.Type\022\025\n\router_type_i" +
- "d\030\013 \001(\005\032\334\001\n\010Argument\022U\n\nprojection\030\001 \001(\016" +
- "2<.org.jetbrains.kotlin.serialization.Ty" +
- "pe.Argument.Projection:\003INV\0226\n\004type\030\002 \001(" +
- "\0132(.org.jetbrains.kotlin.serialization.T" +
- "ype\022\017\n\007type_id\030\003 \001(\005\"0\n\nProjection\022\006\n\002IN" +
- "\020\000\022\007\n\003OUT\020\001\022\007\n\003INV\020\002\022\010\n\004STAR\020\003*\005\010d\020\310\001\"\236\002" +
- "\n\rTypeParameter\022\n\n\002id\030\001 \002(\005\022\022\n\004name\030\002 \002(" +
- "\005B\004\210\265\030\001\022\026\n\007reified\030\003 \001(\010:\005false\022Q\n\010varia",
- "nce\030\004 \001(\0162:.org.jetbrains.kotlin.seriali" +
- "zation.TypeParameter.Variance:\003INV\022=\n\013up" +
- "per_bound\030\005 \003(\0132(.org.jetbrains.kotlin.s" +
- "erialization.Type\022\026\n\016upper_bound_id\030\006 \003(" +
- "\005\"$\n\010Variance\022\006\n\002IN\020\000\022\007\n\003OUT\020\001\022\007\n\003INV\020\002*" +
- "\005\010d\020\350\007\"\347\005\n\005Class\022\020\n\005flags\030\001 \001(\005:\0016\022\025\n\007fq" +
- "_name\030\003 \002(\005B\004\220\265\030\001\022#\n\025companion_object_na" +
- "me\030\004 \001(\005B\004\210\265\030\001\022I\n\016type_parameter\030\005 \003(\01321" +
- ".org.jetbrains.kotlin.serialization.Type" +
- "Parameter\022;\n\tsupertype\030\006 \003(\0132(.org.jetbr",
- "ains.kotlin.serialization.Type\022\030\n\014supert" +
- "ype_id\030\002 \003(\005B\002\020\001\022!\n\021nested_class_name\030\007 " +
- "\003(\005B\006\020\001\210\265\030\001\022D\n\013constructor\030\010 \003(\0132/.org.j" +
- "etbrains.kotlin.serialization.Constructo" +
- "r\022>\n\010function\030\t \003(\0132,.org.jetbrains.kotl" +
- "in.serialization.Function\022>\n\010property\030\n " +
- "\003(\0132,.org.jetbrains.kotlin.serialization" +
- ".Property\022A\n\nenum_entry\030\r \003(\0132-.org.jetb" +
- "rains.kotlin.serialization.EnumEntry\022A\n\n" +
- "type_table\030\036 \001(\0132-.org.jetbrains.kotlin.",
- "serialization.TypeTable\"x\n\004Kind\022\t\n\005CLASS" +
- "\020\000\022\r\n\tINTERFACE\020\001\022\016\n\nENUM_CLASS\020\002\022\016\n\nENU" +
- "M_ENTRY\020\003\022\024\n\020ANNOTATION_CLASS\020\004\022\n\n\006OBJEC" +
- "T\020\005\022\024\n\020COMPANION_OBJECT\020\006*\005\010d\020\310\001\"\323\001\n\007Pac" +
- "kage\022>\n\010function\030\003 \003(\0132,.org.jetbrains.k" +
- "otlin.serialization.Function\022>\n\010property" +
- "\030\004 \003(\0132,.org.jetbrains.kotlin.serializat" +
- "ion.Property\022A\n\ntype_table\030\036 \001(\0132-.org.j" +
- "etbrains.kotlin.serialization.TypeTable*" +
- "\005\010d\020\310\001\"_\n\tTypeTable\0226\n\004type\030\001 \003(\0132(.org.",
- "jetbrains.kotlin.serialization.Type\022\032\n\016f" +
- "irst_nullable\030\002 \001(\005:\002-1\"s\n\013Constructor\022\020" +
- "\n\005flags\030\001 \001(\005:\0016\022K\n\017value_parameter\030\002 \003(" +
- "\01322.org.jetbrains.kotlin.serialization.V" +
- "alueParameter*\005\010d\020\310\001\"\332\003\n\010Function\022\020\n\005fla" +
- "gs\030\t \001(\005:\0016\022\024\n\told_flags\030\001 \001(\005:\0016\022\022\n\004nam" +
- "e\030\002 \002(\005B\004\210\265\030\001\022=\n\013return_type\030\003 \001(\0132(.org" +
- ".jetbrains.kotlin.serialization.Type\022\026\n\016" +
- "return_type_id\030\007 \001(\005\022I\n\016type_parameter\030\004" +
- " \003(\01321.org.jetbrains.kotlin.serializatio",
- "n.TypeParameter\022?\n\rreceiver_type\030\005 \001(\0132(" +
- ".org.jetbrains.kotlin.serialization.Type" +
- "\022\030\n\020receiver_type_id\030\010 \001(\005\022K\n\017value_para" +
- "meter\030\006 \003(\01322.org.jetbrains.kotlin.seria" +
- "lization.ValueParameter\022A\n\ntype_table\030\036 " +
- "\001(\0132-.org.jetbrains.kotlin.serialization" +
- ".TypeTable*\005\010d\020\310\001\"\317\003\n\010Property\022\022\n\005flags\030" +
- "\013 \001(\005:\003518\022\027\n\told_flags\030\001 \001(\005:\0042054\022\022\n\004n" +
- "ame\030\002 \002(\005B\004\210\265\030\001\022=\n\013return_type\030\003 \001(\0132(.o" +
- "rg.jetbrains.kotlin.serialization.Type\022\026",
- "\n\016return_type_id\030\t \001(\005\022I\n\016type_parameter" +
- "\030\004 \003(\01321.org.jetbrains.kotlin.serializat" +
- "ion.TypeParameter\022?\n\rreceiver_type\030\005 \001(\013" +
- "2(.org.jetbrains.kotlin.serialization.Ty" +
- "pe\022\030\n\020receiver_type_id\030\n \001(\005\022R\n\026setter_v" +
- "alue_parameter\030\006 \001(\01322.org.jetbrains.kot" +
- "lin.serialization.ValueParameter\022\024\n\014gett" +
- "er_flags\030\007 \001(\005\022\024\n\014setter_flags\030\010 \001(\005*\005\010d" +
- "\020\310\001\"\355\001\n\016ValueParameter\022\020\n\005flags\030\001 \001(\005:\0010" +
- "\022\022\n\004name\030\002 \002(\005B\004\210\265\030\001\0226\n\004type\030\003 \001(\0132(.org",
- ".jetbrains.kotlin.serialization.Type\022\017\n\007" +
- "type_id\030\005 \001(\005\022E\n\023vararg_element_type\030\004 \001" +
- "(\0132(.org.jetbrains.kotlin.serialization." +
- "Type\022\036\n\026vararg_element_type_id\030\006 \001(\005*\005\010d" +
- "\020\310\001\"&\n\tEnumEntry\022\022\n\004name\030\001 \001(\005B\004\210\265\030\001*\005\010d" +
- "\020\310\001*9\n\010Modality\022\t\n\005FINAL\020\000\022\010\n\004OPEN\020\001\022\014\n\010" +
- "ABSTRACT\020\002\022\n\n\006SEALED\020\003*b\n\nVisibility\022\014\n\010" +
- "INTERNAL\020\000\022\013\n\007PRIVATE\020\001\022\r\n\tPROTECTED\020\002\022\n" +
- "\n\006PUBLIC\020\003\022\023\n\017PRIVATE_TO_THIS\020\004\022\t\n\005LOCAL" +
- "\020\005*Q\n\nMemberKind\022\017\n\013DECLARATION\020\000\022\021\n\rFAK",
- "E_OVERRIDE\020\001\022\016\n\nDELEGATION\020\002\022\017\n\013SYNTHESI" +
- "ZED\020\003B\022B\rDebugProtoBuf\210\001\000"
+ "\030\001\022\035\n\017type_alias_name\030\014 \001(\005B\004\210\265\030\001\022<\n\nout" +
+ "er_type\030\n \001(\0132(.org.jetbrains.kotlin.ser" +
+ "ialization.Type\022\025\n\router_type_id\030\013 \001(\005\022B" +
+ "\n\020abbreviated_type\030\r \001(\0132(.org.jetbrains" +
+ ".kotlin.serialization.Type\022\033\n\023abbreviate" +
+ "d_type_id\030\016 \001(\005\032\334\001\n\010Argument\022U\n\nprojecti" +
+ "on\030\001 \001(\0162<.org.jetbrains.kotlin.serializ" +
+ "ation.Type.Argument.Projection:\003INV\0226\n\004t" +
+ "ype\030\002 \001(\0132(.org.jetbrains.kotlin.seriali" +
+ "zation.Type\022\017\n\007type_id\030\003 \001(\005\"0\n\nProjecti",
+ "on\022\006\n\002IN\020\000\022\007\n\003OUT\020\001\022\007\n\003INV\020\002\022\010\n\004STAR\020\003*\005" +
+ "\010d\020\310\001\"\236\002\n\rTypeParameter\022\n\n\002id\030\001 \002(\005\022\022\n\004n" +
+ "ame\030\002 \002(\005B\004\210\265\030\001\022\026\n\007reified\030\003 \001(\010:\005false\022" +
+ "Q\n\010variance\030\004 \001(\0162:.org.jetbrains.kotlin" +
+ ".serialization.TypeParameter.Variance:\003I" +
+ "NV\022=\n\013upper_bound\030\005 \003(\0132(.org.jetbrains." +
+ "kotlin.serialization.Type\022\026\n\016upper_bound" +
+ "_id\030\006 \003(\005\"$\n\010Variance\022\006\n\002IN\020\000\022\007\n\003OUT\020\001\022\007" +
+ "\n\003INV\020\002*\005\010d\020\350\007\"\252\006\n\005Class\022\020\n\005flags\030\001 \001(\005:" +
+ "\0016\022\025\n\007fq_name\030\003 \002(\005B\004\220\265\030\001\022#\n\025companion_o",
+ "bject_name\030\004 \001(\005B\004\210\265\030\001\022I\n\016type_parameter" +
+ "\030\005 \003(\01321.org.jetbrains.kotlin.serializat" +
+ "ion.TypeParameter\022;\n\tsupertype\030\006 \003(\0132(.o" +
+ "rg.jetbrains.kotlin.serialization.Type\022\030" +
+ "\n\014supertype_id\030\002 \003(\005B\002\020\001\022!\n\021nested_class" +
+ "_name\030\007 \003(\005B\006\020\001\210\265\030\001\022D\n\013constructor\030\010 \003(\013" +
+ "2/.org.jetbrains.kotlin.serialization.Co" +
+ "nstructor\022>\n\010function\030\t \003(\0132,.org.jetbra" +
+ "ins.kotlin.serialization.Function\022>\n\010pro" +
+ "perty\030\n \003(\0132,.org.jetbrains.kotlin.seria",
+ "lization.Property\022A\n\ntype_alias\030\013 \003(\0132-." +
+ "org.jetbrains.kotlin.serialization.TypeA" +
+ "lias\022A\n\nenum_entry\030\r \003(\0132-.org.jetbrains" +
+ ".kotlin.serialization.EnumEntry\022A\n\ntype_" +
+ "table\030\036 \001(\0132-.org.jetbrains.kotlin.seria" +
+ "lization.TypeTable\"x\n\004Kind\022\t\n\005CLASS\020\000\022\r\n" +
+ "\tINTERFACE\020\001\022\016\n\nENUM_CLASS\020\002\022\016\n\nENUM_ENT" +
+ "RY\020\003\022\024\n\020ANNOTATION_CLASS\020\004\022\n\n\006OBJECT\020\005\022\024" +
+ "\n\020COMPANION_OBJECT\020\006*\005\010d\020\310\001\"\226\002\n\007Package\022" +
+ ">\n\010function\030\003 \003(\0132,.org.jetbrains.kotlin",
+ ".serialization.Function\022>\n\010property\030\004 \003(" +
+ "\0132,.org.jetbrains.kotlin.serialization.P" +
+ "roperty\022A\n\ntype_alias\030\005 \003(\0132-.org.jetbra" +
+ "ins.kotlin.serialization.TypeAlias\022A\n\nty" +
+ "pe_table\030\036 \001(\0132-.org.jetbrains.kotlin.se" +
+ "rialization.TypeTable*\005\010d\020\310\001\"_\n\tTypeTabl" +
+ "e\0226\n\004type\030\001 \003(\0132(.org.jetbrains.kotlin.s" +
+ "erialization.Type\022\032\n\016first_nullable\030\002 \001(" +
+ "\005:\002-1\"s\n\013Constructor\022\020\n\005flags\030\001 \001(\005:\0016\022K" +
+ "\n\017value_parameter\030\002 \003(\01322.org.jetbrains.",
+ "kotlin.serialization.ValueParameter*\005\010d\020" +
+ "\310\001\"\332\003\n\010Function\022\020\n\005flags\030\t \001(\005:\0016\022\024\n\told" +
+ "_flags\030\001 \001(\005:\0016\022\022\n\004name\030\002 \002(\005B\004\210\265\030\001\022=\n\013r" +
+ "eturn_type\030\003 \001(\0132(.org.jetbrains.kotlin." +
+ "serialization.Type\022\026\n\016return_type_id\030\007 \001" +
+ "(\005\022I\n\016type_parameter\030\004 \003(\01321.org.jetbrai" +
+ "ns.kotlin.serialization.TypeParameter\022?\n" +
+ "\rreceiver_type\030\005 \001(\0132(.org.jetbrains.kot" +
+ "lin.serialization.Type\022\030\n\020receiver_type_" +
+ "id\030\010 \001(\005\022K\n\017value_parameter\030\006 \003(\01322.org.",
+ "jetbrains.kotlin.serialization.ValuePara" +
+ "meter\022A\n\ntype_table\030\036 \001(\0132-.org.jetbrain" +
+ "s.kotlin.serialization.TypeTable*\005\010d\020\310\001\"" +
+ "\317\003\n\010Property\022\022\n\005flags\030\013 \001(\005:\003518\022\027\n\told_" +
+ "flags\030\001 \001(\005:\0042054\022\022\n\004name\030\002 \002(\005B\004\210\265\030\001\022=\n" +
+ "\013return_type\030\003 \001(\0132(.org.jetbrains.kotli" +
+ "n.serialization.Type\022\026\n\016return_type_id\030\t" +
+ " \001(\005\022I\n\016type_parameter\030\004 \003(\01321.org.jetbr" +
+ "ains.kotlin.serialization.TypeParameter\022" +
+ "?\n\rreceiver_type\030\005 \001(\0132(.org.jetbrains.k",
+ "otlin.serialization.Type\022\030\n\020receiver_typ" +
+ "e_id\030\n \001(\005\022R\n\026setter_value_parameter\030\006 \001" +
+ "(\01322.org.jetbrains.kotlin.serialization." +
+ "ValueParameter\022\024\n\014getter_flags\030\007 \001(\005\022\024\n\014" +
+ "setter_flags\030\010 \001(\005*\005\010d\020\310\001\"\355\001\n\016ValueParam" +
+ "eter\022\020\n\005flags\030\001 \001(\005:\0010\022\022\n\004name\030\002 \002(\005B\004\210\265" +
+ "\030\001\0226\n\004type\030\003 \001(\0132(.org.jetbrains.kotlin." +
+ "serialization.Type\022\017\n\007type_id\030\005 \001(\005\022E\n\023v" +
+ "ararg_element_type\030\004 \001(\0132(.org.jetbrains" +
+ ".kotlin.serialization.Type\022\036\n\026vararg_ele",
+ "ment_type_id\030\006 \001(\005*\005\010d\020\310\001\"\275\002\n\tTypeAlias\022" +
+ "\020\n\005flags\030\001 \001(\005:\0010\022\022\n\004name\030\002 \002(\005B\004\210\265\030\001\022I\n" +
+ "\016type_parameter\030\003 \003(\01321.org.jetbrains.ko" +
+ "tlin.serialization.TypeParameter\022A\n\017unde" +
+ "rlying_type\030\004 \001(\0132(.org.jetbrains.kotlin" +
+ ".serialization.Type\022\032\n\022underlying_type_i" +
+ "d\030\005 \001(\005\022?\n\rexpanded_type\030\006 \001(\0132(.org.jet" +
+ "brains.kotlin.serialization.Type\022\030\n\020expa" +
+ "nded_type_id\030\007 \001(\005*\005\010d\020\310\001\"&\n\tEnumEntry\022\022" +
+ "\n\004name\030\001 \001(\005B\004\210\265\030\001*\005\010d\020\310\001*9\n\010Modality\022\t\n",
+ "\005FINAL\020\000\022\010\n\004OPEN\020\001\022\014\n\010ABSTRACT\020\002\022\n\n\006SEAL" +
+ "ED\020\003*b\n\nVisibility\022\014\n\010INTERNAL\020\000\022\013\n\007PRIV" +
+ "ATE\020\001\022\r\n\tPROTECTED\020\002\022\n\n\006PUBLIC\020\003\022\023\n\017PRIV" +
+ "ATE_TO_THIS\020\004\022\t\n\005LOCAL\020\005*Q\n\nMemberKind\022\017" +
+ "\n\013DECLARATION\020\000\022\021\n\rFAKE_OVERRIDE\020\001\022\016\n\nDE" +
+ "LEGATION\020\002\022\017\n\013SYNTHESIZED\020\003B\022B\rDebugProt" +
+ "oBuf\210\001\000"
};
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() {
@@ -21886,7 +24512,7 @@ public final class DebugProtoBuf {
internal_static_org_jetbrains_kotlin_serialization_Type_fieldAccessorTable = new
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_org_jetbrains_kotlin_serialization_Type_descriptor,
- new java.lang.String[] { "Argument", "Nullable", "FlexibleTypeCapabilitiesId", "FlexibleUpperBound", "FlexibleUpperBoundId", "ClassName", "TypeParameter", "TypeParameterName", "OuterType", "OuterTypeId", });
+ new java.lang.String[] { "Argument", "Nullable", "FlexibleTypeCapabilitiesId", "FlexibleUpperBound", "FlexibleUpperBoundId", "ClassName", "TypeParameter", "TypeParameterName", "TypeAliasName", "OuterType", "OuterTypeId", "AbbreviatedType", "AbbreviatedTypeId", });
internal_static_org_jetbrains_kotlin_serialization_Type_Argument_descriptor =
internal_static_org_jetbrains_kotlin_serialization_Type_descriptor.getNestedTypes().get(0);
internal_static_org_jetbrains_kotlin_serialization_Type_Argument_fieldAccessorTable = new
@@ -21904,13 +24530,13 @@ public final class DebugProtoBuf {
internal_static_org_jetbrains_kotlin_serialization_Class_fieldAccessorTable = new
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_org_jetbrains_kotlin_serialization_Class_descriptor,
- new java.lang.String[] { "Flags", "FqName", "CompanionObjectName", "TypeParameter", "Supertype", "SupertypeId", "NestedClassName", "Constructor", "Function", "Property", "EnumEntry", "TypeTable", });
+ new java.lang.String[] { "Flags", "FqName", "CompanionObjectName", "TypeParameter", "Supertype", "SupertypeId", "NestedClassName", "Constructor", "Function", "Property", "TypeAlias", "EnumEntry", "TypeTable", });
internal_static_org_jetbrains_kotlin_serialization_Package_descriptor =
getDescriptor().getMessageTypes().get(6);
internal_static_org_jetbrains_kotlin_serialization_Package_fieldAccessorTable = new
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_org_jetbrains_kotlin_serialization_Package_descriptor,
- new java.lang.String[] { "Function", "Property", "TypeTable", });
+ new java.lang.String[] { "Function", "Property", "TypeAlias", "TypeTable", });
internal_static_org_jetbrains_kotlin_serialization_TypeTable_descriptor =
getDescriptor().getMessageTypes().get(7);
internal_static_org_jetbrains_kotlin_serialization_TypeTable_fieldAccessorTable = new
@@ -21941,8 +24567,14 @@ public final class DebugProtoBuf {
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_org_jetbrains_kotlin_serialization_ValueParameter_descriptor,
new java.lang.String[] { "Flags", "Name", "Type", "TypeId", "VarargElementType", "VarargElementTypeId", });
- internal_static_org_jetbrains_kotlin_serialization_EnumEntry_descriptor =
+ internal_static_org_jetbrains_kotlin_serialization_TypeAlias_descriptor =
getDescriptor().getMessageTypes().get(12);
+ internal_static_org_jetbrains_kotlin_serialization_TypeAlias_fieldAccessorTable = new
+ com.google.protobuf.GeneratedMessage.FieldAccessorTable(
+ internal_static_org_jetbrains_kotlin_serialization_TypeAlias_descriptor,
+ new java.lang.String[] { "Flags", "Name", "TypeParameter", "UnderlyingType", "UnderlyingTypeId", "ExpandedType", "ExpandedTypeId", });
+ internal_static_org_jetbrains_kotlin_serialization_EnumEntry_descriptor =
+ getDescriptor().getMessageTypes().get(13);
internal_static_org_jetbrains_kotlin_serialization_EnumEntry_fieldAccessorTable = new
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_org_jetbrains_kotlin_serialization_EnumEntry_descriptor,
@@ -21958,6 +24590,7 @@ public final class DebugProtoBuf {
registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.fqNameIdInTable);
registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.nameIdInTable);
registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.nameIdInTable);
+ registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.nameIdInTable);
registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.fqNameIdInTable);
registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.nameIdInTable);
registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.nameIdInTable);
@@ -21965,6 +24598,7 @@ public final class DebugProtoBuf {
registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.nameIdInTable);
registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.nameIdInTable);
registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.nameIdInTable);
+ registry.add(org.jetbrains.kotlin.serialization.DebugExtOptionsProtoBuf.nameIdInTable);
return registry;
}
};
diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/PackagePartCodegen.java b/compiler/backend/src/org/jetbrains/kotlin/codegen/PackagePartCodegen.java
index 885e968b5dd..247a985d81e 100644
--- a/compiler/backend/src/org/jetbrains/kotlin/codegen/PackagePartCodegen.java
+++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/PackagePartCodegen.java
@@ -27,6 +27,7 @@ import org.jetbrains.kotlin.codegen.serialization.JvmSerializerExtension;
import org.jetbrains.kotlin.codegen.state.GenerationState;
import org.jetbrains.kotlin.descriptors.DeclarationDescriptor;
import org.jetbrains.kotlin.descriptors.SimpleFunctionDescriptor;
+import org.jetbrains.kotlin.descriptors.TypeAliasDescriptor;
import org.jetbrains.kotlin.descriptors.VariableDescriptor;
import org.jetbrains.kotlin.descriptors.annotations.Annotated;
import org.jetbrains.kotlin.descriptors.annotations.AnnotationDescriptor;
@@ -112,10 +113,15 @@ public class PackagePartCodegen extends MemberCodegen {
if (declaration instanceof KtNamedFunction) {
SimpleFunctionDescriptor functionDescriptor = bindingContext.get(BindingContext.FUNCTION, declaration);
members.add(functionDescriptor);
- } else if (declaration instanceof KtProperty) {
+ }
+ else if (declaration instanceof KtProperty) {
VariableDescriptor property = bindingContext.get(BindingContext.VARIABLE, declaration);
members.add(property);
}
+ else if (declaration instanceof KtTypeAlias) {
+ TypeAliasDescriptor typeAlias = bindingContext.get(BindingContext.TYPE_ALIAS, declaration);
+ members.add(typeAlias);
+ }
}
final DescriptorSerializer serializer =
diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/serialization/JvmStringTable.kt b/compiler/backend/src/org/jetbrains/kotlin/codegen/serialization/JvmStringTable.kt
index a236d2d3d43..411f1a00ed1 100644
--- a/compiler/backend/src/org/jetbrains/kotlin/codegen/serialization/JvmStringTable.kt
+++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/serialization/JvmStringTable.kt
@@ -18,6 +18,7 @@ package org.jetbrains.kotlin.codegen.serialization
import org.jetbrains.kotlin.codegen.state.KotlinTypeMapper
import org.jetbrains.kotlin.descriptors.ClassDescriptor
+import org.jetbrains.kotlin.descriptors.ClassifierDescriptorWithTypeParameters
import org.jetbrains.kotlin.descriptors.PackageFragmentDescriptor
import org.jetbrains.kotlin.load.kotlin.JvmNameResolver
import org.jetbrains.kotlin.name.ClassId
@@ -53,7 +54,7 @@ class JvmStringTable(private val typeMapper: KotlinTypeMapper) : StringTable {
return !hasPredefinedIndex() && !hasOperation() && substringIndexCount == 0 && replaceCharCount == 0
}
- override fun getFqNameIndex(descriptor: ClassDescriptor): Int {
+ override fun getFqNameIndex(descriptor: ClassifierDescriptorWithTypeParameters): Int {
if (ErrorUtils.isError(descriptor)) {
throw IllegalStateException("Cannot get FQ name of error class: " + descriptor)
}
@@ -109,7 +110,7 @@ class JvmStringTable(private val typeMapper: KotlinTypeMapper) : StringTable {
return index
}
- private val ClassDescriptor.classId: ClassId
+ private val ClassifierDescriptorWithTypeParameters.classId: ClassId
get() {
val container = containingDeclaration
return when (container) {
diff --git a/compiler/frontend/src/org/jetbrains/kotlin/resolve/BindingContext.java b/compiler/frontend/src/org/jetbrains/kotlin/resolve/BindingContext.java
index 613fc9098bf..35f3a5d0d2c 100644
--- a/compiler/frontend/src/org/jetbrains/kotlin/resolve/BindingContext.java
+++ b/compiler/frontend/src/org/jetbrains/kotlin/resolve/BindingContext.java
@@ -91,6 +91,7 @@ public interface BindingContext {
WritableSlice> COMPILE_TIME_VALUE = Slices.createSimpleSlice();
WritableSlice TYPE = Slices.createSimpleSlice();
+ WritableSlice ABBREVIATED_TYPE = Slices.createSimpleSlice();
WritableSlice EXPRESSION_TYPE_INFO = new BasicWritableSlice(DO_NOTHING);
WritableSlice EXPECTED_EXPRESSION_TYPE = new BasicWritableSlice(DO_NOTHING);
WritableSlice EXPECTED_RETURN_TYPE = new BasicWritableSlice(DO_NOTHING);
@@ -216,7 +217,7 @@ public interface BindingContext {
WritableSlice VALUE_PARAMETER = Slices.createSimpleSlice();
WritableSlice PROPERTY_ACCESSOR = Slices.createSimpleSlice();
WritableSlice PRIMARY_CONSTRUCTOR_PARAMETER = Slices.createSimpleSlice();
- WritableSlice TYPE_ALIAS = Slices.createSimpleSlice();
+ WritableSlice TYPE_ALIAS = Slices.createSimpleSlice();
WritableSlice[] DECLARATIONS_TO_DESCRIPTORS = new WritableSlice[] {
CLASS, TYPE_PARAMETER, FUNCTION, CONSTRUCTOR, VARIABLE, VALUE_PARAMETER, PROPERTY_ACCESSOR,
diff --git a/compiler/frontend/src/org/jetbrains/kotlin/resolve/DescriptorResolver.java b/compiler/frontend/src/org/jetbrains/kotlin/resolve/DescriptorResolver.java
index f4418ffa5d6..184114c6969 100644
--- a/compiler/frontend/src/org/jetbrains/kotlin/resolve/DescriptorResolver.java
+++ b/compiler/frontend/src/org/jetbrains/kotlin/resolve/DescriptorResolver.java
@@ -714,12 +714,21 @@ public class DescriptorResolver {
final KtTypeReference typeReference = typeAlias.getTypeReference();
- typeAliasDescriptor.initialize(typeParameterDescriptors, storageManager.createLazyValue(new Function0() {
- @Override
- public KotlinType invoke() {
- return typeResolver.resolveAbbreviatedType(scopeWithTypeParameters, typeReference, trace, true);
- }
- }));
+ typeAliasDescriptor.initialize(
+ typeParameterDescriptors,
+ storageManager.createLazyValue(new Function0() {
+ @Override
+ public KotlinType invoke() {
+ return typeResolver.resolveAbbreviatedType(scopeWithTypeParameters, typeReference, trace, true);
+ }
+ }),
+ storageManager.createLazyValue(new Function0() {
+ @Override
+ public KotlinType invoke() {
+ // TODO do not reparse
+ return typeResolver.resolveType(scopeWithTypeParameters, typeReference, trace, true);
+ }
+ }));
trace.record(TYPE_ALIAS, typeAlias, typeAliasDescriptor);
return typeAliasDescriptor;
diff --git a/compiler/frontend/src/org/jetbrains/kotlin/resolve/QualifiedExpressionResolver.kt b/compiler/frontend/src/org/jetbrains/kotlin/resolve/QualifiedExpressionResolver.kt
index e795612c243..8a04f46089f 100644
--- a/compiler/frontend/src/org/jetbrains/kotlin/resolve/QualifiedExpressionResolver.kt
+++ b/compiler/frontend/src/org/jetbrains/kotlin/resolve/QualifiedExpressionResolver.kt
@@ -371,7 +371,7 @@ class QualifiedExpressionResolver(val symbolUsageValidator: SymbolUsageValidator
val nextPackageOrClassDescriptor =
when (currentDescriptor) {
is TypeAliasDescriptor -> // TODO type aliases as qualifiers? (would break some assumptions in TypeResolver)
- currentDescriptor.underlyingClassDescriptor.getContributedClassifier(qualifierPart)
+ currentDescriptor.classDescriptor?.getContributedClassifier(qualifierPart)
is ClassDescriptor ->
currentDescriptor.getContributedClassifier(qualifierPart)
is PackageViewDescriptor -> {
diff --git a/compiler/frontend/src/org/jetbrains/kotlin/resolve/TypeResolver.kt b/compiler/frontend/src/org/jetbrains/kotlin/resolve/TypeResolver.kt
index ef79bf82e4e..1d52b22673b 100644
--- a/compiler/frontend/src/org/jetbrains/kotlin/resolve/TypeResolver.kt
+++ b/compiler/frontend/src/org/jetbrains/kotlin/resolve/TypeResolver.kt
@@ -81,9 +81,11 @@ class TypeResolver(
val cachedType = c.trace.getBindingContext().get(BindingContext.TYPE, typeReference)
if (cachedType != null) return type(cachedType)
+ val resolvedTypeSlice = if (c.abbreviated) BindingContext.ABBREVIATED_TYPE else BindingContext.TYPE
+
val debugType = typeReference.debugTypeInfo
if (debugType != null) {
- c.trace.record(BindingContext.TYPE, typeReference, debugType)
+ c.trace.record(resolvedTypeSlice, typeReference, debugType)
return type(debugType)
}
@@ -100,13 +102,13 @@ class TypeResolver(
}
val lazyKotlinType = LazyKotlinType()
- c.trace.record(BindingContext.TYPE, typeReference, lazyKotlinType)
+ c.trace.record(resolvedTypeSlice, typeReference, lazyKotlinType)
return type(lazyKotlinType)
}
val type = doResolvePossiblyBareType(c, typeReference)
if (!type.isBare()) {
- c.trace.record(BindingContext.TYPE, typeReference, type.getActualType())
+ c.trace.record(resolvedTypeSlice, typeReference, type.getActualType())
}
return type
}
diff --git a/compiler/frontend/src/org/jetbrains/kotlin/resolve/lazy/descriptors/TypeAliasDescriptorImpl.kt b/compiler/frontend/src/org/jetbrains/kotlin/resolve/lazy/descriptors/TypeAliasDescriptorImpl.kt
index 4d7e3a604a2..8cc2b33a9c5 100644
--- a/compiler/frontend/src/org/jetbrains/kotlin/resolve/lazy/descriptors/TypeAliasDescriptorImpl.kt
+++ b/compiler/frontend/src/org/jetbrains/kotlin/resolve/lazy/descriptors/TypeAliasDescriptorImpl.kt
@@ -26,6 +26,7 @@ import org.jetbrains.kotlin.resolve.descriptorUtil.builtIns
import org.jetbrains.kotlin.resolve.scopes.LexicalScope
import org.jetbrains.kotlin.storage.NotNullLazyValue
import org.jetbrains.kotlin.storage.StorageManager
+import org.jetbrains.kotlin.storage.getValue
import org.jetbrains.kotlin.types.KotlinType
import org.jetbrains.kotlin.types.TypeConstructor
import org.jetbrains.kotlin.types.TypeSubstitutor
@@ -40,24 +41,35 @@ class TypeAliasDescriptorImpl(
TypeAliasDescriptor {
// TODO kotlinize some interfaces
- private lateinit var fDeclaredTypeParameters: List
- private lateinit var lazyUnderlyingType: NotNullLazyValue
+ private lateinit var declaredTypeParametersImpl: List
+ private lateinit var underlyingTypeImpl: NotNullLazyValue
+ private lateinit var expandedTypeImpl: NotNullLazyValue
- override val underlyingType: KotlinType get() = lazyUnderlyingType()
+ override val underlyingType: KotlinType get() = underlyingTypeImpl()
+ override val expandedType: KotlinType get() = expandedTypeImpl()
- fun initialize(declaredTypeParameters: List, lazyUnderlyingType: NotNullLazyValue) {
- this.fDeclaredTypeParameters = declaredTypeParameters
- this.lazyUnderlyingType = lazyUnderlyingType
+ fun initialize(
+ declaredTypeParameters: List,
+ lazyUnderlyingType: NotNullLazyValue,
+ lazyExpandedType: NotNullLazyValue
+ ) {
+ this.declaredTypeParametersImpl = declaredTypeParameters
+ this.underlyingTypeImpl = lazyUnderlyingType
+ this.expandedTypeImpl = lazyExpandedType
}
override fun accept(visitor: DeclarationDescriptorVisitor, data: D): R =
visitor.visitTypeAliasDescriptor(this, data)
- override fun getDeclaredTypeParameters(): List =
- fDeclaredTypeParameters
+ override fun isInner(): Boolean = false // TODO treat all nested type aliases as inner?
- override val underlyingClassDescriptor: ClassDescriptor
- get() = underlyingType.constructor.declarationDescriptor as ClassDescriptor // TODO
+ override fun getDeclaredTypeParameters(): List =
+ declaredTypeParametersImpl
+
+ override val classDescriptor: ClassDescriptor?
+ get() = expandedType.let { expandedType ->
+ if (expandedType.isError) null else expandedType.constructor.declarationDescriptor as ClassDescriptor
+ }
override fun getModality() = Modality.FINAL
diff --git a/compiler/serialization/src/org/jetbrains/kotlin/serialization/DescriptorSerializer.java b/compiler/serialization/src/org/jetbrains/kotlin/serialization/DescriptorSerializer.java
index c157c6365cf..c395a6ca43a 100644
--- a/compiler/serialization/src/org/jetbrains/kotlin/serialization/DescriptorSerializer.java
+++ b/compiler/serialization/src/org/jetbrains/kotlin/serialization/DescriptorSerializer.java
@@ -135,7 +135,7 @@ public class DescriptorSerializer {
builder.setFlags(flags);
}
- builder.setFqName(getClassId(classDescriptor));
+ builder.setFqName(getClassifierId(classDescriptor));
for (TypeParameterDescriptor typeParameterDescriptor : classDescriptor.getDeclaredTypeParameters()) {
builder.addTypeParameter(typeParameter(typeParameterDescriptor));
@@ -357,6 +357,32 @@ public class DescriptorSerializer {
return builder;
}
+ @NotNull
+ public ProtoBuf.TypeAlias.Builder typeAliasProto(@NotNull TypeAliasDescriptor descriptor) {
+ ProtoBuf.TypeAlias.Builder builder = ProtoBuf.TypeAlias.newBuilder();
+
+ int flags = Flags.getTypeAliasFlags(hasAnnotations(descriptor), descriptor.getVisibility());
+ if (flags != builder.getFlags()) {
+ builder.setFlags(flags);
+ }
+
+ builder.setName(getSimpleNameIndex(descriptor.getName()));
+
+ for (TypeParameterDescriptor typeParameterDescriptor : descriptor.getDeclaredTypeParameters()) {
+ builder.addTypeParameter(typeParameter(typeParameterDescriptor));
+ }
+
+ KotlinType underlyingType = descriptor.getUnderlyingType();
+ if (useTypeTable()) {
+ builder.setUnderlyingTypeId(typeId(underlyingType));
+ }
+ else {
+ builder.setUnderlyingType(type(underlyingType));
+ }
+
+ return builder;
+ }
+
@NotNull
public ProtoBuf.EnumEntry.Builder enumEntryProto(@NotNull ClassDescriptor descriptor) {
ProtoBuf.EnumEntry.Builder builder = ProtoBuf.EnumEntry.newBuilder();
@@ -499,6 +525,11 @@ public class DescriptorSerializer {
assert type.getArguments().isEmpty() : "Found arguments for type constructor build on type parameter: " + descriptor;
}
+ if (descriptor instanceof TypeAliasDescriptor) {
+ PossiblyInnerType possiblyInnerType = TypeParameterUtilsKt.buildPossiblyInnerType(type);
+ assert possiblyInnerType != null : "possiblyInnerType should not be null in case of type alias";
+ fillFromPossiblyInnerType(builder, possiblyInnerType);
+ }
if (type.isMarkedNullable() != builder.getNullable()) {
builder.setNullable(type.isMarkedNullable());
@@ -513,7 +544,14 @@ public class DescriptorSerializer {
@NotNull ProtoBuf.Type.Builder builder,
@NotNull PossiblyInnerType type
) {
- builder.setClassName(getClassId(type.getClassDescriptor()));
+ ClassifierDescriptorWithTypeParameters classifierDescriptor = type.getClassifierDescriptor();
+ int classifierId = getClassifierId(classifierDescriptor);
+ if (classifierDescriptor instanceof ClassDescriptor) {
+ builder.setClassName(classifierId);
+ }
+ else {
+ builder.setTypeAliasName(classifierId);
+ }
for (TypeProjection projection : type.getArguments()) {
builder.addArgument(typeArgument(projection));
@@ -606,6 +644,9 @@ public class DescriptorSerializer {
else if (declaration instanceof FunctionDescriptor) {
builder.addFunction(functionProto((FunctionDescriptor) declaration));
}
+ else if (declaration instanceof TypeAliasDescriptor) {
+ builder.addTypeAlias(typeAliasProto((TypeAliasDescriptor) declaration));
+ }
}
ProtoBuf.TypeTable typeTableProto = typeTable.serialize();
@@ -631,7 +672,7 @@ public class DescriptorSerializer {
throw new IllegalStateException("Unknown projectionKind: " + projectionKind);
}
- private int getClassId(@NotNull ClassDescriptor descriptor) {
+ private int getClassifierId(@NotNull ClassifierDescriptorWithTypeParameters descriptor) {
return getStringTable().getFqNameIndex(descriptor);
}
diff --git a/compiler/serialization/src/org/jetbrains/kotlin/serialization/StringTable.java b/compiler/serialization/src/org/jetbrains/kotlin/serialization/StringTable.java
index 03f6cc4d442..4aad209f38a 100644
--- a/compiler/serialization/src/org/jetbrains/kotlin/serialization/StringTable.java
+++ b/compiler/serialization/src/org/jetbrains/kotlin/serialization/StringTable.java
@@ -18,13 +18,14 @@ package org.jetbrains.kotlin.serialization;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.kotlin.descriptors.ClassDescriptor;
+import org.jetbrains.kotlin.descriptors.ClassifierDescriptorWithTypeParameters;
import java.io.OutputStream;
public interface StringTable {
int getStringIndex(@NotNull String string);
- int getFqNameIndex(@NotNull ClassDescriptor descriptor);
+ int getFqNameIndex(@NotNull ClassifierDescriptorWithTypeParameters descriptor);
void serializeTo(@NotNull OutputStream output);
}
diff --git a/compiler/serialization/src/org/jetbrains/kotlin/serialization/StringTableImpl.java b/compiler/serialization/src/org/jetbrains/kotlin/serialization/StringTableImpl.java
index 30c8496e04b..80d1ab81142 100644
--- a/compiler/serialization/src/org/jetbrains/kotlin/serialization/StringTableImpl.java
+++ b/compiler/serialization/src/org/jetbrains/kotlin/serialization/StringTableImpl.java
@@ -19,6 +19,7 @@ package org.jetbrains.kotlin.serialization;
import kotlin.Pair;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.kotlin.descriptors.ClassDescriptor;
+import org.jetbrains.kotlin.descriptors.ClassifierDescriptorWithTypeParameters;
import org.jetbrains.kotlin.descriptors.DeclarationDescriptor;
import org.jetbrains.kotlin.descriptors.PackageFragmentDescriptor;
import org.jetbrains.kotlin.name.FqName;
@@ -73,7 +74,7 @@ public class StringTableImpl implements StringTable {
}
@Override
- public int getFqNameIndex(@NotNull ClassDescriptor descriptor) {
+ public int getFqNameIndex(@NotNull ClassifierDescriptorWithTypeParameters descriptor) {
if (ErrorUtils.isError(descriptor)) {
throw new IllegalStateException("Cannot get FQ name of error class: " + descriptor);
}
diff --git a/compiler/testData/diagnostics/tests/typealias/parameterRestrictions.txt b/compiler/testData/diagnostics/tests/typealias/parameterRestrictions.txt
index 43a814e1fbd..792f31eb984 100644
--- a/compiler/testData/diagnostics/tests/typealias/parameterRestrictions.txt
+++ b/compiler/testData/diagnostics/tests/typealias/parameterRestrictions.txt
@@ -1,6 +1,6 @@
package
-public val x: WithVariance [= kotlin.Int] = 0
public typealias WithBounds1*0*/ T : [ERROR : Cyclic upper bounds]> = kotlin.Int
public typealias WithBounds2*0*/ X : [ERROR : Cyclic upper bounds], /*1*/ Y : [ERROR : Cyclic upper bounds]> = kotlin.Int
public typealias WithVariance*0*/ in X, /*1*/ out Y> = kotlin.Int
+public val x: WithVariance [= kotlin.Int] = 0
diff --git a/compiler/testData/diagnostics/tests/typealias/parameterSubstitution.txt b/compiler/testData/diagnostics/tests/typealias/parameterSubstitution.txt
index 5ff4bff9708..a81d18d4dd5 100644
--- a/compiler/testData/diagnostics/tests/typealias/parameterSubstitution.txt
+++ b/compiler/testData/diagnostics/tests/typealias/parameterSubstitution.txt
@@ -1,5 +1,6 @@
package
+public typealias CA*0*/ T> = C
public val ca1: CA [= C]
public val ca2: CA [= C]> [= C [= C]>]
public val ca3: CA> [= C>]
@@ -11,4 +12,3 @@ public final class C*0*/ T> {
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
-public typealias CA*0*/ T> = C
diff --git a/compiler/testData/diagnostics/tests/typealias/recursive.txt b/compiler/testData/diagnostics/tests/typealias/recursive.txt
index 09be8069705..f2d84f0bba0 100644
--- a/compiler/testData/diagnostics/tests/typealias/recursive.txt
+++ b/compiler/testData/diagnostics/tests/typealias/recursive.txt
@@ -1,5 +1,5 @@
package
-public val x: [ERROR : Recursive type alias: A]
public typealias A = B
public typealias B = A
+public val x: [ERROR : Recursive type alias: A]
diff --git a/compiler/testData/diagnostics/tests/typealias/simpleTypeAlias.txt b/compiler/testData/diagnostics/tests/typealias/simpleTypeAlias.txt
index ad97eb6a586..cd3162bf06d 100644
--- a/compiler/testData/diagnostics/tests/typealias/simpleTypeAlias.txt
+++ b/compiler/testData/diagnostics/tests/typealias/simpleTypeAlias.txt
@@ -1,9 +1,9 @@
package
+public typealias S = kotlin.String
+public typealias SS = S
+public typealias SSS = SS
public val s1: SSS [= kotlin.String] = ""
public val s2: SSS [= kotlin.String?] = null
public val s3: kotlin.collections.List? = null
public val s4: kotlin.collections.List?>? = null
-public typealias S = kotlin.String
-public typealias SS = S
-public typealias SSS = SS
diff --git a/compiler/testData/diagnostics/tests/typealias/substitutionVariance.txt b/compiler/testData/diagnostics/tests/typealias/substitutionVariance.txt
index e4706f06e54..796c4208c50 100644
--- a/compiler/testData/diagnostics/tests/typealias/substitutionVariance.txt
+++ b/compiler/testData/diagnostics/tests/typealias/substitutionVariance.txt
@@ -1,5 +1,17 @@
package
+public typealias In1*0*/ T> = In
+public typealias In2*0*/ T> = In
+public typealias In3*0*/ T> = In
+public typealias In4*0*/ T> = In<*>
+public typealias Inv1*0*/ T> = Inv
+public typealias Inv2*0*/ T> = Inv
+public typealias Inv3*0*/ T> = Inv
+public typealias Inv4*0*/ T> = Inv<*>
+public typealias Out1*0*/ T> = Out
+public typealias Out2*0*/ T> = Out
+public typealias Out3*0*/ T> = Out
+public typealias Out4*0*/ T> = Out<*>
public val inv1: Inv1 [= Inv]
public final class In*0*/ in T> {
@@ -22,15 +34,3 @@ public final class Out*0*/ out T> {
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
-public typealias In1*0*/ T> = In
-public typealias In2*0*/ T> = In
-public typealias In3*0*/ T> = In
-public typealias In4*0*/ T> = In<*>
-public typealias Inv1*0*/ T> = Inv
-public typealias Inv2*0*/ T> = Inv
-public typealias Inv3*0*/ T> = Inv
-public typealias Inv4*0*/ T> = Inv<*>
-public typealias Out1*0*/ T> = Out
-public typealias Out2*0*/ T> = Out
-public typealias Out3*0*/ T> = Out
-public typealias Out4*0*/ T> = Out<*>
diff --git a/core/descriptors/src/org/jetbrains/kotlin/descriptors/ClassDescriptor.java b/core/descriptors/src/org/jetbrains/kotlin/descriptors/ClassDescriptor.java
index 73cbd8b283a..101af1b3661 100644
--- a/core/descriptors/src/org/jetbrains/kotlin/descriptors/ClassDescriptor.java
+++ b/core/descriptors/src/org/jetbrains/kotlin/descriptors/ClassDescriptor.java
@@ -80,11 +80,6 @@ public interface ClassDescriptor extends ClassifierDescriptorWithTypeParameters,
@NotNull
Visibility getVisibility();
- /**
- * @return true if this class contains a reference to its outer class (as opposed to static nested class)
- */
- boolean isInner();
-
boolean isCompanionObject();
boolean isData();
diff --git a/core/descriptors/src/org/jetbrains/kotlin/descriptors/ClassifierDescriptorWithTypeParameters.java b/core/descriptors/src/org/jetbrains/kotlin/descriptors/ClassifierDescriptorWithTypeParameters.java
index 9ad47fb57f4..f3c98dcf31e 100644
--- a/core/descriptors/src/org/jetbrains/kotlin/descriptors/ClassifierDescriptorWithTypeParameters.java
+++ b/core/descriptors/src/org/jetbrains/kotlin/descriptors/ClassifierDescriptorWithTypeParameters.java
@@ -22,6 +22,11 @@ import org.jetbrains.annotations.ReadOnly;
import java.util.List;
public interface ClassifierDescriptorWithTypeParameters extends ClassifierDescriptor {
+ /**
+ * @return true if this class contains a reference to its outer class (as opposed to static nested class)
+ */
+ boolean isInner();
+
@ReadOnly
@NotNull
List getDeclaredTypeParameters();
diff --git a/core/descriptors/src/org/jetbrains/kotlin/descriptors/TypeAliasDescriptor.kt b/core/descriptors/src/org/jetbrains/kotlin/descriptors/TypeAliasDescriptor.kt
index e36b6d08eb0..ffe27c0aa38 100644
--- a/core/descriptors/src/org/jetbrains/kotlin/descriptors/TypeAliasDescriptor.kt
+++ b/core/descriptors/src/org/jetbrains/kotlin/descriptors/TypeAliasDescriptor.kt
@@ -22,7 +22,9 @@ import org.jetbrains.kotlin.types.TypeSubstitutor
interface TypeAliasDescriptor : ClassifierDescriptorWithTypeParameters, MemberDescriptor {
val underlyingType: KotlinType
- val underlyingClassDescriptor: ClassDescriptor
+ val expandedType: KotlinType
+
+ val classDescriptor: ClassDescriptor?
override fun substitute(substitutor: TypeSubstitutor): TypeAliasDescriptor
}
diff --git a/core/descriptors/src/org/jetbrains/kotlin/descriptors/typeParameterUtils.kt b/core/descriptors/src/org/jetbrains/kotlin/descriptors/typeParameterUtils.kt
index 3ff3d598894..6022ece68ae 100644
--- a/core/descriptors/src/org/jetbrains/kotlin/descriptors/typeParameterUtils.kt
+++ b/core/descriptors/src/org/jetbrains/kotlin/descriptors/typeParameterUtils.kt
@@ -60,17 +60,21 @@ private class CapturedTypeParameterDescriptor(
}
class PossiblyInnerType(
- val classDescriptor: ClassDescriptor,
+ val classifierDescriptor: ClassifierDescriptorWithTypeParameters,
val arguments: List,
- val outerType: PossiblyInnerType?) {
+ val outerType: PossiblyInnerType?
+) {
+ val classDescriptor: ClassDescriptor
+ get() = classifierDescriptor as ClassDescriptor
+
fun segments(): List = outerType?.segments().orEmpty() + this
}
fun KotlinType.buildPossiblyInnerType(): PossiblyInnerType? {
- return buildPossiblyInnerType(constructor.declarationDescriptor as? ClassDescriptor, 0)
+ return buildPossiblyInnerType(constructor.declarationDescriptor as? ClassifierDescriptorWithTypeParameters, 0)
}
-private fun KotlinType.buildPossiblyInnerType(classDescriptor: ClassDescriptor?, index: Int): PossiblyInnerType? {
+private fun KotlinType.buildPossiblyInnerType(classDescriptor: ClassifierDescriptorWithTypeParameters?, index: Int): PossiblyInnerType? {
if (classDescriptor == null || ErrorUtils.isError(classDescriptor)) return null
val toIndex = classDescriptor.declaredTypeParameters.size + index
@@ -85,5 +89,5 @@ private fun KotlinType.buildPossiblyInnerType(classDescriptor: ClassDescriptor?,
val argumentsSubList = arguments.subList(index, toIndex)
return PossiblyInnerType(
classDescriptor, argumentsSubList,
- buildPossiblyInnerType(classDescriptor.containingDeclaration as? ClassDescriptor, toIndex))
+ buildPossiblyInnerType(classDescriptor.containingDeclaration as? ClassifierDescriptorWithTypeParameters, toIndex))
}
diff --git a/core/descriptors/src/org/jetbrains/kotlin/renderer/DescriptorRendererImpl.kt b/core/descriptors/src/org/jetbrains/kotlin/renderer/DescriptorRendererImpl.kt
index 3472a3e9d57..8b732e5e2aa 100644
--- a/core/descriptors/src/org/jetbrains/kotlin/renderer/DescriptorRendererImpl.kt
+++ b/core/descriptors/src/org/jetbrains/kotlin/renderer/DescriptorRendererImpl.kt
@@ -273,8 +273,8 @@ internal class DescriptorRendererImpl(
possiblyInnerType.outerType?.let {
append(renderPossiblyInnerType(it))
append('.')
- append(renderName(possiblyInnerType.classDescriptor.name))
- } ?: append(renderTypeConstructor(possiblyInnerType.classDescriptor.typeConstructor))
+ append(renderName(possiblyInnerType.classifierDescriptor.name))
+ } ?: append(renderTypeConstructor(possiblyInnerType.classifierDescriptor.typeConstructor))
append(renderTypeArguments(possiblyInnerType.arguments))
}
diff --git a/core/descriptors/src/org/jetbrains/kotlin/resolve/MemberComparator.java b/core/descriptors/src/org/jetbrains/kotlin/resolve/MemberComparator.java
index f85ca02c524..bd68b271a14 100644
--- a/core/descriptors/src/org/jetbrains/kotlin/resolve/MemberComparator.java
+++ b/core/descriptors/src/org/jetbrains/kotlin/resolve/MemberComparator.java
@@ -48,7 +48,10 @@ public class MemberComparator implements Comparator {
}
private static int getDeclarationPriority(DeclarationDescriptor descriptor) {
- if (isEnumEntry(descriptor)) {
+ if (descriptor instanceof TypeAliasDescriptor) {
+ return 8;
+ }
+ else if (isEnumEntry(descriptor)) {
return 7;
}
else if (descriptor instanceof ConstructorDescriptor) {
@@ -92,7 +95,17 @@ public class MemberComparator implements Comparator {
return namesCompareTo;
}
- if (o1 instanceof CallableDescriptor && o2 instanceof CallableDescriptor) {
+ if (o1 instanceof TypeAliasDescriptor && o2 instanceof TypeAliasDescriptor) {
+ TypeAliasDescriptor ta1 = (TypeAliasDescriptor) o1;
+ TypeAliasDescriptor ta2 = (TypeAliasDescriptor) o2;
+ String r1 = RENDERER.renderType(ta1.getUnderlyingType());
+ String r2 = RENDERER.renderType(ta2.getUnderlyingType());
+ int underlyingTypesCompareTo = r1.compareTo(r2);
+ if (underlyingTypesCompareTo != 0) {
+ return underlyingTypesCompareTo;
+ }
+ }
+ else if (o1 instanceof CallableDescriptor && o2 instanceof CallableDescriptor) {
CallableDescriptor c1 = (CallableDescriptor) o1;
CallableDescriptor c2 = (CallableDescriptor) o2;
diff --git a/core/deserialization/src/descriptors.proto b/core/deserialization/src/descriptors.proto
index 0b826ea8110..c50c86e3230 100644
--- a/core/deserialization/src/descriptors.proto
+++ b/core/deserialization/src/descriptors.proto
@@ -128,10 +128,14 @@ message Type {
optional int32 type_parameter = 7; // id of the type parameter
// Name of the type parameter in the immediate owner
optional int32 type_parameter_name = 9 [(name_id_in_table) = true];
+ optional int32 type_alias_name = 12 [(name_id_in_table) = true];
optional Type outer_type = 10;
optional int32 outer_type_id = 11;
+ optional Type abbreviated_type = 13;
+ optional int32 abbreviated_type_id = 14;
+
extensions 100 to 199;
}
@@ -191,6 +195,7 @@ message Class {
repeated Constructor constructor = 8;
repeated Function function = 9;
repeated Property property = 10;
+ repeated TypeAlias type_alias = 11;
repeated EnumEntry enum_entry = 13;
@@ -202,6 +207,7 @@ message Class {
message Package {
repeated Function function = 3;
repeated Property property = 4;
+ repeated TypeAlias type_alias = 5;
optional TypeTable type_table = 30;
@@ -322,6 +328,26 @@ message ValueParameter {
extensions 100 to 199;
}
+message TypeAlias {
+ /*
+ hasAnnotations
+ Visibility
+ */
+ optional int32 flags = 1 [default = 0];
+
+ required int32 name = 2 [(name_id_in_table) = true];
+
+ repeated TypeParameter type_parameter = 3;
+
+ optional Type underlying_type = 4;
+ optional int32 underlying_type_id = 5;
+
+ optional Type expanded_type = 6;
+ optional int32 expanded_type_id = 7;
+
+ extensions 100 to 199;
+}
+
message EnumEntry {
optional int32 name = 1 [(name_id_in_table) = true];
diff --git a/core/deserialization/src/org/jetbrains/kotlin/serialization/Flags.java b/core/deserialization/src/org/jetbrains/kotlin/serialization/Flags.java
index 3c229298700..5b754b50064 100644
--- a/core/deserialization/src/org/jetbrains/kotlin/serialization/Flags.java
+++ b/core/deserialization/src/org/jetbrains/kotlin/serialization/Flags.java
@@ -252,6 +252,12 @@ public class Flags {
;
}
+ public static int getTypeAliasFlags(boolean hasAnnotations, Visibility visibility) {
+ return HAS_ANNOTATIONS.toFlags(hasAnnotations)
+ | VISIBILITY.toFlags(visibility(visibility))
+ ;
+ }
+
// Infrastructure
public static abstract class FlagField {
diff --git a/core/deserialization/src/org/jetbrains/kotlin/serialization/ProtoBuf.java b/core/deserialization/src/org/jetbrains/kotlin/serialization/ProtoBuf.java
index 0dc867a480b..e9f5b7a5e15 100644
--- a/core/deserialization/src/org/jetbrains/kotlin/serialization/ProtoBuf.java
+++ b/core/deserialization/src/org/jetbrains/kotlin/serialization/ProtoBuf.java
@@ -4354,6 +4354,16 @@ public final class ProtoBuf {
*/
int getTypeParameterName();
+ // optional int32 type_alias_name = 12;
+ /**
+ * optional int32 type_alias_name = 12;
+ */
+ boolean hasTypeAliasName();
+ /**
+ * optional int32 type_alias_name = 12;
+ */
+ int getTypeAliasName();
+
// optional .org.jetbrains.kotlin.serialization.Type outer_type = 10;
/**
* optional .org.jetbrains.kotlin.serialization.Type outer_type = 10;
@@ -4373,6 +4383,26 @@ public final class ProtoBuf {
* optional int32 outer_type_id = 11;
*/
int getOuterTypeId();
+
+ // optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ */
+ boolean hasAbbreviatedType();
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ */
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type getAbbreviatedType();
+
+ // optional int32 abbreviated_type_id = 14;
+ /**
+ * optional int32 abbreviated_type_id = 14;
+ */
+ boolean hasAbbreviatedTypeId();
+ /**
+ * optional int32 abbreviated_type_id = 14;
+ */
+ int getAbbreviatedTypeId();
}
/**
* Protobuf type {@code org.jetbrains.kotlin.serialization.Type}
@@ -4470,7 +4500,7 @@ public final class ProtoBuf {
}
case 82: {
org.jetbrains.kotlin.serialization.ProtoBuf.Type.Builder subBuilder = null;
- if (((bitField0_ & 0x00000080) == 0x00000080)) {
+ if (((bitField0_ & 0x00000100) == 0x00000100)) {
subBuilder = outerType_.toBuilder();
}
outerType_ = input.readMessage(org.jetbrains.kotlin.serialization.ProtoBuf.Type.PARSER, extensionRegistry);
@@ -4478,14 +4508,37 @@ public final class ProtoBuf {
subBuilder.mergeFrom(outerType_);
outerType_ = subBuilder.buildPartial();
}
- bitField0_ |= 0x00000080;
+ bitField0_ |= 0x00000100;
break;
}
case 88: {
- bitField0_ |= 0x00000100;
+ bitField0_ |= 0x00000200;
outerTypeId_ = input.readInt32();
break;
}
+ case 96: {
+ bitField0_ |= 0x00000080;
+ typeAliasName_ = input.readInt32();
+ break;
+ }
+ case 106: {
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type.Builder subBuilder = null;
+ if (((bitField0_ & 0x00000400) == 0x00000400)) {
+ subBuilder = abbreviatedType_.toBuilder();
+ }
+ abbreviatedType_ = input.readMessage(org.jetbrains.kotlin.serialization.ProtoBuf.Type.PARSER, extensionRegistry);
+ if (subBuilder != null) {
+ subBuilder.mergeFrom(abbreviatedType_);
+ abbreviatedType_ = subBuilder.buildPartial();
+ }
+ bitField0_ |= 0x00000400;
+ break;
+ }
+ case 112: {
+ bitField0_ |= 0x00000800;
+ abbreviatedTypeId_ = input.readInt32();
+ break;
+ }
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
@@ -5354,6 +5407,22 @@ public final class ProtoBuf {
return typeParameterName_;
}
+ // optional int32 type_alias_name = 12;
+ public static final int TYPE_ALIAS_NAME_FIELD_NUMBER = 12;
+ private int typeAliasName_;
+ /**
+ * optional int32 type_alias_name = 12;
+ */
+ public boolean hasTypeAliasName() {
+ return ((bitField0_ & 0x00000080) == 0x00000080);
+ }
+ /**
+ * optional int32 type_alias_name = 12;
+ */
+ public int getTypeAliasName() {
+ return typeAliasName_;
+ }
+
// optional .org.jetbrains.kotlin.serialization.Type outer_type = 10;
public static final int OUTER_TYPE_FIELD_NUMBER = 10;
private org.jetbrains.kotlin.serialization.ProtoBuf.Type outerType_;
@@ -5361,7 +5430,7 @@ public final class ProtoBuf {
* optional .org.jetbrains.kotlin.serialization.Type outer_type = 10;
*/
public boolean hasOuterType() {
- return ((bitField0_ & 0x00000080) == 0x00000080);
+ return ((bitField0_ & 0x00000100) == 0x00000100);
}
/**
* optional .org.jetbrains.kotlin.serialization.Type outer_type = 10;
@@ -5377,7 +5446,7 @@ public final class ProtoBuf {
* optional int32 outer_type_id = 11;
*/
public boolean hasOuterTypeId() {
- return ((bitField0_ & 0x00000100) == 0x00000100);
+ return ((bitField0_ & 0x00000200) == 0x00000200);
}
/**
* optional int32 outer_type_id = 11;
@@ -5386,6 +5455,38 @@ public final class ProtoBuf {
return outerTypeId_;
}
+ // optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ public static final int ABBREVIATED_TYPE_FIELD_NUMBER = 13;
+ private org.jetbrains.kotlin.serialization.ProtoBuf.Type abbreviatedType_;
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ */
+ public boolean hasAbbreviatedType() {
+ return ((bitField0_ & 0x00000400) == 0x00000400);
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.Type getAbbreviatedType() {
+ return abbreviatedType_;
+ }
+
+ // optional int32 abbreviated_type_id = 14;
+ public static final int ABBREVIATED_TYPE_ID_FIELD_NUMBER = 14;
+ private int abbreviatedTypeId_;
+ /**
+ * optional int32 abbreviated_type_id = 14;
+ */
+ public boolean hasAbbreviatedTypeId() {
+ return ((bitField0_ & 0x00000800) == 0x00000800);
+ }
+ /**
+ * optional int32 abbreviated_type_id = 14;
+ */
+ public int getAbbreviatedTypeId() {
+ return abbreviatedTypeId_;
+ }
+
private void initFields() {
argument_ = java.util.Collections.emptyList();
nullable_ = false;
@@ -5395,8 +5496,11 @@ public final class ProtoBuf {
className_ = 0;
typeParameter_ = 0;
typeParameterName_ = 0;
+ typeAliasName_ = 0;
outerType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
outerTypeId_ = 0;
+ abbreviatedType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+ abbreviatedTypeId_ = 0;
}
private byte memoizedIsInitialized = -1;
public final boolean isInitialized() {
@@ -5421,6 +5525,12 @@ public final class ProtoBuf {
return false;
}
}
+ if (hasAbbreviatedType()) {
+ if (!getAbbreviatedType().isInitialized()) {
+ memoizedIsInitialized = 0;
+ return false;
+ }
+ }
if (!extensionsAreInitialized()) {
memoizedIsInitialized = 0;
return false;
@@ -5459,12 +5569,21 @@ public final class ProtoBuf {
if (((bitField0_ & 0x00000040) == 0x00000040)) {
output.writeInt32(9, typeParameterName_);
}
- if (((bitField0_ & 0x00000080) == 0x00000080)) {
+ if (((bitField0_ & 0x00000100) == 0x00000100)) {
output.writeMessage(10, outerType_);
}
- if (((bitField0_ & 0x00000100) == 0x00000100)) {
+ if (((bitField0_ & 0x00000200) == 0x00000200)) {
output.writeInt32(11, outerTypeId_);
}
+ if (((bitField0_ & 0x00000080) == 0x00000080)) {
+ output.writeInt32(12, typeAliasName_);
+ }
+ if (((bitField0_ & 0x00000400) == 0x00000400)) {
+ output.writeMessage(13, abbreviatedType_);
+ }
+ if (((bitField0_ & 0x00000800) == 0x00000800)) {
+ output.writeInt32(14, abbreviatedTypeId_);
+ }
extensionWriter.writeUntil(200, output);
}
@@ -5506,14 +5625,26 @@ public final class ProtoBuf {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(9, typeParameterName_);
}
- if (((bitField0_ & 0x00000080) == 0x00000080)) {
+ if (((bitField0_ & 0x00000100) == 0x00000100)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(10, outerType_);
}
- if (((bitField0_ & 0x00000100) == 0x00000100)) {
+ if (((bitField0_ & 0x00000200) == 0x00000200)) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(11, outerTypeId_);
}
+ if (((bitField0_ & 0x00000080) == 0x00000080)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeInt32Size(12, typeAliasName_);
+ }
+ if (((bitField0_ & 0x00000400) == 0x00000400)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(13, abbreviatedType_);
+ }
+ if (((bitField0_ & 0x00000800) == 0x00000800)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeInt32Size(14, abbreviatedTypeId_);
+ }
size += extensionsSerializedSize();
memoizedSerializedSize = size;
return size;
@@ -5621,10 +5752,16 @@ public final class ProtoBuf {
bitField0_ = (bitField0_ & ~0x00000040);
typeParameterName_ = 0;
bitField0_ = (bitField0_ & ~0x00000080);
- outerType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+ typeAliasName_ = 0;
bitField0_ = (bitField0_ & ~0x00000100);
- outerTypeId_ = 0;
+ outerType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
bitField0_ = (bitField0_ & ~0x00000200);
+ outerTypeId_ = 0;
+ bitField0_ = (bitField0_ & ~0x00000400);
+ abbreviatedType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+ bitField0_ = (bitField0_ & ~0x00000800);
+ abbreviatedTypeId_ = 0;
+ bitField0_ = (bitField0_ & ~0x00001000);
return this;
}
@@ -5684,11 +5821,23 @@ public final class ProtoBuf {
if (((from_bitField0_ & 0x00000100) == 0x00000100)) {
to_bitField0_ |= 0x00000080;
}
- result.outerType_ = outerType_;
+ result.typeAliasName_ = typeAliasName_;
if (((from_bitField0_ & 0x00000200) == 0x00000200)) {
to_bitField0_ |= 0x00000100;
}
+ result.outerType_ = outerType_;
+ if (((from_bitField0_ & 0x00000400) == 0x00000400)) {
+ to_bitField0_ |= 0x00000200;
+ }
result.outerTypeId_ = outerTypeId_;
+ if (((from_bitField0_ & 0x00000800) == 0x00000800)) {
+ to_bitField0_ |= 0x00000400;
+ }
+ result.abbreviatedType_ = abbreviatedType_;
+ if (((from_bitField0_ & 0x00001000) == 0x00001000)) {
+ to_bitField0_ |= 0x00000800;
+ }
+ result.abbreviatedTypeId_ = abbreviatedTypeId_;
result.bitField0_ = to_bitField0_;
return result;
}
@@ -5726,12 +5875,21 @@ public final class ProtoBuf {
if (other.hasTypeParameterName()) {
setTypeParameterName(other.getTypeParameterName());
}
+ if (other.hasTypeAliasName()) {
+ setTypeAliasName(other.getTypeAliasName());
+ }
if (other.hasOuterType()) {
mergeOuterType(other.getOuterType());
}
if (other.hasOuterTypeId()) {
setOuterTypeId(other.getOuterTypeId());
}
+ if (other.hasAbbreviatedType()) {
+ mergeAbbreviatedType(other.getAbbreviatedType());
+ }
+ if (other.hasAbbreviatedTypeId()) {
+ setAbbreviatedTypeId(other.getAbbreviatedTypeId());
+ }
this.mergeExtensionFields(other);
return this;
}
@@ -5755,6 +5913,12 @@ public final class ProtoBuf {
return false;
}
}
+ if (hasAbbreviatedType()) {
+ if (!getAbbreviatedType().isInitialized()) {
+
+ return false;
+ }
+ }
if (!extensionsAreInitialized()) {
return false;
@@ -6217,13 +6381,46 @@ public final class ProtoBuf {
return this;
}
+ // optional int32 type_alias_name = 12;
+ private int typeAliasName_ ;
+ /**
+ * optional int32 type_alias_name = 12;
+ */
+ public boolean hasTypeAliasName() {
+ return ((bitField0_ & 0x00000100) == 0x00000100);
+ }
+ /**
+ * optional int32 type_alias_name = 12;
+ */
+ public int getTypeAliasName() {
+ return typeAliasName_;
+ }
+ /**
+ * optional int32 type_alias_name = 12;
+ */
+ public Builder setTypeAliasName(int value) {
+ bitField0_ |= 0x00000100;
+ typeAliasName_ = value;
+
+ return this;
+ }
+ /**
+ * optional int32 type_alias_name = 12;
+ */
+ public Builder clearTypeAliasName() {
+ bitField0_ = (bitField0_ & ~0x00000100);
+ typeAliasName_ = 0;
+
+ return this;
+ }
+
// optional .org.jetbrains.kotlin.serialization.Type outer_type = 10;
private org.jetbrains.kotlin.serialization.ProtoBuf.Type outerType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
/**
* optional .org.jetbrains.kotlin.serialization.Type outer_type = 10;
*/
public boolean hasOuterType() {
- return ((bitField0_ & 0x00000100) == 0x00000100);
+ return ((bitField0_ & 0x00000200) == 0x00000200);
}
/**
* optional .org.jetbrains.kotlin.serialization.Type outer_type = 10;
@@ -6240,7 +6437,7 @@ public final class ProtoBuf {
}
outerType_ = value;
- bitField0_ |= 0x00000100;
+ bitField0_ |= 0x00000200;
return this;
}
/**
@@ -6250,14 +6447,14 @@ public final class ProtoBuf {
org.jetbrains.kotlin.serialization.ProtoBuf.Type.Builder builderForValue) {
outerType_ = builderForValue.build();
- bitField0_ |= 0x00000100;
+ bitField0_ |= 0x00000200;
return this;
}
/**
* optional .org.jetbrains.kotlin.serialization.Type outer_type = 10;
*/
public Builder mergeOuterType(org.jetbrains.kotlin.serialization.ProtoBuf.Type value) {
- if (((bitField0_ & 0x00000100) == 0x00000100) &&
+ if (((bitField0_ & 0x00000200) == 0x00000200) &&
outerType_ != org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance()) {
outerType_ =
org.jetbrains.kotlin.serialization.ProtoBuf.Type.newBuilder(outerType_).mergeFrom(value).buildPartial();
@@ -6265,7 +6462,7 @@ public final class ProtoBuf {
outerType_ = value;
}
- bitField0_ |= 0x00000100;
+ bitField0_ |= 0x00000200;
return this;
}
/**
@@ -6274,7 +6471,7 @@ public final class ProtoBuf {
public Builder clearOuterType() {
outerType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
- bitField0_ = (bitField0_ & ~0x00000100);
+ bitField0_ = (bitField0_ & ~0x00000200);
return this;
}
@@ -6284,7 +6481,7 @@ public final class ProtoBuf {
* optional int32 outer_type_id = 11;
*/
public boolean hasOuterTypeId() {
- return ((bitField0_ & 0x00000200) == 0x00000200);
+ return ((bitField0_ & 0x00000400) == 0x00000400);
}
/**
* optional int32 outer_type_id = 11;
@@ -6296,7 +6493,7 @@ public final class ProtoBuf {
* optional int32 outer_type_id = 11;
*/
public Builder setOuterTypeId(int value) {
- bitField0_ |= 0x00000200;
+ bitField0_ |= 0x00000400;
outerTypeId_ = value;
return this;
@@ -6305,12 +6502,106 @@ public final class ProtoBuf {
* optional int32 outer_type_id = 11;
*/
public Builder clearOuterTypeId() {
- bitField0_ = (bitField0_ & ~0x00000200);
+ bitField0_ = (bitField0_ & ~0x00000400);
outerTypeId_ = 0;
return this;
}
+ // optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ private org.jetbrains.kotlin.serialization.ProtoBuf.Type abbreviatedType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ */
+ public boolean hasAbbreviatedType() {
+ return ((bitField0_ & 0x00000800) == 0x00000800);
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.Type getAbbreviatedType() {
+ return abbreviatedType_;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ */
+ public Builder setAbbreviatedType(org.jetbrains.kotlin.serialization.ProtoBuf.Type value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ abbreviatedType_ = value;
+
+ bitField0_ |= 0x00000800;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ */
+ public Builder setAbbreviatedType(
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type.Builder builderForValue) {
+ abbreviatedType_ = builderForValue.build();
+
+ bitField0_ |= 0x00000800;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ */
+ public Builder mergeAbbreviatedType(org.jetbrains.kotlin.serialization.ProtoBuf.Type value) {
+ if (((bitField0_ & 0x00000800) == 0x00000800) &&
+ abbreviatedType_ != org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance()) {
+ abbreviatedType_ =
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type.newBuilder(abbreviatedType_).mergeFrom(value).buildPartial();
+ } else {
+ abbreviatedType_ = value;
+ }
+
+ bitField0_ |= 0x00000800;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type abbreviated_type = 13;
+ */
+ public Builder clearAbbreviatedType() {
+ abbreviatedType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+
+ bitField0_ = (bitField0_ & ~0x00000800);
+ return this;
+ }
+
+ // optional int32 abbreviated_type_id = 14;
+ private int abbreviatedTypeId_ ;
+ /**
+ * optional int32 abbreviated_type_id = 14;
+ */
+ public boolean hasAbbreviatedTypeId() {
+ return ((bitField0_ & 0x00001000) == 0x00001000);
+ }
+ /**
+ * optional int32 abbreviated_type_id = 14;
+ */
+ public int getAbbreviatedTypeId() {
+ return abbreviatedTypeId_;
+ }
+ /**
+ * optional int32 abbreviated_type_id = 14;
+ */
+ public Builder setAbbreviatedTypeId(int value) {
+ bitField0_ |= 0x00001000;
+ abbreviatedTypeId_ = value;
+
+ return this;
+ }
+ /**
+ * optional int32 abbreviated_type_id = 14;
+ */
+ public Builder clearAbbreviatedTypeId() {
+ bitField0_ = (bitField0_ & ~0x00001000);
+ abbreviatedTypeId_ = 0;
+
+ return this;
+ }
+
// @@protoc_insertion_point(builder_scope:org.jetbrains.kotlin.serialization.Type)
}
@@ -7538,6 +7829,21 @@ public final class ProtoBuf {
*/
int getPropertyCount();
+ // repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ java.util.List
+ getTypeAliasList();
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias getTypeAlias(int index);
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ int getTypeAliasCount();
+
// repeated .org.jetbrains.kotlin.serialization.EnumEntry enum_entry = 13;
/**
* repeated .org.jetbrains.kotlin.serialization.EnumEntry enum_entry = 13;
@@ -7703,11 +8009,19 @@ public final class ProtoBuf {
property_.add(input.readMessage(org.jetbrains.kotlin.serialization.ProtoBuf.Property.PARSER, extensionRegistry));
break;
}
- case 106: {
+ case 90: {
if (!((mutable_bitField0_ & 0x00000400) == 0x00000400)) {
- enumEntry_ = new java.util.ArrayList();
+ typeAlias_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000400;
}
+ typeAlias_.add(input.readMessage(org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.PARSER, extensionRegistry));
+ break;
+ }
+ case 106: {
+ if (!((mutable_bitField0_ & 0x00000800) == 0x00000800)) {
+ enumEntry_ = new java.util.ArrayList();
+ mutable_bitField0_ |= 0x00000800;
+ }
enumEntry_.add(input.readMessage(org.jetbrains.kotlin.serialization.ProtoBuf.EnumEntry.PARSER, extensionRegistry));
break;
}
@@ -7754,6 +8068,9 @@ public final class ProtoBuf {
property_ = java.util.Collections.unmodifiableList(property_);
}
if (((mutable_bitField0_ & 0x00000400) == 0x00000400)) {
+ typeAlias_ = java.util.Collections.unmodifiableList(typeAlias_);
+ }
+ if (((mutable_bitField0_ & 0x00000800) == 0x00000800)) {
enumEntry_ = java.util.Collections.unmodifiableList(enumEntry_);
}
makeExtensionsImmutable();
@@ -8180,6 +8497,42 @@ public final class ProtoBuf {
return property_.get(index);
}
+ // repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ public static final int TYPE_ALIAS_FIELD_NUMBER = 11;
+ private java.util.List typeAlias_;
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public java.util.List getTypeAliasList() {
+ return typeAlias_;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public java.util.List extends org.jetbrains.kotlin.serialization.ProtoBuf.TypeAliasOrBuilder>
+ getTypeAliasOrBuilderList() {
+ return typeAlias_;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public int getTypeAliasCount() {
+ return typeAlias_.size();
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias getTypeAlias(int index) {
+ return typeAlias_.get(index);
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeAliasOrBuilder getTypeAliasOrBuilder(
+ int index) {
+ return typeAlias_.get(index);
+ }
+
// repeated .org.jetbrains.kotlin.serialization.EnumEntry enum_entry = 13;
public static final int ENUM_ENTRY_FIELD_NUMBER = 13;
private java.util.List enumEntry_;
@@ -8243,6 +8596,7 @@ public final class ProtoBuf {
constructor_ = java.util.Collections.emptyList();
function_ = java.util.Collections.emptyList();
property_ = java.util.Collections.emptyList();
+ typeAlias_ = java.util.Collections.emptyList();
enumEntry_ = java.util.Collections.emptyList();
typeTable_ = org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance();
}
@@ -8285,6 +8639,12 @@ public final class ProtoBuf {
return false;
}
}
+ for (int i = 0; i < getTypeAliasCount(); i++) {
+ if (!getTypeAlias(i).isInitialized()) {
+ memoizedIsInitialized = 0;
+ return false;
+ }
+ }
for (int i = 0; i < getEnumEntryCount(); i++) {
if (!getEnumEntry(i).isInitialized()) {
memoizedIsInitialized = 0;
@@ -8349,6 +8709,9 @@ public final class ProtoBuf {
for (int i = 0; i < property_.size(); i++) {
output.writeMessage(10, property_.get(i));
}
+ for (int i = 0; i < typeAlias_.size(); i++) {
+ output.writeMessage(11, typeAlias_.get(i));
+ }
for (int i = 0; i < enumEntry_.size(); i++) {
output.writeMessage(13, enumEntry_.get(i));
}
@@ -8424,6 +8787,10 @@ public final class ProtoBuf {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(10, property_.get(i));
}
+ for (int i = 0; i < typeAlias_.size(); i++) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(11, typeAlias_.get(i));
+ }
for (int i = 0; i < enumEntry_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(13, enumEntry_.get(i));
@@ -8543,10 +8910,12 @@ public final class ProtoBuf {
bitField0_ = (bitField0_ & ~0x00000100);
property_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000200);
- enumEntry_ = java.util.Collections.emptyList();
+ typeAlias_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000400);
- typeTable_ = org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance();
+ enumEntry_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000800);
+ typeTable_ = org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance();
+ bitField0_ = (bitField0_ & ~0x00001000);
return this;
}
@@ -8618,11 +8987,16 @@ public final class ProtoBuf {
}
result.property_ = property_;
if (((bitField0_ & 0x00000400) == 0x00000400)) {
- enumEntry_ = java.util.Collections.unmodifiableList(enumEntry_);
+ typeAlias_ = java.util.Collections.unmodifiableList(typeAlias_);
bitField0_ = (bitField0_ & ~0x00000400);
}
+ result.typeAlias_ = typeAlias_;
+ if (((bitField0_ & 0x00000800) == 0x00000800)) {
+ enumEntry_ = java.util.Collections.unmodifiableList(enumEntry_);
+ bitField0_ = (bitField0_ & ~0x00000800);
+ }
result.enumEntry_ = enumEntry_;
- if (((from_bitField0_ & 0x00000800) == 0x00000800)) {
+ if (((from_bitField0_ & 0x00001000) == 0x00001000)) {
to_bitField0_ |= 0x00000008;
}
result.typeTable_ = typeTable_;
@@ -8710,11 +9084,21 @@ public final class ProtoBuf {
property_.addAll(other.property_);
}
+ }
+ if (!other.typeAlias_.isEmpty()) {
+ if (typeAlias_.isEmpty()) {
+ typeAlias_ = other.typeAlias_;
+ bitField0_ = (bitField0_ & ~0x00000400);
+ } else {
+ ensureTypeAliasIsMutable();
+ typeAlias_.addAll(other.typeAlias_);
+ }
+
}
if (!other.enumEntry_.isEmpty()) {
if (enumEntry_.isEmpty()) {
enumEntry_ = other.enumEntry_;
- bitField0_ = (bitField0_ & ~0x00000400);
+ bitField0_ = (bitField0_ & ~0x00000800);
} else {
ensureEnumEntryIsMutable();
enumEntry_.addAll(other.enumEntry_);
@@ -8763,6 +9147,12 @@ public final class ProtoBuf {
return false;
}
}
+ for (int i = 0; i < getTypeAliasCount(); i++) {
+ if (!getTypeAlias(i).isInitialized()) {
+
+ return false;
+ }
+ }
for (int i = 0; i < getEnumEntryCount(); i++) {
if (!getEnumEntry(i).isInitialized()) {
@@ -9697,13 +10087,138 @@ public final class ProtoBuf {
return this;
}
+ // repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ private java.util.List typeAlias_ =
+ java.util.Collections.emptyList();
+ private void ensureTypeAliasIsMutable() {
+ if (!((bitField0_ & 0x00000400) == 0x00000400)) {
+ typeAlias_ = new java.util.ArrayList(typeAlias_);
+ bitField0_ |= 0x00000400;
+ }
+ }
+
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public java.util.List getTypeAliasList() {
+ return java.util.Collections.unmodifiableList(typeAlias_);
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public int getTypeAliasCount() {
+ return typeAlias_.size();
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias getTypeAlias(int index) {
+ return typeAlias_.get(index);
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public Builder setTypeAlias(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeAliasIsMutable();
+ typeAlias_.set(index, value);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public Builder setTypeAlias(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.Builder builderForValue) {
+ ensureTypeAliasIsMutable();
+ typeAlias_.set(index, builderForValue.build());
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public Builder addTypeAlias(org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeAliasIsMutable();
+ typeAlias_.add(value);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public Builder addTypeAlias(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeAliasIsMutable();
+ typeAlias_.add(index, value);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public Builder addTypeAlias(
+ org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.Builder builderForValue) {
+ ensureTypeAliasIsMutable();
+ typeAlias_.add(builderForValue.build());
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public Builder addTypeAlias(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.Builder builderForValue) {
+ ensureTypeAliasIsMutable();
+ typeAlias_.add(index, builderForValue.build());
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public Builder addAllTypeAlias(
+ java.lang.Iterable extends org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias> values) {
+ ensureTypeAliasIsMutable();
+ super.addAll(values, typeAlias_);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public Builder clearTypeAlias() {
+ typeAlias_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000400);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 11;
+ */
+ public Builder removeTypeAlias(int index) {
+ ensureTypeAliasIsMutable();
+ typeAlias_.remove(index);
+
+ return this;
+ }
+
// repeated .org.jetbrains.kotlin.serialization.EnumEntry enum_entry = 13;
private java.util.List enumEntry_ =
java.util.Collections.emptyList();
private void ensureEnumEntryIsMutable() {
- if (!((bitField0_ & 0x00000400) == 0x00000400)) {
+ if (!((bitField0_ & 0x00000800) == 0x00000800)) {
enumEntry_ = new java.util.ArrayList(enumEntry_);
- bitField0_ |= 0x00000400;
+ bitField0_ |= 0x00000800;
}
}
@@ -9808,7 +10323,7 @@ public final class ProtoBuf {
*/
public Builder clearEnumEntry() {
enumEntry_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000400);
+ bitField0_ = (bitField0_ & ~0x00000800);
return this;
}
@@ -9828,7 +10343,7 @@ public final class ProtoBuf {
* optional .org.jetbrains.kotlin.serialization.TypeTable type_table = 30;
*/
public boolean hasTypeTable() {
- return ((bitField0_ & 0x00000800) == 0x00000800);
+ return ((bitField0_ & 0x00001000) == 0x00001000);
}
/**
* optional .org.jetbrains.kotlin.serialization.TypeTable type_table = 30;
@@ -9845,7 +10360,7 @@ public final class ProtoBuf {
}
typeTable_ = value;
- bitField0_ |= 0x00000800;
+ bitField0_ |= 0x00001000;
return this;
}
/**
@@ -9855,14 +10370,14 @@ public final class ProtoBuf {
org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.Builder builderForValue) {
typeTable_ = builderForValue.build();
- bitField0_ |= 0x00000800;
+ bitField0_ |= 0x00001000;
return this;
}
/**
* optional .org.jetbrains.kotlin.serialization.TypeTable type_table = 30;
*/
public Builder mergeTypeTable(org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable value) {
- if (((bitField0_ & 0x00000800) == 0x00000800) &&
+ if (((bitField0_ & 0x00001000) == 0x00001000) &&
typeTable_ != org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance()) {
typeTable_ =
org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.newBuilder(typeTable_).mergeFrom(value).buildPartial();
@@ -9870,7 +10385,7 @@ public final class ProtoBuf {
typeTable_ = value;
}
- bitField0_ |= 0x00000800;
+ bitField0_ |= 0x00001000;
return this;
}
/**
@@ -9879,7 +10394,7 @@ public final class ProtoBuf {
public Builder clearTypeTable() {
typeTable_ = org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance();
- bitField0_ = (bitField0_ & ~0x00000800);
+ bitField0_ = (bitField0_ & ~0x00001000);
return this;
}
@@ -9928,6 +10443,21 @@ public final class ProtoBuf {
*/
int getPropertyCount();
+ // repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ java.util.List
+ getTypeAliasList();
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias getTypeAlias(int index);
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ int getTypeAliasCount();
+
// optional .org.jetbrains.kotlin.serialization.TypeTable type_table = 30;
/**
* optional .org.jetbrains.kotlin.serialization.TypeTable type_table = 30;
@@ -9997,6 +10527,14 @@ public final class ProtoBuf {
property_.add(input.readMessage(org.jetbrains.kotlin.serialization.ProtoBuf.Property.PARSER, extensionRegistry));
break;
}
+ case 42: {
+ if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
+ typeAlias_ = new java.util.ArrayList();
+ mutable_bitField0_ |= 0x00000004;
+ }
+ typeAlias_.add(input.readMessage(org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.PARSER, extensionRegistry));
+ break;
+ }
case 242: {
org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.Builder subBuilder = null;
if (((bitField0_ & 0x00000001) == 0x00000001)) {
@@ -10024,6 +10562,9 @@ public final class ProtoBuf {
if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
property_ = java.util.Collections.unmodifiableList(property_);
}
+ if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
+ typeAlias_ = java.util.Collections.unmodifiableList(typeAlias_);
+ }
makeExtensionsImmutable();
}
}
@@ -10115,6 +10656,42 @@ public final class ProtoBuf {
return property_.get(index);
}
+ // repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ public static final int TYPE_ALIAS_FIELD_NUMBER = 5;
+ private java.util.List typeAlias_;
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public java.util.List getTypeAliasList() {
+ return typeAlias_;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public java.util.List extends org.jetbrains.kotlin.serialization.ProtoBuf.TypeAliasOrBuilder>
+ getTypeAliasOrBuilderList() {
+ return typeAlias_;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public int getTypeAliasCount() {
+ return typeAlias_.size();
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias getTypeAlias(int index) {
+ return typeAlias_.get(index);
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeAliasOrBuilder getTypeAliasOrBuilder(
+ int index) {
+ return typeAlias_.get(index);
+ }
+
// optional .org.jetbrains.kotlin.serialization.TypeTable type_table = 30;
public static final int TYPE_TABLE_FIELD_NUMBER = 30;
private org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable typeTable_;
@@ -10134,6 +10711,7 @@ public final class ProtoBuf {
private void initFields() {
function_ = java.util.Collections.emptyList();
property_ = java.util.Collections.emptyList();
+ typeAlias_ = java.util.Collections.emptyList();
typeTable_ = org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
@@ -10153,6 +10731,12 @@ public final class ProtoBuf {
return false;
}
}
+ for (int i = 0; i < getTypeAliasCount(); i++) {
+ if (!getTypeAlias(i).isInitialized()) {
+ memoizedIsInitialized = 0;
+ return false;
+ }
+ }
if (hasTypeTable()) {
if (!getTypeTable().isInitialized()) {
memoizedIsInitialized = 0;
@@ -10179,6 +10763,9 @@ public final class ProtoBuf {
for (int i = 0; i < property_.size(); i++) {
output.writeMessage(4, property_.get(i));
}
+ for (int i = 0; i < typeAlias_.size(); i++) {
+ output.writeMessage(5, typeAlias_.get(i));
+ }
if (((bitField0_ & 0x00000001) == 0x00000001)) {
output.writeMessage(30, typeTable_);
}
@@ -10199,6 +10786,10 @@ public final class ProtoBuf {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, property_.get(i));
}
+ for (int i = 0; i < typeAlias_.size(); i++) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(5, typeAlias_.get(i));
+ }
if (((bitField0_ & 0x00000001) == 0x00000001)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(30, typeTable_);
@@ -10298,8 +10889,10 @@ public final class ProtoBuf {
bitField0_ = (bitField0_ & ~0x00000001);
property_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
- typeTable_ = org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance();
+ typeAlias_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);
+ typeTable_ = org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance();
+ bitField0_ = (bitField0_ & ~0x00000008);
return this;
}
@@ -10333,7 +10926,12 @@ public final class ProtoBuf {
bitField0_ = (bitField0_ & ~0x00000002);
}
result.property_ = property_;
- if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
+ if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ typeAlias_ = java.util.Collections.unmodifiableList(typeAlias_);
+ bitField0_ = (bitField0_ & ~0x00000004);
+ }
+ result.typeAlias_ = typeAlias_;
+ if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
to_bitField0_ |= 0x00000001;
}
result.typeTable_ = typeTable_;
@@ -10362,6 +10960,16 @@ public final class ProtoBuf {
property_.addAll(other.property_);
}
+ }
+ if (!other.typeAlias_.isEmpty()) {
+ if (typeAlias_.isEmpty()) {
+ typeAlias_ = other.typeAlias_;
+ bitField0_ = (bitField0_ & ~0x00000004);
+ } else {
+ ensureTypeAliasIsMutable();
+ typeAlias_.addAll(other.typeAlias_);
+ }
+
}
if (other.hasTypeTable()) {
mergeTypeTable(other.getTypeTable());
@@ -10383,6 +10991,12 @@ public final class ProtoBuf {
return false;
}
}
+ for (int i = 0; i < getTypeAliasCount(); i++) {
+ if (!getTypeAlias(i).isInitialized()) {
+
+ return false;
+ }
+ }
if (hasTypeTable()) {
if (!getTypeTable().isInitialized()) {
@@ -10665,13 +11279,138 @@ public final class ProtoBuf {
return this;
}
+ // repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ private java.util.List typeAlias_ =
+ java.util.Collections.emptyList();
+ private void ensureTypeAliasIsMutable() {
+ if (!((bitField0_ & 0x00000004) == 0x00000004)) {
+ typeAlias_ = new java.util.ArrayList(typeAlias_);
+ bitField0_ |= 0x00000004;
+ }
+ }
+
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public java.util.List getTypeAliasList() {
+ return java.util.Collections.unmodifiableList(typeAlias_);
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public int getTypeAliasCount() {
+ return typeAlias_.size();
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias getTypeAlias(int index) {
+ return typeAlias_.get(index);
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public Builder setTypeAlias(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeAliasIsMutable();
+ typeAlias_.set(index, value);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public Builder setTypeAlias(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.Builder builderForValue) {
+ ensureTypeAliasIsMutable();
+ typeAlias_.set(index, builderForValue.build());
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public Builder addTypeAlias(org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeAliasIsMutable();
+ typeAlias_.add(value);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public Builder addTypeAlias(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeAliasIsMutable();
+ typeAlias_.add(index, value);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public Builder addTypeAlias(
+ org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.Builder builderForValue) {
+ ensureTypeAliasIsMutable();
+ typeAlias_.add(builderForValue.build());
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public Builder addTypeAlias(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.Builder builderForValue) {
+ ensureTypeAliasIsMutable();
+ typeAlias_.add(index, builderForValue.build());
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public Builder addAllTypeAlias(
+ java.lang.Iterable extends org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias> values) {
+ ensureTypeAliasIsMutable();
+ super.addAll(values, typeAlias_);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public Builder clearTypeAlias() {
+ typeAlias_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000004);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeAlias type_alias = 5;
+ */
+ public Builder removeTypeAlias(int index) {
+ ensureTypeAliasIsMutable();
+ typeAlias_.remove(index);
+
+ return this;
+ }
+
// optional .org.jetbrains.kotlin.serialization.TypeTable type_table = 30;
private org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable typeTable_ = org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance();
/**
* optional .org.jetbrains.kotlin.serialization.TypeTable type_table = 30;
*/
public boolean hasTypeTable() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
+ return ((bitField0_ & 0x00000008) == 0x00000008);
}
/**
* optional .org.jetbrains.kotlin.serialization.TypeTable type_table = 30;
@@ -10688,7 +11427,7 @@ public final class ProtoBuf {
}
typeTable_ = value;
- bitField0_ |= 0x00000004;
+ bitField0_ |= 0x00000008;
return this;
}
/**
@@ -10698,14 +11437,14 @@ public final class ProtoBuf {
org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.Builder builderForValue) {
typeTable_ = builderForValue.build();
- bitField0_ |= 0x00000004;
+ bitField0_ |= 0x00000008;
return this;
}
/**
* optional .org.jetbrains.kotlin.serialization.TypeTable type_table = 30;
*/
public Builder mergeTypeTable(org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable value) {
- if (((bitField0_ & 0x00000004) == 0x00000004) &&
+ if (((bitField0_ & 0x00000008) == 0x00000008) &&
typeTable_ != org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance()) {
typeTable_ =
org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.newBuilder(typeTable_).mergeFrom(value).buildPartial();
@@ -10713,7 +11452,7 @@ public final class ProtoBuf {
typeTable_ = value;
}
- bitField0_ |= 0x00000004;
+ bitField0_ |= 0x00000008;
return this;
}
/**
@@ -10722,7 +11461,7 @@ public final class ProtoBuf {
public Builder clearTypeTable() {
typeTable_ = org.jetbrains.kotlin.serialization.ProtoBuf.TypeTable.getDefaultInstance();
- bitField0_ = (bitField0_ & ~0x00000004);
+ bitField0_ = (bitField0_ & ~0x00000008);
return this;
}
@@ -16135,6 +16874,1134 @@ public final class ProtoBuf {
// @@protoc_insertion_point(class_scope:org.jetbrains.kotlin.serialization.ValueParameter)
}
+ public interface TypeAliasOrBuilder extends
+ com.google.protobuf.GeneratedMessageLite.
+ ExtendableMessageOrBuilder {
+
+ // optional int32 flags = 1 [default = 0];
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ boolean hasFlags();
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ int getFlags();
+
+ // required int32 name = 2;
+ /**
+ * required int32 name = 2;
+ */
+ boolean hasName();
+ /**
+ * required int32 name = 2;
+ */
+ int getName();
+
+ // repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ java.util.List
+ getTypeParameterList();
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter getTypeParameter(int index);
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ int getTypeParameterCount();
+
+ // optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ boolean hasUnderlyingType();
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type getUnderlyingType();
+
+ // optional int32 underlying_type_id = 5;
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ boolean hasUnderlyingTypeId();
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ int getUnderlyingTypeId();
+
+ // optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ boolean hasExpandedType();
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type getExpandedType();
+
+ // optional int32 expanded_type_id = 7;
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ boolean hasExpandedTypeId();
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ int getExpandedTypeId();
+ }
+ /**
+ * Protobuf type {@code org.jetbrains.kotlin.serialization.TypeAlias}
+ */
+ public static final class TypeAlias extends
+ com.google.protobuf.GeneratedMessageLite.ExtendableMessage<
+ TypeAlias> implements TypeAliasOrBuilder {
+ // Use TypeAlias.newBuilder() to construct.
+ private TypeAlias(com.google.protobuf.GeneratedMessageLite.ExtendableBuilder builder) {
+ super(builder);
+
+ }
+ private TypeAlias(boolean noInit) {}
+
+ private static final TypeAlias defaultInstance;
+ public static TypeAlias getDefaultInstance() {
+ return defaultInstance;
+ }
+
+ public TypeAlias getDefaultInstanceForType() {
+ return defaultInstance;
+ }
+
+ private TypeAlias(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ initFields();
+ int mutable_bitField0_ = 0;
+ try {
+ boolean done = false;
+ while (!done) {
+ int tag = input.readTag();
+ switch (tag) {
+ case 0:
+ done = true;
+ break;
+ default: {
+ if (!parseUnknownField(input,
+ extensionRegistry, tag)) {
+ done = true;
+ }
+ break;
+ }
+ case 8: {
+ bitField0_ |= 0x00000001;
+ flags_ = input.readInt32();
+ break;
+ }
+ case 16: {
+ bitField0_ |= 0x00000002;
+ name_ = input.readInt32();
+ break;
+ }
+ case 26: {
+ if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
+ typeParameter_ = new java.util.ArrayList();
+ mutable_bitField0_ |= 0x00000004;
+ }
+ typeParameter_.add(input.readMessage(org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter.PARSER, extensionRegistry));
+ break;
+ }
+ case 34: {
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type.Builder subBuilder = null;
+ if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ subBuilder = underlyingType_.toBuilder();
+ }
+ underlyingType_ = input.readMessage(org.jetbrains.kotlin.serialization.ProtoBuf.Type.PARSER, extensionRegistry);
+ if (subBuilder != null) {
+ subBuilder.mergeFrom(underlyingType_);
+ underlyingType_ = subBuilder.buildPartial();
+ }
+ bitField0_ |= 0x00000004;
+ break;
+ }
+ case 40: {
+ bitField0_ |= 0x00000008;
+ underlyingTypeId_ = input.readInt32();
+ break;
+ }
+ case 50: {
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type.Builder subBuilder = null;
+ if (((bitField0_ & 0x00000010) == 0x00000010)) {
+ subBuilder = expandedType_.toBuilder();
+ }
+ expandedType_ = input.readMessage(org.jetbrains.kotlin.serialization.ProtoBuf.Type.PARSER, extensionRegistry);
+ if (subBuilder != null) {
+ subBuilder.mergeFrom(expandedType_);
+ expandedType_ = subBuilder.buildPartial();
+ }
+ bitField0_ |= 0x00000010;
+ break;
+ }
+ case 56: {
+ bitField0_ |= 0x00000020;
+ expandedTypeId_ = input.readInt32();
+ break;
+ }
+ }
+ }
+ } catch (com.google.protobuf.InvalidProtocolBufferException e) {
+ throw e.setUnfinishedMessage(this);
+ } catch (java.io.IOException e) {
+ throw new com.google.protobuf.InvalidProtocolBufferException(
+ e.getMessage()).setUnfinishedMessage(this);
+ } finally {
+ if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
+ typeParameter_ = java.util.Collections.unmodifiableList(typeParameter_);
+ }
+ makeExtensionsImmutable();
+ }
+ }
+ public static com.google.protobuf.Parser PARSER =
+ new com.google.protobuf.AbstractParser() {
+ public TypeAlias parsePartialFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return new TypeAlias(input, extensionRegistry);
+ }
+ };
+
+ @java.lang.Override
+ public com.google.protobuf.Parser getParserForType() {
+ return PARSER;
+ }
+
+ private int bitField0_;
+ // optional int32 flags = 1 [default = 0];
+ public static final int FLAGS_FIELD_NUMBER = 1;
+ private int flags_;
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ public boolean hasFlags() {
+ return ((bitField0_ & 0x00000001) == 0x00000001);
+ }
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ public int getFlags() {
+ return flags_;
+ }
+
+ // required int32 name = 2;
+ public static final int NAME_FIELD_NUMBER = 2;
+ private int name_;
+ /**
+ * required int32 name = 2;
+ */
+ public boolean hasName() {
+ return ((bitField0_ & 0x00000002) == 0x00000002);
+ }
+ /**
+ * required int32 name = 2;
+ */
+ public int getName() {
+ return name_;
+ }
+
+ // repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ public static final int TYPE_PARAMETER_FIELD_NUMBER = 3;
+ private java.util.List typeParameter_;
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public java.util.List getTypeParameterList() {
+ return typeParameter_;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public java.util.List extends org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameterOrBuilder>
+ getTypeParameterOrBuilderList() {
+ return typeParameter_;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public int getTypeParameterCount() {
+ return typeParameter_.size();
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter getTypeParameter(int index) {
+ return typeParameter_.get(index);
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameterOrBuilder getTypeParameterOrBuilder(
+ int index) {
+ return typeParameter_.get(index);
+ }
+
+ // optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ public static final int UNDERLYING_TYPE_FIELD_NUMBER = 4;
+ private org.jetbrains.kotlin.serialization.ProtoBuf.Type underlyingType_;
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public boolean hasUnderlyingType() {
+ return ((bitField0_ & 0x00000004) == 0x00000004);
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.Type getUnderlyingType() {
+ return underlyingType_;
+ }
+
+ // optional int32 underlying_type_id = 5;
+ public static final int UNDERLYING_TYPE_ID_FIELD_NUMBER = 5;
+ private int underlyingTypeId_;
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ public boolean hasUnderlyingTypeId() {
+ return ((bitField0_ & 0x00000008) == 0x00000008);
+ }
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ public int getUnderlyingTypeId() {
+ return underlyingTypeId_;
+ }
+
+ // optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ public static final int EXPANDED_TYPE_FIELD_NUMBER = 6;
+ private org.jetbrains.kotlin.serialization.ProtoBuf.Type expandedType_;
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public boolean hasExpandedType() {
+ return ((bitField0_ & 0x00000010) == 0x00000010);
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.Type getExpandedType() {
+ return expandedType_;
+ }
+
+ // optional int32 expanded_type_id = 7;
+ public static final int EXPANDED_TYPE_ID_FIELD_NUMBER = 7;
+ private int expandedTypeId_;
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ public boolean hasExpandedTypeId() {
+ return ((bitField0_ & 0x00000020) == 0x00000020);
+ }
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ public int getExpandedTypeId() {
+ return expandedTypeId_;
+ }
+
+ private void initFields() {
+ flags_ = 0;
+ name_ = 0;
+ typeParameter_ = java.util.Collections.emptyList();
+ underlyingType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+ underlyingTypeId_ = 0;
+ expandedType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+ expandedTypeId_ = 0;
+ }
+ private byte memoizedIsInitialized = -1;
+ public final boolean isInitialized() {
+ byte isInitialized = memoizedIsInitialized;
+ if (isInitialized != -1) return isInitialized == 1;
+
+ if (!hasName()) {
+ memoizedIsInitialized = 0;
+ return false;
+ }
+ for (int i = 0; i < getTypeParameterCount(); i++) {
+ if (!getTypeParameter(i).isInitialized()) {
+ memoizedIsInitialized = 0;
+ return false;
+ }
+ }
+ if (hasUnderlyingType()) {
+ if (!getUnderlyingType().isInitialized()) {
+ memoizedIsInitialized = 0;
+ return false;
+ }
+ }
+ if (hasExpandedType()) {
+ if (!getExpandedType().isInitialized()) {
+ memoizedIsInitialized = 0;
+ return false;
+ }
+ }
+ if (!extensionsAreInitialized()) {
+ memoizedIsInitialized = 0;
+ return false;
+ }
+ memoizedIsInitialized = 1;
+ return true;
+ }
+
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
+ throws java.io.IOException {
+ getSerializedSize();
+ com.google.protobuf.GeneratedMessageLite
+ .ExtendableMessage.ExtensionWriter extensionWriter =
+ newExtensionWriter();
+ if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ output.writeInt32(1, flags_);
+ }
+ if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ output.writeInt32(2, name_);
+ }
+ for (int i = 0; i < typeParameter_.size(); i++) {
+ output.writeMessage(3, typeParameter_.get(i));
+ }
+ if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ output.writeMessage(4, underlyingType_);
+ }
+ if (((bitField0_ & 0x00000008) == 0x00000008)) {
+ output.writeInt32(5, underlyingTypeId_);
+ }
+ if (((bitField0_ & 0x00000010) == 0x00000010)) {
+ output.writeMessage(6, expandedType_);
+ }
+ if (((bitField0_ & 0x00000020) == 0x00000020)) {
+ output.writeInt32(7, expandedTypeId_);
+ }
+ extensionWriter.writeUntil(200, output);
+ }
+
+ private int memoizedSerializedSize = -1;
+ public int getSerializedSize() {
+ int size = memoizedSerializedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeInt32Size(1, flags_);
+ }
+ if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeInt32Size(2, name_);
+ }
+ for (int i = 0; i < typeParameter_.size(); i++) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(3, typeParameter_.get(i));
+ }
+ if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(4, underlyingType_);
+ }
+ if (((bitField0_ & 0x00000008) == 0x00000008)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeInt32Size(5, underlyingTypeId_);
+ }
+ if (((bitField0_ & 0x00000010) == 0x00000010)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(6, expandedType_);
+ }
+ if (((bitField0_ & 0x00000020) == 0x00000020)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeInt32Size(7, expandedTypeId_);
+ }
+ size += extensionsSerializedSize();
+ 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.serialization.ProtoBuf.TypeAlias parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias parseFrom(
+ com.google.protobuf.ByteString data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+ public static org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias parseFrom(
+ byte[] data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+ public static org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias parseFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return PARSER.parseFrom(input);
+ }
+ public static org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias parseFrom(
+ java.io.InputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return PARSER.parseFrom(input, extensionRegistry);
+ }
+ public static org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias parseDelimitedFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return PARSER.parseDelimitedFrom(input);
+ }
+ public static org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias parseDelimitedFrom(
+ java.io.InputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return PARSER.parseDelimitedFrom(input, extensionRegistry);
+ }
+ public static org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias parseFrom(
+ com.google.protobuf.CodedInputStream input)
+ throws java.io.IOException {
+ return PARSER.parseFrom(input);
+ }
+ public static org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias parseFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.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.serialization.ProtoBuf.TypeAlias prototype) {
+ return newBuilder().mergeFrom(prototype);
+ }
+ public Builder toBuilder() { return newBuilder(this); }
+
+ /**
+ * Protobuf type {@code org.jetbrains.kotlin.serialization.TypeAlias}
+ */
+ public static final class Builder extends
+ com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<
+ org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias, Builder> implements org.jetbrains.kotlin.serialization.ProtoBuf.TypeAliasOrBuilder {
+ // Construct using org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.newBuilder()
+ private Builder() {
+ maybeForceBuilderInitialization();
+ }
+
+ private void maybeForceBuilderInitialization() {
+ }
+ private static Builder create() {
+ return new Builder();
+ }
+
+ public Builder clear() {
+ super.clear();
+ flags_ = 0;
+ bitField0_ = (bitField0_ & ~0x00000001);
+ name_ = 0;
+ bitField0_ = (bitField0_ & ~0x00000002);
+ typeParameter_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000004);
+ underlyingType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+ bitField0_ = (bitField0_ & ~0x00000008);
+ underlyingTypeId_ = 0;
+ bitField0_ = (bitField0_ & ~0x00000010);
+ expandedType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+ bitField0_ = (bitField0_ & ~0x00000020);
+ expandedTypeId_ = 0;
+ bitField0_ = (bitField0_ & ~0x00000040);
+ return this;
+ }
+
+ public Builder clone() {
+ return create().mergeFrom(buildPartial());
+ }
+
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias getDefaultInstanceForType() {
+ return org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.getDefaultInstance();
+ }
+
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias build() {
+ org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias result = buildPartial();
+ if (!result.isInitialized()) {
+ throw newUninitializedMessageException(result);
+ }
+ return result;
+ }
+
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias buildPartial() {
+ org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias result = new org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias(this);
+ int from_bitField0_ = bitField0_;
+ int to_bitField0_ = 0;
+ if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
+ to_bitField0_ |= 0x00000001;
+ }
+ result.flags_ = flags_;
+ if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
+ to_bitField0_ |= 0x00000002;
+ }
+ result.name_ = name_;
+ 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.underlyingType_ = underlyingType_;
+ if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
+ to_bitField0_ |= 0x00000008;
+ }
+ result.underlyingTypeId_ = underlyingTypeId_;
+ if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
+ to_bitField0_ |= 0x00000010;
+ }
+ result.expandedType_ = expandedType_;
+ if (((from_bitField0_ & 0x00000040) == 0x00000040)) {
+ to_bitField0_ |= 0x00000020;
+ }
+ result.expandedTypeId_ = expandedTypeId_;
+ result.bitField0_ = to_bitField0_;
+ return result;
+ }
+
+ public Builder mergeFrom(org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias other) {
+ if (other == org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias.getDefaultInstance()) return this;
+ if (other.hasFlags()) {
+ setFlags(other.getFlags());
+ }
+ if (other.hasName()) {
+ setName(other.getName());
+ }
+ if (!other.typeParameter_.isEmpty()) {
+ if (typeParameter_.isEmpty()) {
+ typeParameter_ = other.typeParameter_;
+ bitField0_ = (bitField0_ & ~0x00000004);
+ } else {
+ ensureTypeParameterIsMutable();
+ typeParameter_.addAll(other.typeParameter_);
+ }
+
+ }
+ if (other.hasUnderlyingType()) {
+ mergeUnderlyingType(other.getUnderlyingType());
+ }
+ if (other.hasUnderlyingTypeId()) {
+ setUnderlyingTypeId(other.getUnderlyingTypeId());
+ }
+ if (other.hasExpandedType()) {
+ mergeExpandedType(other.getExpandedType());
+ }
+ if (other.hasExpandedTypeId()) {
+ setExpandedTypeId(other.getExpandedTypeId());
+ }
+ this.mergeExtensionFields(other);
+ return this;
+ }
+
+ public final boolean isInitialized() {
+ if (!hasName()) {
+
+ return false;
+ }
+ for (int i = 0; i < getTypeParameterCount(); i++) {
+ if (!getTypeParameter(i).isInitialized()) {
+
+ return false;
+ }
+ }
+ if (hasUnderlyingType()) {
+ if (!getUnderlyingType().isInitialized()) {
+
+ return false;
+ }
+ }
+ if (hasExpandedType()) {
+ if (!getExpandedType().isInitialized()) {
+
+ return false;
+ }
+ }
+ if (!extensionsAreInitialized()) {
+
+ return false;
+ }
+ return true;
+ }
+
+ public Builder mergeFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias parsedMessage = null;
+ try {
+ parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
+ } catch (com.google.protobuf.InvalidProtocolBufferException e) {
+ parsedMessage = (org.jetbrains.kotlin.serialization.ProtoBuf.TypeAlias) e.getUnfinishedMessage();
+ throw e;
+ } finally {
+ if (parsedMessage != null) {
+ mergeFrom(parsedMessage);
+ }
+ }
+ return this;
+ }
+ private int bitField0_;
+
+ // optional int32 flags = 1 [default = 0];
+ private int flags_ ;
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ public boolean hasFlags() {
+ return ((bitField0_ & 0x00000001) == 0x00000001);
+ }
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ public int getFlags() {
+ return flags_;
+ }
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ public Builder setFlags(int value) {
+ bitField0_ |= 0x00000001;
+ flags_ = value;
+
+ return this;
+ }
+ /**
+ * optional int32 flags = 1 [default = 0];
+ *
+ *
+ *
+ *hasAnnotations
+ *Visibility
+ *
+ */
+ public Builder clearFlags() {
+ bitField0_ = (bitField0_ & ~0x00000001);
+ flags_ = 0;
+
+ return this;
+ }
+
+ // required int32 name = 2;
+ private int name_ ;
+ /**
+ * required int32 name = 2;
+ */
+ public boolean hasName() {
+ return ((bitField0_ & 0x00000002) == 0x00000002);
+ }
+ /**
+ * required int32 name = 2;
+ */
+ public int getName() {
+ return name_;
+ }
+ /**
+ * required int32 name = 2;
+ */
+ public Builder setName(int value) {
+ bitField0_ |= 0x00000002;
+ name_ = value;
+
+ return this;
+ }
+ /**
+ * required int32 name = 2;
+ */
+ public Builder clearName() {
+ bitField0_ = (bitField0_ & ~0x00000002);
+ name_ = 0;
+
+ return this;
+ }
+
+ // repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ private java.util.List typeParameter_ =
+ java.util.Collections.emptyList();
+ private void ensureTypeParameterIsMutable() {
+ if (!((bitField0_ & 0x00000004) == 0x00000004)) {
+ typeParameter_ = new java.util.ArrayList(typeParameter_);
+ bitField0_ |= 0x00000004;
+ }
+ }
+
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public java.util.List getTypeParameterList() {
+ return java.util.Collections.unmodifiableList(typeParameter_);
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public int getTypeParameterCount() {
+ return typeParameter_.size();
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter getTypeParameter(int index) {
+ return typeParameter_.get(index);
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder setTypeParameter(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeParameterIsMutable();
+ typeParameter_.set(index, value);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder setTypeParameter(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter.Builder builderForValue) {
+ ensureTypeParameterIsMutable();
+ typeParameter_.set(index, builderForValue.build());
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder addTypeParameter(org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeParameterIsMutable();
+ typeParameter_.add(value);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder addTypeParameter(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureTypeParameterIsMutable();
+ typeParameter_.add(index, value);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder addTypeParameter(
+ org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter.Builder builderForValue) {
+ ensureTypeParameterIsMutable();
+ typeParameter_.add(builderForValue.build());
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder addTypeParameter(
+ int index, org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter.Builder builderForValue) {
+ ensureTypeParameterIsMutable();
+ typeParameter_.add(index, builderForValue.build());
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder addAllTypeParameter(
+ java.lang.Iterable extends org.jetbrains.kotlin.serialization.ProtoBuf.TypeParameter> values) {
+ ensureTypeParameterIsMutable();
+ super.addAll(values, typeParameter_);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder clearTypeParameter() {
+ typeParameter_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000004);
+
+ return this;
+ }
+ /**
+ * repeated .org.jetbrains.kotlin.serialization.TypeParameter type_parameter = 3;
+ */
+ public Builder removeTypeParameter(int index) {
+ ensureTypeParameterIsMutable();
+ typeParameter_.remove(index);
+
+ return this;
+ }
+
+ // optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ private org.jetbrains.kotlin.serialization.ProtoBuf.Type underlyingType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public boolean hasUnderlyingType() {
+ return ((bitField0_ & 0x00000008) == 0x00000008);
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.Type getUnderlyingType() {
+ return underlyingType_;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public Builder setUnderlyingType(org.jetbrains.kotlin.serialization.ProtoBuf.Type value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ underlyingType_ = value;
+
+ bitField0_ |= 0x00000008;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public Builder setUnderlyingType(
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type.Builder builderForValue) {
+ underlyingType_ = builderForValue.build();
+
+ bitField0_ |= 0x00000008;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public Builder mergeUnderlyingType(org.jetbrains.kotlin.serialization.ProtoBuf.Type value) {
+ if (((bitField0_ & 0x00000008) == 0x00000008) &&
+ underlyingType_ != org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance()) {
+ underlyingType_ =
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type.newBuilder(underlyingType_).mergeFrom(value).buildPartial();
+ } else {
+ underlyingType_ = value;
+ }
+
+ bitField0_ |= 0x00000008;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type underlying_type = 4;
+ */
+ public Builder clearUnderlyingType() {
+ underlyingType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+
+ bitField0_ = (bitField0_ & ~0x00000008);
+ return this;
+ }
+
+ // optional int32 underlying_type_id = 5;
+ private int underlyingTypeId_ ;
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ public boolean hasUnderlyingTypeId() {
+ return ((bitField0_ & 0x00000010) == 0x00000010);
+ }
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ public int getUnderlyingTypeId() {
+ return underlyingTypeId_;
+ }
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ public Builder setUnderlyingTypeId(int value) {
+ bitField0_ |= 0x00000010;
+ underlyingTypeId_ = value;
+
+ return this;
+ }
+ /**
+ * optional int32 underlying_type_id = 5;
+ */
+ public Builder clearUnderlyingTypeId() {
+ bitField0_ = (bitField0_ & ~0x00000010);
+ underlyingTypeId_ = 0;
+
+ return this;
+ }
+
+ // optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ private org.jetbrains.kotlin.serialization.ProtoBuf.Type expandedType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public boolean hasExpandedType() {
+ return ((bitField0_ & 0x00000020) == 0x00000020);
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public org.jetbrains.kotlin.serialization.ProtoBuf.Type getExpandedType() {
+ return expandedType_;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public Builder setExpandedType(org.jetbrains.kotlin.serialization.ProtoBuf.Type value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ expandedType_ = value;
+
+ bitField0_ |= 0x00000020;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public Builder setExpandedType(
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type.Builder builderForValue) {
+ expandedType_ = builderForValue.build();
+
+ bitField0_ |= 0x00000020;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public Builder mergeExpandedType(org.jetbrains.kotlin.serialization.ProtoBuf.Type value) {
+ if (((bitField0_ & 0x00000020) == 0x00000020) &&
+ expandedType_ != org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance()) {
+ expandedType_ =
+ org.jetbrains.kotlin.serialization.ProtoBuf.Type.newBuilder(expandedType_).mergeFrom(value).buildPartial();
+ } else {
+ expandedType_ = value;
+ }
+
+ bitField0_ |= 0x00000020;
+ return this;
+ }
+ /**
+ * optional .org.jetbrains.kotlin.serialization.Type expanded_type = 6;
+ */
+ public Builder clearExpandedType() {
+ expandedType_ = org.jetbrains.kotlin.serialization.ProtoBuf.Type.getDefaultInstance();
+
+ bitField0_ = (bitField0_ & ~0x00000020);
+ return this;
+ }
+
+ // optional int32 expanded_type_id = 7;
+ private int expandedTypeId_ ;
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ public boolean hasExpandedTypeId() {
+ return ((bitField0_ & 0x00000040) == 0x00000040);
+ }
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ public int getExpandedTypeId() {
+ return expandedTypeId_;
+ }
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ public Builder setExpandedTypeId(int value) {
+ bitField0_ |= 0x00000040;
+ expandedTypeId_ = value;
+
+ return this;
+ }
+ /**
+ * optional int32 expanded_type_id = 7;
+ */
+ public Builder clearExpandedTypeId() {
+ bitField0_ = (bitField0_ & ~0x00000040);
+ expandedTypeId_ = 0;
+
+ return this;
+ }
+
+ // @@protoc_insertion_point(builder_scope:org.jetbrains.kotlin.serialization.TypeAlias)
+ }
+
+ static {
+ defaultInstance = new TypeAlias(true);
+ defaultInstance.initFields();
+ }
+
+ // @@protoc_insertion_point(class_scope:org.jetbrains.kotlin.serialization.TypeAlias)
+ }
+
public interface EnumEntryOrBuilder extends
com.google.protobuf.GeneratedMessageLite.
ExtendableMessageOrBuilder {