File:  [parser3project] / parser3 / tests / 182.html
Revision 1.6: download - view: text, annotated - select for diffs - revision graph
Wed Feb 25 18:49:08 2026 UTC (3 months ago) by moko
Branches: MAIN
CVS tags: HEAD
test for array redefinition added

@main[]
$sDir[182_dir]
^use[$sDir/a1.p]
^use[$sDir/a2.p]

^^a:a1[]: ^a:a1[]
^^a:a2[]: ^a:a2[]
^^a:a3[]: ^a:a3[]
^^b:b1[]: ^b:b1[]

<hr />

# override 'a' class and add 'c' class
^use[182_dir/a3.p; $.replace(true) ]

$e[^try-catch{ ^use[182_dir/a5.p] }]
^e.match[(Comment:) .*?(a5.p)][]{$match.1 $match.2}

^^a:a1[]: ^a:a1[]
^^a:a2[]: ^try-catch{^a:a2[]}
^^b:b1[]: ^b:b1[]
^^c:c1[]: ^c:c1[]
^^c:c2[]: ^try-catch{^c:c2[]}

$list[^reflection:classes[]]
^list.at(-3)[key]
^list.at(-2)[key]
^list.at(-1)[key]

^use[182_dir/a7.p]
^array:is-user[]


E-mail: