<commit_before>;;; lang/haskell/config.el -*- lexical-binding: t; -*-

(cond ((featurep! +intero) (load! "+intero"))
      ((featurep! +dante)  (load! "+dante")))

;;
;; Common packages

(after! haskell-mode
  (setq haskell-process-suggest-remove-import-lines t  ; warnings for redundant imports etc
        haskell-process-auto-import-loaded-modules t)
  (when (featurep! :feature syntax-checker)
    (setq haskell-process-show-overlays nil))  ; flycheck makes this unnecessary
  (add-hook! 'haskell-mode-hook
    #'(subword-mode           ; improves text navigation with camelCase
       haskell-collapse-mode  ; support folding haskell code blocks
       interactive-haskell-mode))
  (set-lookup-handlers! 'haskell-mode :definition #'haskell-mode-jump-to-def-or-tag)
  (set-file-template! 'haskell-mode :trigger #'haskell-auto-insert-module-template :project t)
  (set-repl-handler! '(haskell-mode haskell-cabal-mode literate-haskell-mode) #'+haskell-repl-buffer)

  (add-to-list 'completion-ignored-extensions ".hi")

  (map! :localleader
        :map haskell-mode-map
        ;; this is set to use cabal for dante users and stack for intero users:
        "b" #'haskell-process-cabal-build
        "c" #'haskell-cabal-visit-file
        "h" #'haskell-hide-toggle
        "H" #'haskell-hide-toggle-all))<commit_msg>lang/haskell: disable subword-mode by default<commit_after>;;; lang/haskell/config.el -*- lexical-binding: t; -*-

(cond ((featurep! +intero) (load! "+intero"))
      ((featurep! +dante)  (load! "+dante")))

;;
;; Common packages

(after! haskell-mode
  (setq haskell-process-suggest-remove-import-lines t  ; warnings for redundant imports etc
        haskell-process-auto-import-loaded-modules t)
  (when (featurep! :feature syntax-checker)
    (setq haskell-process-show-overlays nil))  ; flycheck makes this unnecessary
  (add-hook! 'haskell-mode-hook
    #'(haskell-collapse-mode  ; support folding haskell code blocks
       interactive-haskell-mode))
  (set-lookup-handlers! 'haskell-mode :definition #'haskell-mode-jump-to-def-or-tag)
  (set-file-template! 'haskell-mode :trigger #'haskell-auto-insert-module-template :project t)
  (set-repl-handler! '(haskell-mode haskell-cabal-mode literate-haskell-mode) #'+haskell-repl-buffer)

  (add-to-list 'completion-ignored-extensions ".hi")

  (map! :localleader
        :map haskell-mode-map
        ;; this is set to use cabal for dante users and stack for intero users:
        "b" #'haskell-process-cabal-build
        "c" #'haskell-cabal-visit-file
        "h" #'haskell-hide-toggle
        "H" #'haskell-hide-toggle-all))
{'fraction_non_alphanumeric': 0.14819091608929946, 'fraction_numerical': 0.0, 'mean_word_length': 3.4965397923875434, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4415620', 'n_tokens_mistral': 953, 'n_tokens_neox': 899, 'n_words': 191}