Skip to content

haskell-mode-find-def failing; additional quote characters needed; fix included #1856

Open

Description

@genovese

With recent versions of GHC, the :info name command returns a module name in quotes that are unicode characters (in particular x2018 ‘ and x2019 ’). The matching in haskell-mode-find-def only has the ASCII `' quotes.

In line 443 in the current HEAD

    (string-match "`\\(.+?\\):\\(.+?\\)'$" defined)

could be changed to

    (string-match "[`‘]\\(.+?\\):\\(.+?\\)['’]$" defined)

and in line 448 in the current HEAD

    (string-match "`\\(.+?\\)'$" defined))

could be changed to

    (string-match "[`‘]\\(.+?\\)['’]$" defined)

When making these changes only, haskell-mode-find-def now works, whereas before it returned nil.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions