[Dancer-users] Dancer::MIME return value
sawyer x
xsawyerx at gmail.com
Mon Oct 31 16:02:28 CET 2011
I agree it shouldn't cause a problem, but that it should be fixed, because
it's non-standard and confuses newbies. :)
On Mon, Oct 31, 2011 at 4:47 PM, Naveed Massjouni <naveedm9 at gmail.com>wrote:
> On Mon, Oct 31, 2011 at 8:50 AM, sawyer x <xsawyerx at gmail.com> wrote:
> > This should indeed be fixed.
> >
> > Thank you!
> >
> > On Mon, Oct 31, 2011 at 2:44 PM, <thecrux at gmail.com> wrote:
> >>
> >> Hi.
> >>
> >> I had noticed that Dancer/MIME.pm (and also Dancer/Core/MIME.pm in
> >> Dancer2)
> >> return 42
> >> https://github.com/sukria/Dancer/blob/devel/lib/Dancer/MIME.pm#L67
> >>
> >> This is wrong, because generate warning
> >> $ perl -wce '42'
> >> Useless use of a constant (42) in void context at -e line 1.
> >> -e syntax OK
> >>
> >> Also, with `use warnings FATAL => 'all'` (default for Moo) returned
> error
> >>
> >> $ perl -c -Ilib lib/Dancer/Core/MIME.pm ; echo $?
> >> Useless use of a constant (42) in void context at
> lib/Dancer/Core/MIME.pm
> >> line 77.
> >> 255
> >>
>
> I don't understand. All modules are required to end with a true value.
> Usually, it is 1; but 42; should be fine. What am I missing?
> -Naveed
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.backup-manager.org/pipermail/dancer-users/attachments/20111031/56d03f2f/attachment.htm>
More information about the Dancer-users
mailing list