Subject: | [PATCH] Moose enum Warnings |
Hey,
A Moose update issues these warnings:
t/Simple/Document.t ..................... Passing a list of values to enum is deprecated. Enum values should be wrapped in an arrayref. at /home/zoffix/Desktop/Downloads/QW/Markdent/lib/Markdent/Types/Internal.pm line 77.
enum TableCellAlignment, qw( left right center );
should be
enum TableCellAlignment, [ qw( left right center ) ];
Attached patch fixes the issue.
--
Cheers,
ZZ [ https://metacpan.org/author/ZOFFIX ]
Subject: | enum-warning-patch.patch |
diff --git a/lib/Markdent/Types/Internal.pm b/lib/Markdent/Types/Internal.pm
index 01aa59e..daa1a62 100644
--- a/lib/Markdent/Types/Internal.pm
+++ b/lib/Markdent/Types/Internal.pm
@@ -74,7 +74,7 @@ subtype OutputStream,
},
message { 'The output stream must be a Perl file handle or an object with a print method' };
-enum TableCellAlignment, qw( left right center );
+enum TableCellAlignment, [ qw( left right center ) ];
subtype PosInt,
as Int,