You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: descriptor.go
    path of file: ./repos/sealer/vendor/github.com/gogo/protobuf/protoc-gen-gogo/descriptor
    
    the code of the file until where you have to start completion: // Go support for Protocol Buffers - Google's data interchange format
//
// Copyright 2016 The Go Authors.  All rights reserved.
// https://github.com/golang/protobuf
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
//     * Redistributions of source code must retain the above copyright
// notice
    
func (field *FieldDescriptorProto) IsScalar() bool {
	if field.Type == nil {
		return false
	}
	switch *field.Type {
	case FieldDescriptorProto_TYPE_DOUBLE,
		FieldDescriptorProto_TYPE_FLOAT,
		FieldDescriptorProto_TYPE_INT64,
		FieldDescriptorProto_TYPE_UINT64,
		FieldDescriptorProto_TYPE_INT32,
		FieldDescriptorProto_TYPE_FIXED64,
		FieldDescriptorProto_TYPE_FIXED32,
		FieldDescriptorProto_TYPE_BOOL,
		FieldDescriptorProto_TYPE_UINT32,
		FieldDescriptorProto_TYPE_ENUM,
		FieldDescriptorProto_TYPE_SFIXED32,
		FieldDescriptorProto_TYPE_SFIXED64,
		FieldDescriptorProto_TYPE_SINT32,
		FieldDescriptorProto_TYPE_SINT64:
		return true
	default:
		return false
	}
}