in reply to Re^2: Recognizing Perl in text
in thread Recognizing Perl in text

> It could be perl, but it could also be PHP

so what?

Of course it is Perl and PHP and what ever else, like the words "name","hand" and "finger" are German AND English (well modulo capitalization).

The OP didn't ask about distinguishing Perl from other languages, but from text.

Cheers Rolf

Replies are listed 'Best First'.
Re^4: Recognizing Perl in text
by girarde (Hermit) on Jan 06, 2011 at 20:12 UTC
    Be careful: so is 'Gift'. ;-)
Re^4: Recognizing Perl in text
by DrHyde (Prior) on Jan 07, 2011 at 10:27 UTC

    The person I was responding to said "I'd say all extracted lines which pass a syntax check with perl -c without error are per definition perl code". This is demonstrably false.

      LOL...

      This person didn't say (or mean) "exclusively perl code"!

      BTW it's also valid JS and Ruby code! :)

      Cheers Rolf

      UPDATE: this is the one instance of a doublepost which shouldn't be reaped. Sorry for the inconvenience! :)