in reply to Re: "Dynamic" dispatch tables
in thread "Dynamic" dispatch tables

You're right, I'm not sure yet if I really need a hash. I'll have to figure out some of the details.

I also already started using the "not exists" part, but running into a problem with that: I want to move the setup of the dispatch table / array into a module, but in the module the "exists &{"tcid_$_"} always fails as the sub is not defined in this module. Is there a good workaround for this?

Replies are listed 'Best First'.
Re^3: "Dynamic" dispatch tables
by Tanktalus (Canon) on Apr 29, 2011 at 20:55 UTC
    Yes. What package will they be in? If they'll be in the Foo package, then just use exists &{"Foo::tcid_$_"} instead. :-)
      They won't be in any package, but in the .pl script. I got it to work by using "main::", thanks for the hint.