in reply to Re^3: Constant subroutine main::C redefined
in thread Constant subroutine main::C redefined
Also note that "redefining" a constant does not necessarily do what BrowserUk wants. The constants get inlined, so redefining them only works from that point on:
use constant C => 1; sub c { C }; use constant C => 2; sub d { C }; print c(); # 1 print d(); # 2
|
|---|