Subject: | [PATCH] Documention for ensure_class_found to warn about @INC coderef issue. |
Documention patch.
Subject: | 0001-POD-Note-that-ensure_class_found-is-incompatible.patch |
From f18d8c62474ab326fd9bcff0509c50aaa232b658 Mon Sep 17 00:00:00 2001
From: Toby Corkindale <tobyc@strategicdata.com.au>
Date: Thu, 5 Feb 2009 11:49:05 +1100
Subject: [PATCH] POD - Note that ensure_class_found() is incompatible with coderefs in @INC,
and thus potentially troublesome when used with PAR.
Signed-off-by: Toby Corkindale <tobyc@strategicdata.com.au>
---
lib/Class/C3/Componentised.pm | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/lib/Class/C3/Componentised.pm b/lib/Class/C3/Componentised.pm
index ed0ac41..7d28416 100755
--- a/lib/Class/C3/Componentised.pm
+++ b/lib/Class/C3/Componentised.pm
@@ -136,7 +136,12 @@ sub ensure_class_loaded {
=head2 ensure_class_found
Returns true if the specified class is installed or already loaded, false
-otherwise
+otherwise.
+
+Note that the underlying mechanism (Class::Inspector->installed()) used by this
+sub will not, at the time of writing, correctly function when @INC includes
+coderefs. Since PAR relies upon coderefs in @INC, this function should be
+avoided in modules that are likely to be included within a PAR.
=cut
--
1.5.6.5