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: named.go
    path of file: ./repos/gccrs/libgo/go/go/types
    
    the code of the file until where you have to start completion: // Copyright 2011 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package types

import (
	"go/token"
	"sync"
)

// A Named represents a named (defined) type.
type Named struct {
	check      *Checker
	obj        *TypeName      // corresponding declared object for declared types; placeholder for instantiated types
	orig       *Named         // original, uninstantiated type
	fromRHS    Type           // type (on RHS of declaration) this *Named type is derived of (for cycle reporting)
	underlying Type           // possibly a 
    
func (t *Named) cleanup() {
	// Ensure that every defined type created in the course of type-checking has
	// either non-*Named underlying, or is unresolved.
	//
	// This guarantees that we don't leak any types whose underlying is *Named,
	// because any unresolved instances will lazily compute their underlying by
	// substituting in the underlying of their origin. The origin must have
	// either been imported or type-checked and expanded here, and in either case
	// its underlying will be fully expanded.
	switch t.underlying.(type) {
	case nil:
		if t.resolver == nil {
			panic("nil underlying")
		}
	case *Named:
		t.under() // t.under may add entries to check.cleaners
	}
	t.check = nil
}