diff options
author | Nathan Dench <ndenc2@gmail.com> | 2019-05-24 15:16:44 +1000 |
---|---|---|
committer | Nathan Dench <ndenc2@gmail.com> | 2019-05-24 15:16:44 +1000 |
commit | 107c1cdb09c575aa2f61d97f48d8587eb6bada4c (patch) | |
tree | ca7d008643efc555c388baeaf1d986e0b6b3e28c /vendor/github.com/golang/protobuf/proto/lib.go | |
parent | 844b5a68d8af4791755b8f0ad293cc99f5959183 (diff) | |
download | terraform-provider-statuscake-107c1cdb09c575aa2f61d97f48d8587eb6bada4c.tar.gz terraform-provider-statuscake-107c1cdb09c575aa2f61d97f48d8587eb6bada4c.tar.zst terraform-provider-statuscake-107c1cdb09c575aa2f61d97f48d8587eb6bada4c.zip |
Upgrade to 0.12
Diffstat (limited to 'vendor/github.com/golang/protobuf/proto/lib.go')
-rw-r--r-- | vendor/github.com/golang/protobuf/proto/lib.go | 38 |
1 files changed, 12 insertions, 26 deletions
diff --git a/vendor/github.com/golang/protobuf/proto/lib.go b/vendor/github.com/golang/protobuf/proto/lib.go index 75565cc..fdd328b 100644 --- a/vendor/github.com/golang/protobuf/proto/lib.go +++ b/vendor/github.com/golang/protobuf/proto/lib.go | |||
@@ -341,26 +341,6 @@ type Message interface { | |||
341 | ProtoMessage() | 341 | ProtoMessage() |
342 | } | 342 | } |
343 | 343 | ||
344 | // Stats records allocation details about the protocol buffer encoders | ||
345 | // and decoders. Useful for tuning the library itself. | ||
346 | type Stats struct { | ||
347 | Emalloc uint64 // mallocs in encode | ||
348 | Dmalloc uint64 // mallocs in decode | ||
349 | Encode uint64 // number of encodes | ||
350 | Decode uint64 // number of decodes | ||
351 | Chit uint64 // number of cache hits | ||
352 | Cmiss uint64 // number of cache misses | ||
353 | Size uint64 // number of sizes | ||
354 | } | ||
355 | |||
356 | // Set to true to enable stats collection. | ||
357 | const collectStats = false | ||
358 | |||
359 | var stats Stats | ||
360 | |||
361 | // GetStats returns a copy of the global Stats structure. | ||
362 | func GetStats() Stats { return stats } | ||
363 | |||
364 | // A Buffer is a buffer manager for marshaling and unmarshaling | 344 | // A Buffer is a buffer manager for marshaling and unmarshaling |
365 | // protocol buffers. It may be reused between invocations to | 345 | // protocol buffers. It may be reused between invocations to |
366 | // reduce memory usage. It is not necessary to use a Buffer; | 346 | // reduce memory usage. It is not necessary to use a Buffer; |
@@ -960,13 +940,19 @@ func isProto3Zero(v reflect.Value) bool { | |||
960 | return false | 940 | return false |
961 | } | 941 | } |
962 | 942 | ||
963 | // ProtoPackageIsVersion2 is referenced from generated protocol buffer files | 943 | const ( |
964 | // to assert that that code is compatible with this version of the proto package. | 944 | // ProtoPackageIsVersion3 is referenced from generated protocol buffer files |
965 | const ProtoPackageIsVersion2 = true | 945 | // to assert that that code is compatible with this version of the proto package. |
946 | ProtoPackageIsVersion3 = true | ||
947 | |||
948 | // ProtoPackageIsVersion2 is referenced from generated protocol buffer files | ||
949 | // to assert that that code is compatible with this version of the proto package. | ||
950 | ProtoPackageIsVersion2 = true | ||
966 | 951 | ||
967 | // ProtoPackageIsVersion1 is referenced from generated protocol buffer files | 952 | // ProtoPackageIsVersion1 is referenced from generated protocol buffer files |
968 | // to assert that that code is compatible with this version of the proto package. | 953 | // to assert that that code is compatible with this version of the proto package. |
969 | const ProtoPackageIsVersion1 = true | 954 | ProtoPackageIsVersion1 = true |
955 | ) | ||
970 | 956 | ||
971 | // InternalMessageInfo is a type used internally by generated .pb.go files. | 957 | // InternalMessageInfo is a type used internally by generated .pb.go files. |
972 | // This type is not intended to be used by non-generated code. | 958 | // This type is not intended to be used by non-generated code. |