reflect/protoreflect: rename methods with Type suffix

The protobuf type system uses the word "descriptor" instead of "type".
We should avoid the "type" verbage when we aren't talking about Go types.
The old names are temporarily kept around for compatibility reasons.

Change-Id: Icc99c913528ead011f7a74aa8399d9c5ec6dc56e
Reviewed-on: https://go-review.googlesource.com/c/protobuf/+/172238
Reviewed-by: Herbie Ong <herbie@google.com>
Reviewed-by: Damien Neil <dneil@google.com>
diff --git a/internal/legacy/file_test.go b/internal/legacy/file_test.go
index 15dca7b..20e4aa2 100644
--- a/internal/legacy/file_test.go
+++ b/internal/legacy/file_test.go
@@ -431,7 +431,7 @@
 					case "HasJSONName":
 						// Ignore this since the semantics of the field has
 						// changed across protoc and protoc-gen-go releases.
-					case "OneofType", "ExtendedType", "EnumType", "MessageType":
+					case "Oneof", "Extendee", "Enum", "Message":
 						// Avoid descending into a dependency to avoid a cycle.
 						// Just record the full name if available.
 						//
@@ -440,6 +440,12 @@
 						if !v.IsNil() {
 							out[name] = v.Interface().(pref.Descriptor).FullName()
 						}
+					// TODO: Remove this when the methods are deleted.
+					case "OneofType", "ExtendedType", "EnumType", "MessageType":
+						v := m.Call(nil)[0]
+						if !v.IsNil() {
+							out[name] = v.Interface().(pref.Descriptor).FullName()
+						}
 					default:
 						out[name] = m.Call(nil)[0].Interface()
 					}