1
2
3
|
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
|
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
|
#! /usr/bin/env tclsh
create fake interp with "if" defined to take both halves, "package" to determine stuff, and "source" as real -- all other commands noops
# create fake interp with "if" defined to take both halves, "package" to determine stuff, and "source"/"set"/"proc" as real -- all other commands noops
set keep {
source
set unset
namespace
proc
list
if
}
set interp [interp create]
$interp eval [list set keep $keep]
$interp eval {
namespace eval ::teaparty {}
rename if ::teaparty::if
proc package args {
}
proc if args {
}
}
|