summaryrefslogtreecommitdiff
path: root/usr/gri/gosrc/object.go
blob: cf1a432aaafd0b27814a9225c8bf3a2367c3205d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
// 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.

package Object

import Globals "globals"


export BAD, CONST, TYPE, VAR, FUNC, PACKAGE
const /* kind */ (
	BAD = iota;  // error handling
	CONST; TYPE; VAR; FUNC; PACKAGE;
	PTYPE;  // primary type (import/export only)
)


type Object Globals.Object


func NewObject(kind int, name string) *Object {
	obj := new(Object);
	obj.mark = false;
	obj.kind = kind;
	obj.name = name;
	obj.type_ = nil;  // Universe::undef_t;
	obj.pnolev = 0;
	return obj;
}