use constant DEBUG => 0; ... perform_some_debugging_operation() if DEBUG; ...