Skip to content

Commit

Permalink
Regenerate
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasvl committed May 6, 2024
1 parent b4c6303 commit a1ce4a0
Show file tree
Hide file tree
Showing 7 changed files with 157 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@
// For information on using the generated types, please see the documentation:
// https://github.com/apple/swift-protobuf/

// Protocol Buffers - Google's data interchange format
// Copyright 2024 Google Inc. All rights reserved.
//
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file or at
// https://developers.google.com/open-source/licenses/bsd

import Foundation
import SwiftProtobuf

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@
// For information on using the generated types, please see the documentation:
// https://github.com/apple/swift-protobuf/

// Protocol Buffers - Google's data interchange format
// Copyright 2024 Google Inc. All rights reserved.
//
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file or at
// https://developers.google.com/open-source/licenses/bsd

import Foundation
import SwiftProtobuf

Expand Down
6 changes: 6 additions & 0 deletions Reference/upstream/google/protobuf/unittest.pb.swift
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ enum ProtobufUnittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
/// (1 << 32) to generate a 64b bitmask would be incorrect.
case foreignBax // = 32

/// Large enough to escape the Boxed Integer cache.
case foreignLarge // = 123456

init() {
self = .foreignFoo
}
Expand All @@ -54,6 +57,7 @@ enum ProtobufUnittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
case 5: self = .foreignBar
case 6: self = .foreignBaz
case 32: self = .foreignBax
case 123456: self = .foreignLarge
default: return nil
}
}
Expand All @@ -64,6 +68,7 @@ enum ProtobufUnittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
case .foreignBar: return 5
case .foreignBaz: return 6
case .foreignBax: return 32
case .foreignLarge: return 123456
}
}

Expand Down Expand Up @@ -10527,6 +10532,7 @@ extension ProtobufUnittest_ForeignEnum: SwiftProtobuf._ProtoNameProviding {
5: .same(proto: "FOREIGN_BAR"),
6: .same(proto: "FOREIGN_BAZ"),
32: .same(proto: "FOREIGN_BAX"),
123456: .same(proto: "FOREIGN_LARGE"),
]
}

Expand Down
116 changes: 116 additions & 0 deletions Reference/upstream/google/protobuf/unittest_custom_options.pb.swift
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,46 @@ struct ProtobufUnittest_SettingRealsFromNegativeInts: Sendable {
init() {}
}

struct ProtobufUnittest_SettingRealsFromInf: Sendable {
// SwiftProtobuf.Message conformance is added in an extension below. See the
// `Message` and `Message+*Additions` files in the SwiftProtobuf library for
// methods supported on all messages.

var unknownFields = SwiftProtobuf.UnknownStorage()

init() {}
}

struct ProtobufUnittest_SettingRealsFromNegativeInf: Sendable {
// SwiftProtobuf.Message conformance is added in an extension below. See the
// `Message` and `Message+*Additions` files in the SwiftProtobuf library for
// methods supported on all messages.

var unknownFields = SwiftProtobuf.UnknownStorage()

init() {}
}

struct ProtobufUnittest_SettingRealsFromNan: Sendable {
// SwiftProtobuf.Message conformance is added in an extension below. See the
// `Message` and `Message+*Additions` files in the SwiftProtobuf library for
// methods supported on all messages.

var unknownFields = SwiftProtobuf.UnknownStorage()

init() {}
}

struct ProtobufUnittest_SettingRealsFromNegativeNan: Sendable {
// SwiftProtobuf.Message conformance is added in an extension below. See the
// `Message` and `Message+*Additions` files in the SwiftProtobuf library for
// methods supported on all messages.

var unknownFields = SwiftProtobuf.UnknownStorage()

init() {}
}

struct ProtobufUnittest_ComplexOptionType1: SwiftProtobuf.ExtensibleMessage, Sendable {
// SwiftProtobuf.Message conformance is added in an extension below. See the
// `Message` and `Message+*Additions` files in the SwiftProtobuf library for
Expand Down Expand Up @@ -2101,6 +2141,82 @@ extension ProtobufUnittest_SettingRealsFromNegativeInts: SwiftProtobuf.Message,
}
}

extension ProtobufUnittest_SettingRealsFromInf: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding {
static let protoMessageName: String = _protobuf_package + ".SettingRealsFromInf"
static let _protobuf_nameMap = SwiftProtobuf._NameMap()

mutating func decodeMessage<D: SwiftProtobuf.Decoder>(decoder: inout D) throws {
// Load everything into unknown fields
while try decoder.nextFieldNumber() != nil {}
}

func traverse<V: SwiftProtobuf.Visitor>(visitor: inout V) throws {
try unknownFields.traverse(visitor: &visitor)
}

static func ==(lhs: ProtobufUnittest_SettingRealsFromInf, rhs: ProtobufUnittest_SettingRealsFromInf) -> Bool {
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}

extension ProtobufUnittest_SettingRealsFromNegativeInf: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding {
static let protoMessageName: String = _protobuf_package + ".SettingRealsFromNegativeInf"
static let _protobuf_nameMap = SwiftProtobuf._NameMap()

mutating func decodeMessage<D: SwiftProtobuf.Decoder>(decoder: inout D) throws {
// Load everything into unknown fields
while try decoder.nextFieldNumber() != nil {}
}

func traverse<V: SwiftProtobuf.Visitor>(visitor: inout V) throws {
try unknownFields.traverse(visitor: &visitor)
}

static func ==(lhs: ProtobufUnittest_SettingRealsFromNegativeInf, rhs: ProtobufUnittest_SettingRealsFromNegativeInf) -> Bool {
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}

extension ProtobufUnittest_SettingRealsFromNan: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding {
static let protoMessageName: String = _protobuf_package + ".SettingRealsFromNan"
static let _protobuf_nameMap = SwiftProtobuf._NameMap()

mutating func decodeMessage<D: SwiftProtobuf.Decoder>(decoder: inout D) throws {
// Load everything into unknown fields
while try decoder.nextFieldNumber() != nil {}
}

func traverse<V: SwiftProtobuf.Visitor>(visitor: inout V) throws {
try unknownFields.traverse(visitor: &visitor)
}

static func ==(lhs: ProtobufUnittest_SettingRealsFromNan, rhs: ProtobufUnittest_SettingRealsFromNan) -> Bool {
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}

extension ProtobufUnittest_SettingRealsFromNegativeNan: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding {
static let protoMessageName: String = _protobuf_package + ".SettingRealsFromNegativeNan"
static let _protobuf_nameMap = SwiftProtobuf._NameMap()

mutating func decodeMessage<D: SwiftProtobuf.Decoder>(decoder: inout D) throws {
// Load everything into unknown fields
while try decoder.nextFieldNumber() != nil {}
}

func traverse<V: SwiftProtobuf.Visitor>(visitor: inout V) throws {
try unknownFields.traverse(visitor: &visitor)
}

static func ==(lhs: ProtobufUnittest_SettingRealsFromNegativeNan, rhs: ProtobufUnittest_SettingRealsFromNegativeNan) -> Bool {
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}

extension ProtobufUnittest_ComplexOptionType1: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding {
static let protoMessageName: String = _protobuf_package + ".ComplexOptionType1"
static let _protobuf_nameMap: SwiftProtobuf._NameMap = [
Expand Down
7 changes: 7 additions & 0 deletions Reference/upstream/google/protobuf/unittest_proto3.pb.swift
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ enum Proto3Unittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
case foreignFoo // = 4
case foreignBar // = 5
case foreignBaz // = 6

/// Large enough to escape the Boxed Integer cache.
case foreignLarge // = 123456
case UNRECOGNIZED(Int)

init() {
Expand All @@ -45,6 +48,7 @@ enum Proto3Unittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
case 4: self = .foreignFoo
case 5: self = .foreignBar
case 6: self = .foreignBaz
case 123456: self = .foreignLarge
default: self = .UNRECOGNIZED(rawValue)
}
}
Expand All @@ -55,6 +59,7 @@ enum Proto3Unittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
case .foreignFoo: return 4
case .foreignBar: return 5
case .foreignBaz: return 6
case .foreignLarge: return 123456
case .UNRECOGNIZED(let i): return i
}
}
Expand All @@ -65,6 +70,7 @@ enum Proto3Unittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
.foreignFoo,
.foreignBar,
.foreignBaz,
.foreignLarge,
]

}
Expand Down Expand Up @@ -694,6 +700,7 @@ extension Proto3Unittest_ForeignEnum: SwiftProtobuf._ProtoNameProviding {
4: .same(proto: "FOREIGN_FOO"),
5: .same(proto: "FOREIGN_BAR"),
6: .same(proto: "FOREIGN_BAZ"),
123456: .same(proto: "FOREIGN_LARGE"),
]
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ enum Proto3ArenaUnittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
case foreignFoo // = 4
case foreignBar // = 5
case foreignBaz // = 6

/// Large enough to escape the Boxed Integer cache.
case foreignLarge // = 123456
case UNRECOGNIZED(Int)

init() {
Expand All @@ -45,6 +48,7 @@ enum Proto3ArenaUnittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
case 4: self = .foreignFoo
case 5: self = .foreignBar
case 6: self = .foreignBaz
case 123456: self = .foreignLarge
default: self = .UNRECOGNIZED(rawValue)
}
}
Expand All @@ -55,6 +59,7 @@ enum Proto3ArenaUnittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
case .foreignFoo: return 4
case .foreignBar: return 5
case .foreignBaz: return 6
case .foreignLarge: return 123456
case .UNRECOGNIZED(let i): return i
}
}
Expand All @@ -65,6 +70,7 @@ enum Proto3ArenaUnittest_ForeignEnum: SwiftProtobuf.Enum, Swift.CaseIterable {
.foreignFoo,
.foreignBar,
.foreignBaz,
.foreignLarge,
]

}
Expand Down Expand Up @@ -795,6 +801,7 @@ extension Proto3ArenaUnittest_ForeignEnum: SwiftProtobuf._ProtoNameProviding {
4: .same(proto: "FOREIGN_FOO"),
5: .same(proto: "FOREIGN_BAR"),
6: .same(proto: "FOREIGN_BAZ"),
123456: .same(proto: "FOREIGN_LARGE"),
]
}

Expand Down
7 changes: 7 additions & 0 deletions Sources/Conformance/test_messages_edition2023.pb.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@
// For information on using the generated types, please see the documentation:
// https://github.com/apple/swift-protobuf/

// Protocol Buffers - Google's data interchange format
// Copyright 2024 Google Inc. All rights reserved.
//
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file or at
// https://developers.google.com/open-source/licenses/bsd

import Foundation
import SwiftProtobuf

Expand Down

0 comments on commit a1ce4a0

Please sign in to comment.