all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Andreas Röhler" <andreas.roehler@easy-emacs.de>
To: "help-gnu-emacs@gnu.org List" <help-gnu-emacs@gnu.org>
Subject: Re: perl mode
Date: Wed, 02 Oct 2013 19:10:12 +0200	[thread overview]
Message-ID: <524C5374.8050400@easy-emacs.de> (raw)
In-Reply-To: <20131002050052.GA3387@messier31>

[-- Attachment #1: Type: text/plain, Size: 754 bytes --]

Am 02.10.2013 07:00, schrieb Philippe Delavalade:
> Hi all.
>
> it's my first post on this list, so be kind with my english :-)
>
> I have problems with indentation in perl mode when usign "$'" ; I guess it
> comes from the "'"...
>
> Here is a little example :
>
> #!/usr/bin/perl -w
>
> use strict;
>
> $\ = "\n";
> my $txt = 'Hello World !';
>
> main
> {
> if(1)
> {
> ($txt =~ m/Hello /) && (print "$'");
> }
> print "Bye";
> }
>
> exit(0);
>
> If I run the "indent-region" command (after having marked the whole
> script", identation is not correct.
>
> I suspect I should add some lines in .emacs but I don't know which are the
> right ones...
>
> Thanks in advance for help.
>

with cperl-mode indent-region default delivers this - see attachment

[-- Attachment #2: cperl.png --]
[-- Type: image/png, Size: 57537 bytes --]

  reply	other threads:[~2013-10-02 17:10 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-02  5:00 perl mode Philippe Delavalade
2013-10-02 17:10 ` Andreas Röhler [this message]
     [not found] <mailman.3253.1380707680.10748.help-gnu-emacs@gnu.org>
2013-10-02 12:06 ` Damien Wyart
2013-10-02 12:23   ` Philippe Delavalade
2013-10-02 16:41   ` Philippe Delavalade
     [not found]   ` <mailman.3268.1380732091.10748.help-gnu-emacs@gnu.org>
2013-10-02 17:14     ` Damien Wyart
2013-10-03 16:19       ` Philippe Delavalade
  -- strict thread matches above, loose matches on Subject: below --
2013-10-01 16:09 Philippe Delavalade
2013-10-04  2:46 ` Stefan Monnier
2013-10-04 11:22   ` Luca Ferrari
     [not found]   ` <mailman.3390.1380885764.10748.help-gnu-emacs@gnu.org>
2013-10-04 18:55     ` Damien Wyart
2002-05-08 19:27 Bingham, Jay
2002-05-08 17:24 Gabriel C Millerd

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=524C5374.8050400@easy-emacs.de \
    --to=andreas.roehler@easy-emacs.de \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.