about summary refs log tree commit diff
path: root/pkg/lang/compiler/scope/symbol.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/lang/compiler/scope/symbol.go')
-rw-r--r--pkg/lang/compiler/scope/symbol.go21
1 files changed, 2 insertions, 19 deletions
diff --git a/pkg/lang/compiler/scope/symbol.go b/pkg/lang/compiler/scope/symbol.go
index df91899..3b50108 100644
--- a/pkg/lang/compiler/scope/symbol.go
+++ b/pkg/lang/compiler/scope/symbol.go
@@ -1,7 +1,5 @@
 package scope
 
-import "jinx/pkg/lang/vm/code"
-
 type SymbolID struct {
 	symbolKind   SymbolKind
 	scopeID      ScopeID
@@ -15,16 +13,14 @@ func (id SymbolID) SymbolKind() SymbolKind {
 type SymbolKind int
 
 const (
+	// A variable symbol is bound to a local on the stack.
 	SymbolKindVariable SymbolKind = iota
-	SymbolKindFunction
 )
 
 func (s SymbolKind) String() string {
 	switch s {
 	case SymbolKindVariable:
 		return "variable"
-	case SymbolKindFunction:
-		return "function"
 	default:
 		panic("unknown symbol kind")
 	}
@@ -40,7 +36,7 @@ func (s Symbol[D]) Data() D {
 }
 
 type SymbolData interface {
-	SymbolVariable | SymbolFunction
+	SymbolVariable
 }
 
 type SymbolVariable struct {
@@ -50,16 +46,3 @@ type SymbolVariable struct {
 func (sv SymbolVariable) LocalIndex() int {
 	return sv.localIndex
 }
-
-type SymbolFunction struct {
-	marker code.Marker
-	args   uint
-}
-
-func (sf SymbolFunction) Marker() code.Marker {
-	return sf.marker
-}
-
-func (sf SymbolFunction) Args() uint {
-	return sf.args
-}