Windows treats Constant.pm as being the same file as constant.pm, that is, you can't have both at the same time in the same directory.
Renaming Constant.pm to constant.pm changes nothing. In both cases the error references the lowercase file.
In reply to Re^3: Bareword error in WWW::Mechanize
by Old_Hat
in thread WWW::Mechanize “use constant xx” gets bareword error
by Old_Hat
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |