summaryrefslogtreecommitdiff
path: root/pp_sys.c
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2010-06-14 09:44:49 +0200
committerNicholas Clark <nick@ccl4.org>2010-06-14 09:44:49 +0200
commit086d291379a28ceb3cd7cc6416747be8c426476b (patch)
tree65cd76e65283592688e76e7f00528c3407c3ecff /pp_sys.c
parentf4adce6b773b2b6071e0d1627f4dce6ec0c3caa7 (diff)
downloadperl-086d291379a28ceb3cd7cc6416747be8c426476b.tar.gz
Note why pp_tie can't use call_method() for a package name.
Plus a test that would fail if it did.
Diffstat (limited to 'pp_sys.c')
-rw-r--r--pp_sys.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/pp_sys.c b/pp_sys.c
index 1dadea8949..a6d356e470 100644
--- a/pp_sys.c
+++ b/pp_sys.c
@@ -855,8 +855,10 @@ PP(pp_tie)
call_method(methname, G_SCALAR);
}
else {
- /* Not clear why we don't call call_method here too.
- * perhaps to get different error message ?
+ /* Can't use call_method here, else this: fileno FOO; tie @a, "FOO"
+ * will attempt to invoke IO::File::TIEARRAY, with (best case) the
+ * wrong error message, and worse case, supreme action at a distance.
+ * (Sorry obfuscation writers. You're not going to be given this one.)
*/
STRLEN len;
const char *name = SvPV_nomg_const(*MARK, len);