encoding: switch ordering of Unmarshal arguments

While it is general convention that the receiver being mutated
is the first argument, the standard library specifically goes against
this convention when it comes to the Unmarshal function.

Switch the ordering of the Unmarshal function to match the Go stdlib.

Change-Id: I893346680233ef9fec7104415a54a0a7ae353378
Reviewed-on: https://go-review.googlesource.com/c/protobuf/+/177258
Reviewed-by: Damien Neil <dneil@google.com>
diff --git a/encoding/prototext/decode.go b/encoding/prototext/decode.go
index f9263bd..efc4c7a 100644
--- a/encoding/prototext/decode.go
+++ b/encoding/prototext/decode.go
@@ -20,8 +20,8 @@
 )
 
 // Unmarshal reads the given []byte into the given proto.Message.
-func Unmarshal(m proto.Message, b []byte) error {
-	return UnmarshalOptions{}.Unmarshal(m, b)
+func Unmarshal(b []byte, m proto.Message) error {
+	return UnmarshalOptions{}.Unmarshal(b, m)
 }
 
 // UnmarshalOptions is a configurable textproto format unmarshaler.
@@ -41,7 +41,7 @@
 
 // Unmarshal reads the given []byte and populates the given proto.Message using options in
 // UnmarshalOptions object.
-func (o UnmarshalOptions) Unmarshal(m proto.Message, b []byte) error {
+func (o UnmarshalOptions) Unmarshal(b []byte, m proto.Message) error {
 	var nerr errors.NonFatal
 
 	mr := m.ProtoReflect()