Itcl - the [incr Tcl] extension

Check-in [c191d69522]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:new test illustrating bug [777ae99cfb]
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | sebres-on-dmnd-resolver-perf-branch
Files: files | file ages | folders
SHA3-256: c191d695225f6c2d273aa830c49c0d632c5b1a9b7fe35f2fbf6f8f31ddae5682
User & Date: sebres 2019-11-04 17:42:53.202
Context
2019-11-04
20:28
fixes [777ae99cfb]: previous var-lookup in class body (in ::itcl::parser) could obtain inherited common vars, be sure it does not exists after new uninitialized common creation; more test cases covering corner cases; remove unneeded calls of Itcl_BuildVirtualTables, since resolveVars is build on demand (moved to ItclResolveVarEntry). check-in: 6c5eb55b81 user: sebres tags: sebres-on-dmnd-resolver-perf-branch
17:42
new test illustrating bug [777ae99cfb] check-in: c191d69522 user: sebres tags: sebres-on-dmnd-resolver-perf-branch
2019-10-15
13:02
merge trunk (and integrated sebres-memopt-perf-branch) check-in: 635fe4b82e user: sebres tags: sebres-on-dmnd-resolver-perf-branch
Changes
Unified Diff Ignore Whitespace Patch
Changes to tests/basic.test.
534
535
536
537
538
539
540




















541
542
543
544
545
546
547
    test_arrays0 do array names undefined
} -result {}

test basic-6.8 {common variables can be redefined
} -body {
    test_arrays0 do set undefined "scalar"
} -result {scalar}





















if {[namespace which test_arrays] ne {}} {
    ::itcl::delete class test_arrays
}
check_itcl_basic_errors
rename check_itcl_basic_errors {}








>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
    test_arrays0 do array names undefined
} -result {}

test basic-6.8 {common variables can be redefined
} -body {
    test_arrays0 do set undefined "scalar"
} -result {scalar}

test basic-7.1 {variable lookup before a common creation (bug [777ae99cfb])} -body {
    itcl::class A {
	private common cv "A::cv"
	public proc cv {} {set cv}
    }
    itcl::class B {
	inherit A
	public common res {}
	lappend res [info exists cv]
	#private common cv "B::cv"
	private common cv
	lappend cv "B::cv-add"
	public proc cv {} {set cv}
    }
    lappend B::res [A::cv] [B::cv]
    set B::res
} -result {0 A::cv B::cv-add} -cleanup {
    itcl::delete class B A
}

if {[namespace which test_arrays] ne {}} {
    ::itcl::delete class test_arrays
}
check_itcl_basic_errors
rename check_itcl_basic_errors {}