Skip to content

Commit

Permalink
Merge pull request #14591 from tanishiking/update-generated-semanticd…
Browse files Browse the repository at this point in the history
…b-code

Update generated semanticdb code with the latest scalapb
  • Loading branch information
bishabosha authored Mar 1, 2022
2 parents 84f7250 + 6533141 commit eaefd45
Show file tree
Hide file tree
Showing 18 changed files with 504 additions and 449 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ final case class AccessMessage(
sealedValue: dotty.tools.dotc.semanticdb.AccessMessage.SealedValue = dotty.tools.dotc.semanticdb.AccessMessage.SealedValue.Empty
) extends SemanticdbGeneratedMessage derives CanEqual {
@transient @sharable
private[this] var __serializedSizeCachedValue: _root_.scala.Int = 0
private[this] def __computeSerializedValue(): _root_.scala.Int = {
private[this] var __serializedSizeMemoized: _root_.scala.Int = 0
private[this] def __computeSerializedSize(): _root_.scala.Int = {
var __size = 0
if (sealedValue.privateAccess.isDefined) {
val __value = sealedValue.privateAccess.get
Expand Down Expand Up @@ -84,12 +84,13 @@ final case class AccessMessage(
__size
}
override def serializedSize: _root_.scala.Int = {
var read = __serializedSizeCachedValue
if (read == 0) {
read = __computeSerializedValue()
__serializedSizeCachedValue = read
var __size = __serializedSizeMemoized
if (__size == 0) {
__size = __computeSerializedSize() + 1
__serializedSizeMemoized = __size
}
read
__size - 1

}
def writeTo(`_output__`: SemanticdbOutputStream): _root_.scala.Unit = {
sealedValue.privateAccess.foreach { __v =>
Expand Down Expand Up @@ -378,8 +379,8 @@ final case class PrivateWithinAccess(
symbol: _root_.scala.Predef.String = ""
) extends dotty.tools.dotc.semanticdb.Access.NonEmpty with SemanticdbGeneratedMessage derives CanEqual {
@transient @sharable
private[this] var __serializedSizeCachedValue: _root_.scala.Int = 0
private[this] def __computeSerializedValue(): _root_.scala.Int = {
private[this] var __serializedSizeMemoized: _root_.scala.Int = 0
private[this] def __computeSerializedSize(): _root_.scala.Int = {
var __size = 0

{
Expand All @@ -391,12 +392,13 @@ final case class PrivateWithinAccess(
__size
}
override def serializedSize: _root_.scala.Int = {
var read = __serializedSizeCachedValue
if (read == 0) {
read = __computeSerializedValue()
__serializedSizeCachedValue = read
var __size = __serializedSizeMemoized
if (__size == 0) {
__size = __computeSerializedSize() + 1
__serializedSizeMemoized = __size
}
read
__size - 1

}
def writeTo(`_output__`: SemanticdbOutputStream): _root_.scala.Unit = {
{
Expand Down Expand Up @@ -537,8 +539,8 @@ final case class ProtectedWithinAccess(
symbol: _root_.scala.Predef.String = ""
) extends dotty.tools.dotc.semanticdb.Access.NonEmpty with SemanticdbGeneratedMessage derives CanEqual {
@transient @sharable
private[this] var __serializedSizeCachedValue: _root_.scala.Int = 0
private[this] def __computeSerializedValue(): _root_.scala.Int = {
private[this] var __serializedSizeMemoized: _root_.scala.Int = 0
private[this] def __computeSerializedSize(): _root_.scala.Int = {
var __size = 0

{
Expand All @@ -550,12 +552,13 @@ final case class ProtectedWithinAccess(
__size
}
override def serializedSize: _root_.scala.Int = {
var read = __serializedSizeCachedValue
if (read == 0) {
read = __computeSerializedValue()
__serializedSizeCachedValue = read
var __size = __serializedSizeMemoized
if (__size == 0) {
__size = __computeSerializedSize() + 1
__serializedSizeMemoized = __size
}
read
__size - 1

}
def writeTo(`_output__`: SemanticdbOutputStream): _root_.scala.Unit = {
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,30 +13,31 @@ final case class Annotation(
tpe: dotty.tools.dotc.semanticdb.Type = dotty.tools.dotc.semanticdb.Annotation._typemapper_tpe.toCustom(dotty.tools.dotc.semanticdb.TypeMessage.defaultInstance)
) extends SemanticdbGeneratedMessage derives CanEqual {
@transient @sharable
private[this] var __serializedSizeCachedValue: _root_.scala.Int = 0
private[this] def __computeSerializedValue(): _root_.scala.Int = {
private[this] var __serializedSizeMemoized: _root_.scala.Int = 0
private[this] def __computeSerializedSize(): _root_.scala.Int = {
var __size = 0

{
val __value = dotty.tools.dotc.semanticdb.Annotation._typemapper_tpe.toBase(tpe)
if (__value != dotty.tools.dotc.semanticdb.TypeMessage.defaultInstance) {
if (__value.serializedSize != 0) {
__size += 1 + SemanticdbOutputStream.computeUInt32SizeNoTag(__value.serializedSize) + __value.serializedSize
}
};
__size
}
override def serializedSize: _root_.scala.Int = {
var read = __serializedSizeCachedValue
if (read == 0) {
read = __computeSerializedValue()
__serializedSizeCachedValue = read
var __size = __serializedSizeMemoized
if (__size == 0) {
__size = __computeSerializedSize() + 1
__serializedSizeMemoized = __size
}
read
__size - 1

}
def writeTo(`_output__`: SemanticdbOutputStream): _root_.scala.Unit = {
{
val __v = dotty.tools.dotc.semanticdb.Annotation._typemapper_tpe.toBase(tpe)
if (__v != dotty.tools.dotc.semanticdb.TypeMessage.defaultInstance) {
if (__v.serializedSize != 0) {
_output__.writeTag(1, 2)
_output__.writeUInt32NoTag(__v.serializedSize)
__v.writeTo(_output__)
Expand Down
Loading

0 comments on commit eaefd45

Please sign in to comment.