|
2001-04-06
| ||
| 02:08 | • Ticket [218637ffff] auto_mkindex broken status still Closed with 3 other cha... artifact: e677b58606 user: dgp | |
|
2000-10-26
| ||
| 08:26 | • Closed ticket [218637ffff]. artifact: 225de40e23 user: welch | |
| 01:03 | • New ticket [218637ffff]. artifact: c714227d42 user: nobody | |
auto_mkindex broken
Closed / Fixed218637ffffffffffffffffffffffffffffffffffCreated 26 years agoUpdated 26 years ago
Descriptionplain2000-10-26 01:03:31
OriginalBugID: 1549 Bug
Version: 8.0.5
SubmitDate: '1999-03-19'
LastModified: '2000-02-01'
Severity: CRIT
Status: Released
Submitter: pat
ChangedBy: ericm
RelatedBugIDs: 1115 1481 1558 1559
OS: All
FixedDate: '2000-02-01'
FixedInVersion: 8.1.1
ClosedDate: '2000-10-25'
Name:
Chad Smith
ReproducibleScript:
Type the following class definition into a file called foo.itcl:
class Foo {
method blit {} {}
method blot {} {}
}
Now run itclsh3.0 (this is itcl3.0.1 with tcl8.0.5):
> itclsh3.0
% auto_mkindex . foo.itcl
no value given for parameter "body" to "_%@fake_itcl_class"
Here's what I've found looking into it (the order of proc calls in
init.tcl):
- auto_mkindex
- auto_mkindex_parser::init
- auto_mkindex_parser::commandInit
- auto_mkindex_parser::_%@fake_proc
- auto_mkindex_parser::commandInit
- ::auto_mkindex_parser::_%@fake_namespace
- ... pairs of commandInit and the aliased procs
- ...
- auto_mkindex_parser::mkindex
--> $parser eval $contents (BARFS OUT HERE)
ObservedBehavior:
I can't use this version if auto_mkindex doesn't work.
Again, the error message is:
no value given for parameter "body" to "_%@fake_itcl_class"
DesiredBehavior:
obvious
==================
Name: Robert Seeger
email: [email protected]
Support: None
Severity: 1
OperatingSystem: Windows NT
OperatingSystemVersion: NT4.0 SP4
Extensions: Itcl3.0.1, BLT2.4h (not loaded at the time of the error), TclX8.0.5 (also not loaded), Sybtcl 2.5 (also not loaded), Scotty 3.0.0 (also not loaded)
CustomShell: No patches. All I did was recompile the sources that come with TclPro, and then added the various extensions. All extensions were created as dynamic.
Synopsis: auto_mkindex does not work with Itcl classes on NT
ReproducibleScript:
########### File 1: make_index ################
package require Itcl
auto_mkindex testfiles/*.itcl
########### End file one ######################
########### File 2: testfiles/aclass.itcl #####
itcl::class testme {
public variable avar
constructor {} {
dosomething
}
}
########### End File 2 ##################
This should work. The basic idea is to try to do an auto_mkindex with
files that contain itcl::class commands. It crashes with the error shown
below below
ObservedBehavior:
no value given for parameter "arglist" to "_%@fake_itcl_body"
invoked from within
"_%@fake_itcl_body $args"
("eval" body line 1)
invoked from within
"_%@eval _%@fake_itcl_body {$args}"
(procedure "itcl::body" line 1)
invoked from within
"itcl::body baynet::Reporter::report args {
incr linenumber
output "[perc_subst \${prefix}][lindex \$args 0]"
foreach elem [lrange \$args 1 end..."
invoked from within
"$parser eval $contents"
(procedure "auto_mkindex_parser::mkindex" line 25)
invoked from within
"auto_mkindex_parser::mkindex $file"
(procedure "auto_mkindex" line 21)
invoked from within
"auto_mkindex $dirname *.tcl *.itcl *.tk *.itk"
This is obviously from a different file than shown in the above code
snippet. However, since so many people have seen this problem, I figured
you could duplicate it. I have included what I have been able to figure
out below. . .
When the parser enters the following function:
########### Begin code snippet ################
proc ::auto_mkindex_parser::_%@fake_itcl_class {name body} {
variable index
variable scriptFile
append index "set [list auto_index([fullname $name])]"
append index " \[list source \[file join \$dir [list
$scriptFile]\]\]\n"
variable parser
variable contextStack
set contextStack [linsert $contextStack 0 $name]
$parser eval $body
set contextStack [lrange $contextStack 1 end]
}
########### End code snippet #####################
The variable 'name' is set to the following:
############## Begin value ########################
SnmpDevice {
<snip out entire class definition>
}
################ End value #####################
Thus, it would seem it is passing the whole class declaration into the
fake_class thing as the name of the class, instead of just the actual
name. Unfortunately, I have no idea how to go about fixing this. I'm
going to send it along to the TclPro bug report site, and see what they
say.
DesiredBehavior:
A proper tclIndex file should be created, including entries for the
various classes in the files.
05/04/1999 19:50 - foster: changed product & version from itcl 3.0 to Tcl 8.0.5.
per Pat, this bug has a wide effect and needs to be fixed in 8.1.1 to suppport itcl.
05/09/1999 23:00 - foster - per Brent, suspects fixed in 8.1.
---------
This bug does not appear in 8.3. I'm not certain when it was fixed, but probably sometime around 8.1 when the auto indexer was overhauled.
- eric
-- 02/01/2000 ericm
welch Closed ticket [218637ffff].
[History diff]2000-10-26 08:26:09
dgp Ticket [218637ffff]: 3 changes
[History diff]2001-04-06 02:08:56
Log in (anonymous is fine) to add a comment.