GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  PERL::CRITIC::POLICY::VALUESANDEXPRESSIONS::RESTRICTLONGSTRINGS (3)

.ds Aq ’

NAME

Perl::Critic::Policy::ValuesAndExpressions::RestrictLongStrings - Stop mixing long strings with code.

CONTENTS

AFFILIATION

This policy is part of Perl::Critic::More, a bleeding edge supplement to Perl::Critic.

DESCRIPTION

Long text strings in the middle of code is very distracting and wreaks havoc on code formatting. Consider putting long strings in external data files, __DATA__ sections, or in their own subroutines.

This policy complains if a long string is not the last line of a subroutine. Long is defined as 78 characters by default. This value can be altered in your Perl::Critic configuration via the max_length property. For example, you may add the following to your .perlcriticrc file:



  [ValuesAndExpressions::RestrictLongStrings]
  max_length = 50



TODO

Add option to allow long strings that don’t include newlines.

AUTHOR

Chris Dolan <cdolan@cpan.org>

COPYRIGHT

Copyright (c) 2006-2008 Chris Dolan

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. The full text of this license can be found in the LICENSE file included with this module.

Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 PERL::CRITIC::POLICY::VALUESANDEXPRESSIONS::RESTRICTLONGSTRINGS (3) 2016-04-03

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.