The following module was proposed for inclusion in the Module List:

  modid:       Tie::WarnGlobal
  DSLIP:       adpr?
  description: Ties variables to functions, warns on use
  userid:      STEPHEN (Stephen Nelson)
  chapterid:    6 (Data_Type_Utilities)
  communities:
    www.perlmonks.org

  similar:
    Tie::Watch

  rationale:

    (Reposting because I didn't see it appear in the archives, sorry if
    duplicate)

    Many programmers agree that in large projects, globals are a Bad
    Thing. Faced with a global $FOO, it's frequently a good idea to
    create a FOO() constant or a get_foo() function. However, replacing
    $FOO with get_foo() can be a problem. One can't really know until
    after the event whether one wrote get_foo() correctly. Plus, finding
    all instances of $FOO, or references to $FOO, can be a complete
    nightmare.

    Tie::WarnGlobal is designed to fix that. One can tie a variable to
    get_*() and set_*() functions. Whenever the variable is read to or
    written from, a warning is printed.

    The most similar class on CPAN is Tie::Watch. Tie::Watch is very
    flexible, making it possible to set up many different kinds of
    callbacks. Tie::WarnGlobal's interface is aimed at a more specific
    refactoring process.

  enteredby:   STEPHEN (Stephen Nelson)
  enteredon:   Tue May  8 18:56:10 2001 GMT

The resulting entry would be:

Tie::
::WarnGlobal      adpr ?                                            Ties variables to 
:functions, warns on use


Thanks for registering,
The Pause Team

PS: The following links are only valid for module list maintainers:

Registration form with editing capabilities:
  
https://pause.perl.org/pause/authenquery?ACTION=add_mod&USERID=63000000_c2e6b986d3fdda00&SUBMIT_pause99_add_mod_preview=1
Immediate (one click) registration:
  
https://pause.perl.org/pause/authenquery?ACTION=add_mod&USERID=63000000_c2e6b986d3fdda00&SUBMIT_pause99_add_mod_insertit=1

Reply via email to