This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Fix Emacs dir-local variables
authorAaron Crane <arc@cpan.org>
Mon, 7 Dec 2015 20:13:08 +0000 (20:13 +0000)
committerAaron Crane <arc@cpan.org>
Mon, 7 Dec 2015 20:13:08 +0000 (20:13 +0000)
The setting for cperl-indent-level (which sets the default indentation step
used by Emacs for Perl code) was missing a dot in the relevant cons pair.
This meant that the value set was the single-element list (4) rather than
the integer 4, so attempting to indent lines made Emacs produce an error
"Wrong type argument: number-or-marker-p, (4)".

.dir-locals.el

index 9e118b6..cf0c842 100644 (file)
@@ -1,5 +1,5 @@
 ;; Default settings for all except cpan/
 ((nil . ((indent-tabs-mode . nil)))    ; all modes
- (cperl-mode . ((cperl-indent-level 4)))
+ (cperl-mode . ((cperl-indent-level 4)))
  (c-mode . ((c-indentation-style . bsd)
             (c-basic-offset . 4))))