in reply to Depricated Features of the Language

Dynamic scoping is seriously deprecated in my book. The reference here is not to local $/ = undef; or somesuch but to dynamic scoping, which is very scary. Don't always assume that a module author knows what he is doing. In this case it is a legacy app, not a CPAN module.

I've seen some scary code out there that uses local in all the wrong ways. That is what I'm talking about! hint: you won't see use strict in their code anywhere.

It gives Perl a bad name

So, has anyone seen uselocal "Some::Module";?

  • Comment on Re: Depricated Features of the Language

Replies are listed 'Best First'.
RE: Re: Depricated Features of the Language
by davorg (Chancellor) on Oct 18, 2000 at 12:04 UTC

    So, has anyone seen uselocal "Some::Module";?

    IIRC it's part of InterShop, the ecommerce package and it doesn't actually do anything with scoping, it's just a function that they include which adds their module libraries to @INC before using the module.

    Been some time since I used it tho' so I could be misremembering.

    --
    <http://www.dave.org.uk>

    "Perl makes the fun jobs fun
    and the boring jobs bearable" - me

      Yes,

      That's it! I'm going to get into the app tomorrow. Whoever wrote these extensions sure used dynamic scoping, plug in whatever big name publicly traded consulting firm you choose, tsk, tsk!

      And these are the same people who are pushing Java! No wonder, their Perl is so wretched. Thanks for quelling my bad dream.

      "what if a demon were come into your dream and whisper into your ear that every thing you've lived you'll have to relive again and again" -apologies to nietzsche