September 10th, 2020

сто друзей

век живи, век учись

Variables beginning with underscore used to be forced into package main, but we decided it was more useful for package writers to be able to use leading underscore to indicate private variables and method names. However, variables and functions named with a single "_", such as $_ and "sub _", are still forced into the package "main".
=============

А я-то думаю, чего это &foo::_() говорит undefined. Любопытная особенность, документация когда-то читалась галопом по Европам, поэтому и не знал. Не зря я в своих модулях стараюсь делать sub __name.