%PDF- <> %âãÏÓ endobj 2 0 obj <> endobj 3 0 obj <>/ExtGState<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI] >>/Annots[ 28 0 R 29 0 R] /MediaBox[ 0 0 595.5 842.25] /Contents 4 0 R/Group<>/Tabs/S>> endobj ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµùÕ5sLOšuY>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<> endobj 2 0 obj<>endobj 2 0 obj<>es 3 0 R>> endobj 2 0 obj<> ox[ 0.000000 0.000000 609.600000 935.600000]/Fi endobj 3 0 obj<> endobj 7 1 obj<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI]>>/Subtype/Form>> stream
;ELC ;;; Compiled ;;; in Emacs version 25.2.1 ;;; with all optimizations. ;;; This file uses dynamic docstrings, first added in Emacs 19.29. ;;; This file does not contain utf-8 non-ASCII characters, ;;; and so can be loaded in Emacs versions earlier than 23. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (byte-code "\300\301!\210\300\302!\210\303\304\305\"\207" [require ob comint add-to-list org-babel-tangle-lang-exts ("haskell" . "hs")] 3) (defvar org-babel-default-header-args:haskell '((:padlines . "no"))) (defvar org-babel-haskell-lhs2tex-command "lhs2tex") (defvar org-babel-haskell-eoe "\"org-babel-haskell-eoe\"") #@34 Execute a block of Haskell code. (defalias 'org-babel-execute:haskell #[(body params) "\306\307\"A\310\311\312\313\"\"\306\314\"A\315\f\316!#\317 \"\212\320 ?\321\216\322 !\2043 \323\324 \"\210 q\210\325\326\211@AB\327CBC\330\216\331\332p!!b\210`dD\211ED{AED|\210*\333 !c\210\334\326\335\"\210Fc\210\334\326\335\"\210Gb\210\212\336\337F!\326\335#\205\212 \336H\326\335#)\204\227 \340\332p!!\210\202t \331\332p!!b\210Ac\210) \203\301 \341\342\343\344\337 \206\261 \325!#B\"\203\301 B\345\225\326O@\346BH\".@\310\347F\350\310\333@\"!\235A\"I\351\352\353\"\203\357 \354\355\350IA!\343#\202\371 \352\356\"\205\371 I@J\306\357\"AK\360K\235?\205Y\361K\235\204P\362K\235\204P\363K\235\204P\364K\235\204P\365K\235\204P\366K\235\204I\367K\235\204I\370K\235\204I\371K\235\203U\372K\235\204UJ\202Y\373J!*\374\306\375\"A\306\375\"A\"\374\306\376\"A\306\376\"A\"#.\207" [params session vars result-type body full-body assoc :session mapcar cdr org-babel-get-header :var :result-type org-babel-expand-body:generic org-babel-variable-assignments:haskell org-babel-haskell-initiate-session match-data #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] org-babel-comint-buffer-livep error "Buffer %s does not exist or has no process" "" nil #[(text) " P\211\207" [string-buffer text] 2] #[nil "A\211\207" [comint-output-filter-functions] 2] process-mark get-buffer-process org-babel-trim comint-send-input t re-search-forward regexp-quote accept-process-output string-match replace-regexp-in-string "\n" "[ \n]+" 0 split-string org-babel-haskell-read-string reverse org-babel-reassemble-table eql output mapconcat identity value :result-params "none" "scalar" "verbatim" "html" "code" "pp" "output" "raw" "org" "drawer" "table" org-babel-haskell-table-or-string org-babel-pick-name :colname-names :rowname-names save-match-data-internal raw dangling-text string-buffer comint-output-filter-functions end start org-babel-haskell-eoe comint-last-input-end comint-prompt-regexp results result #1=#:--params] 9 (#$ . 730)]) #@41 Strip \"s from around a haskell string. (defalias 'org-babel-haskell-read-string #[(string) "\301\302\"\203\f \303\304\"\207\207" [string string-match "^\"\\([^ ]+\\)\"$" match-string 1] 3 (#$ . 2846)]) #@140 Initiate a haskell session. If there is not a current inferior-process-buffer in SESSION then create one. Return the initialized session. (defalias 'org-babel-haskell-initiate-session #[(&optional session params) "\301\302!\210\303\304!\206 \305 \306\216\307 \210\310\311!\210p*\207" [#1=#:wconfig require inf-haskell get-buffer "*haskell*" current-window-configuration #[nil "\301!\207" [#1# set-window-configuration] 2] run-haskell sleep-for 0.25] 2 (#$ . 3059)]) #@25 Load BODY into SESSION. (defalias 'org-babel-load-session:haskell #[(session body params) "\306 \307\216\310 \n\"\311\312!\313P\314\315!r q\210\316\216c\210\317\f!\210\320 \210\321 \210+,\207" [#1=#:wconfig session params buffer load-file #2=#:temp-buffer current-window-configuration #[nil "\301!\207" [#1# set-window-configuration] 2] org-babel-prep-session:haskell org-babel-temp-file "haskell-load-" ".hs" generate-new-buffer " *temp*" #[nil "\301!\205 \302!\207" [#2# buffer-name kill-buffer] 2] write-file haskell-mode inferior-haskell-load-file body] 3 (#$ . 3535)]) #@62 Prepare SESSION according to the header arguments in PARAMS. (defalias 'org-babel-prep-session:haskell #[(session params) "\305 \306\216\307 !\212\310 \311\216\312\n!\204 \313\314\n\"\210\nq\210\315\316\317\f!\"\210+p+\207" [#1=#:wconfig session buffer save-match-data-internal params current-window-configuration #[nil "\301!\207" [#1# set-window-configuration] 2] org-babel-haskell-initiate-session match-data #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] org-babel-comint-buffer-livep error "Buffer %s does not exist or has no process" mapc #[(line) "c\210\301\302\303\"\207" [line comint-send-input nil t] 3] org-babel-variable-assignments:haskell] 4 (#$ . 4126)]) #@68 Return list of haskell statements assigning the block's variables. (defalias 'org-babel-variable-assignments:haskell #[(params) "\301\302\301\303\304\305\"\"\"\207" [params mapcar #[(pair) "\301\302@\303A!#\207" [pair format "let %s = %s" org-babel-haskell-var-to-haskell] 5] cdr org-babel-get-header :var] 7 (#$ . 4840)]) #@167 Convert RESULTS to an Emacs-lisp table or string. If RESULTS look like a table, then convert them into an Emacs-lisp table, otherwise return the results as a string. (defalias 'org-babel-haskell-table-or-string #[(results) "\301!\207" [results org-babel-script-escape] 2 (#$ . 5173)]) #@156 Convert an elisp value VAR into a haskell variable. The elisp VAR is converted to a string of haskell source code specifying a variable of the same value. (defalias 'org-babel-haskell-var-to-haskell #[(var) "<\203 \301\302\303\304#\305Q\207\306\307\"\207" [var "[" mapconcat org-babel-haskell-var-to-haskell ", " "]" format "%S"] 5 (#$ . 5466)]) #@401 Export to a .lhs file with all haskell code blocks escaped. When called with a prefix argument the resulting .lhs file will be exported to a .tex file. This function will create two new files, base-name.lhs and base-name.tex where base-name is the name of the current org-mode file. Note that all standard Babel literate programming constructs (header arguments, no-web syntax etc...) are ignored. (defalias 'org-babel-haskell-export-to-lhs #[(&optional arg) "\306 \307\310\311 !\312\313!\211\314P\315P\n\316P8\n\315P9:\317\3208!\321\3209!\260;<=\322>\f\323\324\325!!?@\326\216r?q\210c\210eb\210\327 \322\330#\203\227 \331 A\332\216\333\334!G>*\335\331 A\336\216\337=\204y \340\341\333\342!\"\203 \333\343!\202\204 \344\333\343!!\345Q*\330\211#\210\346\347\224\347\225>#\210\202N )r?q\210\350\322\211@\322\347%\210,\212\351\352!\210\353\f!\210\322B\354\355 \"\210)\356\322!\210\357\f!\210\353 !\210eb\210\342y\210\360c\210\327\361\322\330#\203\352 \335\331 A\362\216\344\333\347!!*\330\211#\210\202\316 \306 \363 \210\356\322!\210)\357 !\2108\323\324\325!!CD\364\216rCq\210c\210)rCq\210\350\322\211D\322\347%\210,E\204*\3538!\2029\365\366;\"\210\367;!\210\3539!.\207" [contents haskell-regexp base-name tmp-file tmp-org-file tmp-tex-file buffer-string "^\\([ ]*\\)#\\+begin_src[ ]haskell*\\(.*\\)?[ \n]\\([^ ]*?\\)[ \n][ ]*#\\+end_src.*" file-name-sans-extension buffer-file-name org-babel-temp-file "haskell-" ".org" ".tex" ".lhs" " " org-babel-process-file-name " > " nil get-buffer-create generate-new-buffer-name " *temp file*" #[nil "\301!\205 \302!\207" [#1=#:temp-buffer buffer-name kill-buffer] 2] re-search-forward t match-data #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] match-string 1 replace-match #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] "#+begin_latex\n\\begin{code}\n" string-match "-i" 2 3 org-remove-indentation "\n\\end{code}\n#+end_latex\n" indent-code-rigidly 0 write-region require ox-latex find-file org-export-to-file latex kill-buffer delete-file "%include polycode.fmt\n" "^[ ]+\\\\begin{code}[^ ]+\\\\end{code}" #[nil "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3] save-buffer #[nil "\301!\205 \302!\207" [#2=#:temp-buffer buffer-name kill-buffer] 2] message "running %s" shell-command lhs-file tex-file org-babel-haskell-lhs2tex-command command org-src-preserve-indentation preserve-indentp indentation #1# #3=#:temp-file save-match-data-internal org-export-copy-to-kill-ring #2# #4=#:temp-file arg] 7 (#$ . 5823) "P"]) (provide 'ob-haskell)