-
Notifications
You must be signed in to change notification settings - Fork 410
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cmd/protoc-gen-go: fix generation of enum defaults
Previously, this call strconv.FormatInt with base 32, when the intention is to call it with base 10. Change-Id: I31cdd2415b3a80936cdcdeb5612a486204404ecb Reviewed-on: https://go-review.googlesource.com/c/protobuf/+/331149 Trust: Joe Tsai <joetsai@digital-static.net> Reviewed-by: Damien Neil <dneil@google.com>
- Loading branch information
Showing
5 changed files
with
1,503 additions
and
1,222 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
// Copyright 2021 The Go Authors. All rights reserved. | ||
// Use of this source code is governed by a BSD-style | ||
// license that can be found in the LICENSE file. | ||
|
||
syntax = "proto2"; | ||
|
||
package goproto.proto.enums; | ||
|
||
option go_package = "google.golang.org/protobuf/internal/testprotos/enums"; | ||
|
||
enum Enum { | ||
DEFAULT = 1337; | ||
ZERO = 0; | ||
ONE = 1; | ||
ELEVENT = 11; | ||
SEVENTEEN = 17; | ||
THIRTYSEVEN = 37; | ||
SIXTYSEVEN = 67; | ||
NEGATIVE = -1; | ||
} |
Oops, something went wrong.