Update docs to mention the proto3 API differences. Fixes #15.
diff --git a/README.md b/README.md index fa4883f..12b39c3 100644 --- a/README.md +++ b/README.md
@@ -101,6 +101,12 @@ with distinguished wrapper types for each possible field value. - Marshal and Unmarshal are functions to encode and decode the wire format. +When the .proto file specifies `syntax="proto3"`, there are some differences: + + - Non-repeated fields of non-message type are values instead of pointers. + - Getters are only generated for message and oneof fields. + - Enum types do not get an Enum method. + Consider file test.proto, containing ```proto
diff --git a/proto/lib.go b/proto/lib.go index dcabe3b..6837512 100644 --- a/proto/lib.go +++ b/proto/lib.go
@@ -70,6 +70,12 @@ with distinguished wrapper types for each possible field value. - Marshal and Unmarshal are functions to encode and decode the wire format. +When the .proto file specifies `syntax="proto3"`, there are some differences: + + - Non-repeated fields of non-message type are values instead of pointers. + - Getters are only generated for message and oneof fields. + - Enum types do not get an Enum method. + The simplest way to describe this is to see an example. Given file test.proto, containing