2012-02-17 04:49:30 +00:00
|
|
|
// compile
|
2008-07-14 23:26:41 +00:00
|
|
|
|
|
|
|
// Copyright 2009 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.
|
|
|
|
|
2012-02-03 19:43:24 +00:00
|
|
|
package bug066
|
2008-07-14 23:26:41 +00:00
|
|
|
|
2009-01-20 22:40:40 +00:00
|
|
|
type Scope struct {
|
2008-12-19 11:05:37 +00:00
|
|
|
entries map[string] *Object;
|
2008-07-14 23:26:41 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2009-01-20 22:40:40 +00:00
|
|
|
type Type struct {
|
2008-07-14 23:26:41 +00:00
|
|
|
scope *Scope;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2009-01-20 22:40:40 +00:00
|
|
|
type Object struct {
|
2008-07-14 23:26:41 +00:00
|
|
|
typ *Type;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2009-01-20 22:40:40 +00:00
|
|
|
func Lookup(scope *Scope) *Object {
|
2008-07-14 23:26:41 +00:00
|
|
|
return scope.entries["foo"];
|
|
|
|
}
|