in reply to Re: Rethinking Your Program's If-Thens
in thread Rethinking Your Program's If-Thens
Also a gotcha, this function will work in a module and may not when buried in the body of your program because %map isn't yet populated. Solutions: put a BEGIN in front of the start of your block, be aware of the limitation, or put a check in division_service that populates %map if it isn't populated yet.
And style points. I don't like &{...}() as much as (...)->(). Also I don't know what I think of your cute trick with putting the error check inside the dereference rather than doing a traditional exists test.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Rethinking Your Program's If-Thens
by Aristotle (Chancellor) on Oct 12, 2002 at 18:15 UTC | |
by Anonymous Monk on Oct 12, 2002 at 19:06 UTC |