This commit allows &CORE::write to be called through references and
via ampersand syntax. No change to pp_enterwrite was necessary, as it
can already handle nulls.
case KEY_system:
case KEY_truncate: case KEY_unlink:
case KEY_unshift:
- case KEY_values: case KEY_write:
+ case KEY_values:
ampable = FALSE;
}
if (ampable) {
lis [&mywarn()], [1], '&warn retval in list context';
}
+test_proto 'write';
+$tests ++;
+eval {&mywrite};
+like $@, qr'^Undefined format "STDOUT" called',
+ "&write without arguments can handle the null";
+
# This is just a check to make sure we have tested everything. If we
# haven’t, then either the sub needs to be tested or the list in
# gv.c is wrong.