On Fri, 11 Aug 2000 02:38:24 -0700, Nathan Wiger wrote:

>The problem with this is that they rely on the indirect object notation,
>same as new(). So:
>
>   import Module;     # calls Module->import
>   new Module;        # calls Module->new
>   bob Module;        # calls Module->bob
>  
>So import and unimport aren't really special functions. In fact, there's
>nothing special about import, except that "use" automatically calls it.

Look at perltie. All ordinary subs, or methods, except that tied objects
automatically invoke oone of them when accessed. That is precisely the
point: the convention of the upper case name indicates that they
probably will be called automatically. "import" does not adhere to that
convention.

p.s. if you misspell "CLOSE" as "CLOS", for example, it won't be called.
As I said: an ordinary sub.

-- 
        Bart.

Reply via email to