gisle / tcl.pm

Tcl extension module for Perl
http://search.cpan.org/dist/Tcl
9 stars 8 forks source link

Test `create_tcl_sub()` from multiple interpreters #53

Open chrstphrchvz opened 11 months ago

chrstphrchvz commented 11 months ago

This test currently fails due to #54:

1..3 todo 2;
# Running under perl version 5.036001 for darwin
# Current time local: Sun Aug 13 02:45:33 2023
# Current time GMT:   Sun Aug 13 07:45:33 2023
# Using Test.pm version 1.31
ok 1
# Tcl procedure '::perl::CODE(0x7fbeb281da10)' not found at t/createcmd2.t line 18.
not ok 2
# Test 2 got: <UNDEF> (t/createcmd2.t at line 24 *TODO*)
#   Expected: "foo"
#  t/createcmd2.t line 24 is: ok($cmd1result, 'foo');
ok 3
vadrer commented 11 months ago

Do I understand correctly that you want to create several interpreters, and that wasn't considered from the day 1? Nice idea. I don't see actual use-case though. Is it for the sake of completeness or you consider current Tcl__new function containing a bug? You can always create interpreters with pure-tcl approach, see "interp - Create and manipulate Tcl interpreters " documentation interp create ?-safe? ?--? ?path?