Xemacs perl compilation can't go to error position, by showing "Wrong type argument" error

67 Views Asked by At

After compilation of perl script I get syntax error in compilation window. If I try to use Goto Error Command, it not working and show error message:

Wrong type argument: listp, "^\\s-*\\(at \\(.*\\):\\([0-9]+\\)\)"

I use cperl 6.2 and xemacs 21.5.34.

1

There are 1 best solutions below

0
On

I change to GNU Emacs. How can I enable perl syntax check? I run cperl but syntax check is disabled?

CPerl's "Check syntax" menu item relies on something called mode-compile. If you don't have that installed it won't work. I've never used mode-compile, and can't offer much help there.

If you're going to be installing another package for syntax checking anyway, and assuming you're using GNU Emacs 24 or later, I suggest using the excellent Flycheck instead. Flycheck supports syntax checking for Perl as well as a huge number of other languages. In addition to regular syntax checking using the perl binary, Flycheck also supports syntax checking using Perl::Critic.

Flycheck is available via MELPA and MELPA stable. Once it is installed, add

(global-flycheck-mode)

to your configuration to enable Flycheck globally. If you've got perl on your path you should start getting syntax checking.