Wiggins d'Anconia wrote:
> Peter Rabbitson wrote:
> 
[snip]
> 
> Either way there shouldn't be a need for eval unless you have raise
> error on, but in that case you should catch the exception with [EMAIL 
> PROTECTED]
> 
> http://danconia.org
> 
> 
>>Thanks for the feedback
>>
>>Peter
>>
> 
> 

Just as a side note... this is really a stylistic or idiomatic argument.
Syntactically or execution wise there is not anything technically wrong
with the code, that I saw. My argument stems completely from the "*it
seems* this is what The Perl Community/Tim Bunce intended" but that is
merely a guess based on the API, and the docs:

http://search.cpan.org/~timb/DBI-1.48/DBI.pm#RaiseError

And I am really only posing it as "feedback" as you requested rather
than a disagreement. I suspect from a readability/maintenance standpoint
as a fellow developer I would prefer the normal eval/if $@ idiom simply
because I would recognize it more readily than how you have it coded.

Having said that, I use my own wrapper module that throws my own brand
of exception, so I really use none of the idioms :-). But that is merely
a preference and I don't expect other developers to like/dislike it :-).

http://danconia.org

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to