• Noam Postavsky's avatar
    Improve ffap-gopher-at-point handling of long lines · fd6b829d
    Noam Postavsky authored
    * lisp/ffap.el (ffap-gopher-regexp): Only match the KEY part.  Note
    setting to nil is now supported.
    (ffap--gopher-var-on-line): New function.
    (ffap-gopher-at-point): Use it instead of the old ffap-gopher-regexp
    which could overflow the regexp stack on long lines (Bug#25391).  Use
    `let-alist' instead of calling `set' on local variables.
    * test/lisp/ffap-tests.el (ffap-gopher-at-point): New test.
    fd6b829d
ffap-tests.el 2.24 KB