Skip to content

Commit db126ca

Browse files
mkruskal-googlecopybara-github
authored andcommitted
Fix exhaustive switch issue in Rust generator
PiperOrigin-RevId: 520398035
1 parent 2eda0cc commit db126ca

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/google/protobuf/compiler/rust/generator.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,8 @@ std::string GetFileExtensionForKernel(Kernel kernel) {
9595
case Kernel::kCpp:
9696
return ".c.pb.rs";
9797
}
98+
ABSL_LOG(FATAL) << "Unknown kernel type: ";
99+
return "";
98100
}
99101

100102
void GenerateForUpb(const FileDescriptor* file, google::protobuf::io::Printer& p) {

0 commit comments

Comments
 (0)