1

インタラクティブなperlpdlシェルであるpdl2を使用していますが、後でインタラクティブセッションを確認できるように、次のコード行を文書化するためにコメントを行に追加したいと思います。

pdl> # this is a comment
Can't exec "this": No such file or directory at /homes/pmg/pmg-soft/local-perl/local-lib/lib/perl /x86_64-linux/PDL/Perldl2/Plugin/PDLCommands.pm line 51.

pdl2シェルにコメントを追加することは可能ですか?

PS:評判が1500の人はpdl2タグを追加できますか?

[アップデート]

OK、「#」は確かに私が思ったようにコメントの印章ですが、前にsp(またはsemething)を入れない限り、#で行を始めることはできないようです。?!それは「機能」ですか?

pdl> # d
Can't exec "d": No such file or directory at /homes/pmg/pmg-soft/local-perl/local-lib/lib/perl5/x86_64-linux/PDL/Perldl2/Plugin/PDLCommands.pm line 51.
pdl>  # d  # "note the space before the #"
pdl>
4

1 に答える 1

2

差出人perldoc perldl

  Shell variables
    Shell variables: (*Note*: if you don't like the defaults change them in
    ~/.perldlrc)

    *   $PERLDL::ESCAPE - default value '#'

        Any line starting with this character is treated as a shell escape.
        The default value is chosen because it escapes the code from the
        standard perl interpreter.

クイックアンドダーティアンサー:( # this is a comment先頭にスペースを付けて)使用する

于 2011-07-12T10:51:35.893 に答える