Skip to content

Commit 90e67cf

Browse files
author
Roman Bataev
committed
v0.15.2
1 parent 19d39d8 commit 90e67cf

File tree

4 files changed

+10
-3
lines changed

4 files changed

+10
-3
lines changed

core/ns.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,12 @@ func (ns *Namespace) ReferAll(other *Namespace) {
100100
}
101101
}
102102

103+
func (ns *Namespace) InternFake(sym Symbol) *Var {
104+
vr := ns.Intern(sym)
105+
vr.isFake = true
106+
return vr
107+
}
108+
103109
func (ns *Namespace) Intern(sym Symbol) *Var {
104110
if sym.ns != nil {
105111
panic(RT.NewError("Can't intern namespace-qualified symbol " + sym.ToString(false)))

core/object.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,7 @@ type (
145145
isDynamic bool
146146
isUsed bool
147147
isGloballyUsed bool
148+
isFake bool
148149
taggedType *Type
149150
}
150151
ProcFn func([]Object) Object

core/parse.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1426,7 +1426,7 @@ func isUnknownCallable(expr Expr) (bool, Seq) {
14261426
if c.vr.expr != nil {
14271427
return false, nil
14281428
}
1429-
if sym.ns == nil && c.vr.ns != GLOBAL_ENV.CoreNamespace {
1429+
if sym.ns == nil && c.vr.isFake && c.vr.ns != GLOBAL_ENV.CoreNamespace {
14301430
return true, nil
14311431
}
14321432
}
@@ -1696,7 +1696,7 @@ func InternFakeSymbol(ns *Namespace, sym Symbol) *Var {
16961696
ns: nil,
16971697
name: STRINGS.Intern(sym.ToString(false)),
16981698
}
1699-
return GLOBAL_ENV.CurrentNamespace().Intern(fakeSym)
1699+
return GLOBAL_ENV.CurrentNamespace().InternFake(fakeSym)
17001700
}
17011701

17021702
func isInteropSymbol(sym Symbol) bool {

core/procs.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ const (
3737
PRINT_IF_NOT_NIL
3838
)
3939

40-
const VERSION = "v0.15.1"
40+
const VERSION = "v0.15.2"
4141

4242
const (
4343
CLJ Dialect = iota

0 commit comments

Comments
 (0)