Following up to myself, I just had an idea about expanding the typed
interface:
On Tue, Jan 24, 2006 at 12:26:30PM -0800, Chip Salzenberg wrote:
> The Perl namespace's typed interface will have to figure out what kind of
> variable it thinks it's getting. That decision could be fairly arbitrary,
> but users will adapt to whatever decision it tends to make.
The more I think about this, the less I like it.
It would be good for the typed interface to _allow_ an exporter to specify
more precisely what kind of variable it has, if it knows. For example:
add_scalar(STRING, PMC*)
add_array(STRING, PMC*)
add_hash(STRING, PMC*)
these would be defined to default to simply add_var(), but Perl namespaces
would implement them to do the obvious (prepending '$', '@', and '%',
respectively).
I'm less sure about the value of find_{scalar,array_hash}, but they'd be
cheap to write, and consistency is a Good Thing.
/me keeps thinking
--
Chip Salzenberg <[EMAIL PROTECTED]>