Open
Description
Describe the bug
When building the Swift FlatBuffers library with Xcode 14 / Swift 5.7, the verify-emitted-module-interface
command fails with the following error:
error: verify-emitted-module-interface command failed with exit code 1 (use -v to see invocation)
bazel-out/ios-x86_64-min12.0-applebin_ios-ios_x86_64-fastbuild-ST-5ef840230b88/bin/external/swift_flatbuffers/swift/FlatBuffers.swiftinterface:161:3: error: missing return in accessor expected to return 'Swift.Int'
}
^
bazel-out/ios-x86_64-min12.0-applebin_ios-ios_x86_64-fastbuild-ST-5ef840230b88/bin/external/swift_flatbuffers/swift/FlatBuffers.swiftinterface:1:1: error: failed to verify module interface of 'FlatBuffers' due to the errors above; the textual interface may be broken by project issues or a compiler bug
// swift-interface-format-version: 1.0
^
The full FlatBuffers.swiftinterface
file is here: FlatBuffers.swiftinterface.zip
Notably lines 160-161 where it says the error is:
@_hasStorage internal var _minAlignment: Swift.Int = 0 {
}
Steps To Reproduce
Steps to reproduce the behavior:
$ git clone https://github.com/envoyproxy/envoy-mobile.git
$ cd envoy-mobile
$ git checkout jp-flatbuffers-swiftinterface-bug
$ git submodule update --init --recursive
$ ./bazelw build --config=ios //library/swift:ios_framework
Expected behavior
The .swiftinterface
file produced should be valid.
Screenshots
N/A
Environment (please fill out the following information)
- OS: macOS 12.6 (21G115)
- Xcode Version/Tag/Branch: Xcode 14.0 (14A309)
Additional context
Add any other context about the problem here.
Metadata
Metadata
Assignees
Labels
Area → compiler: The AST printerFeature → declarations: Variable (property) accessorsA deviation from expected or documented behavior. Also: expected but undesirable behavior.The Swift compiler itselfFeature: declarationsFeature → accessors: Stored variable (property) observers (`willSet`, `didSet`)Bug: Unexpected error