From: Junio C Hamano <gitster@pobox.com>
To: Jakub Narebski <jnareb@gmail.com>
Cc: git@vger.kernel.org, "Petr Baudis" <pasky@suse.cz>,
"Alex Riesen" <raa.lkml@gmail.com>,
"Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Subject: Re: [1.8.0] perl/Git.pm: moving away from using Error.pm module
Date: Sun, 20 Feb 2011 23:20:42 -0800 [thread overview]
Message-ID: <7v4o7xluph.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <201102202346.36410.jnareb@gmail.com> (Jakub Narebski's message of "Sun\, 20 Feb 2011 23\:46\:33 +0100")
Jakub Narebski <jnareb@gmail.com> writes:
> Proposal:
>
> Replace use of Error.pm module in Git.pm with either Exception::Class
> based error class, or using 'carp'/'croak' from Carp, or both by adding
> an option to set error handler in 'Git' class (like e.g. in 'CHI'
> module on CPAN).
Personally, I was never a big fan of the syntax magic with Error.pm, but I
refrained from commenting on it as I am not heavily involved in that part
of the system. If we are going to change things so that everybody uses a
more traditional "eval {}; if ($@) { ... }", it would be a welcome change
from my point of view.
> Migration plan:
Do we even need one?
As far as an external caller is concerned, it would have been expecting us
to throw an exception by dying, and it wouldn't have mattered if it used
Error.pm or "eval { $call_to_Git_pm }; if ($@) {...}", I think.
next prev parent reply other threads:[~2011-02-21 7:21 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-20 22:46 [1.8.0] perl/Git.pm: moving away from using Error.pm module Jakub Narebski
2011-02-21 7:20 ` Junio C Hamano [this message]
2011-02-21 9:31 ` Jakub Narebski
2011-02-21 11:02 ` Nick
2011-02-21 12:12 ` Jakub Narebski
2011-02-21 12:31 ` Ævar Arnfjörð Bjarmason
2011-04-15 23:35 ` Avner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7v4o7xluph.fsf@alter.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=avarab@gmail.com \
--cc=git@vger.kernel.org \
--cc=jnareb@gmail.com \
--cc=pasky@suse.cz \
--cc=raa.lkml@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).