Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
1573 lines (1346 sloc) 155 KB
;ELC
;;; Compiled by smt@scott-taylors-macbook-pro.local on Sun Feb 1 01:41:11 2009
;;; from file /Users/smt/src/git/erlang_mode/erlang.el
;;; in Emacs version 22.3.1
;;; with all optimizations.
;;; This file uses dynamic docstrings, first added in Emacs 19.29.
(if (and (boundp 'emacs-version)
(< (aref emacs-version (1- (length emacs-version))) ?A)
(or (and (boundp 'epoch::version) epoch::version)
(string-lessp emacs-version "19.29")))
(error "`erlang.el' was compiled for Emacs 19.29 or later"))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
#@36 The version number of Erlang mode.
(defconst erlang-version "2.5.4" (#$ . 590))
#@185 The directory where the Erlang system is installed.
The name should not contain the trailing slash.
Should this variable be nil, no manual pages will show up in the
Erlang mode menu.
(defvar erlang-root-dir nil (#$ . 677))
#@295 *List of menu item list to combine to create Erlang mode menu.
External programs which temporarily add menu items to the Erlang mode
menu may use this variable. Please use the function `add-hook' to add
items.
Please call the function `erlang-menu-init' after every change to this
variable.
(defvar erlang-menu-items '(erlang-menu-base-items erlang-menu-skel-items erlang-menu-shell-items erlang-menu-compile-items erlang-menu-man-items erlang-menu-personal-items erlang-menu-version-items) (#$ . -908))
#@720 Description of menu used in Erlang mode.
This variable must be a list. The elements are either nil representing
a horizontal line or a list with two or three elements. The first is
the name of the menu item, the second is the function to call, or a
submenu, on the same same form as ITEMS. The third optional argument
is an expression which is evaluated every time the menu is displayed.
Should the expression evaluate to nil the menu item is ghosted.
Example:
'(("Func1" function-one)
("SubItem"
(("Yellow" function-yellow)
("Blue" function-blue)))
nil
("Region Function" spook-function midnight-variable))
Call the function `erlang-menu-init' after modifying this variable.
(defvar erlang-menu-base-items '(("Indent" (("Indent Line" erlang-indent-command) ("Indent Region " erlang-indent-region (if erlang-xemacs-p (mark) mark-active)) ("Indent Clause" erlang-indent-clause) ("Indent Function" erlang-indent-function) ("Indent Buffer" erlang-indent-current-buffer))) ("Edit" (("Fill Comment" erlang-fill-paragraph) ("Comment Region" comment-region (if erlang-xemacs-p (mark) mark-active)) ("Uncomment Region" erlang-uncomment-region (if erlang-xemacs-p (mark) mark-active)) nil ("Beginning of Function" erlang-beginning-of-function) ("End of Function" erlang-end-of-function) ("Mark Function" erlang-mark-function) nil ("Beginning of Clause" erlang-beginning-of-clause) ("End of Clause" erlang-end-of-clause) ("Mark Clause" erlang-mark-clause) nil ("New Clause" erlang-generate-new-clause) ("Clone Arguments" erlang-clone-arguments) nil ("Align Arrows" erlang-align-arrows))) ("Syntax Highlighting" (("Level 3" erlang-font-lock-level-3) ("Level 2" erlang-font-lock-level-2) ("Level 1" erlang-font-lock-level-1) ("Off" erlang-font-lock-level-0))) ("TAGS" (("Find Tag" find-tag) ("Find Next Tag" erlang-find-next-tag) ("Complete Word" erlang-complete-tag) ("Tags Apropos" tags-apropos) ("Search Files" tags-search)))) (#$ . 1422))
#@111 Description of the Shell menu used by Erlang mode.
Please see the documentation of `erlang-menu-base-items'.
(defvar erlang-menu-shell-items '(nil ("Shell" (("Start New Shell" erlang-shell) ("Display Shell" erlang-shell-display)))) (#$ . 3403))
#@113 Description of the Compile menu used by Erlang mode.
Please see the documentation of `erlang-menu-base-items'.
(defvar erlang-menu-compile-items '(("Compile" (("Compile Buffer" erlang-compile) ("Display Result" erlang-compile-display) ("Next Error" erlang-next-error)))) (#$ . 3656))
#@54 Description of the version menu used in Erlang mode.
(defvar erlang-menu-version-items '(nil ("Version" erlang-version)) (#$ . 3947))
#@140 Description of personal menu items used in Erlang mode.
Please see the variable `erlang-menu-base-items' for a description
of the format.
(defvar erlang-menu-personal-items nil (#$ . 4088))
#@190 The menu containing man pages.
The format of the menu should be compatible with `erlang-menu-base-items'.
This variable is added to the list of Erlang menus stored in
`erlang-menu-items'.
(defvar erlang-menu-man-items nil (#$ . 4286))
#@134 Description of the menu containing the skeleton entries.
The menu is in the form described by the variable `erlang-menu-base-items'.
(defvar erlang-menu-skel-items nil (#$ . 4529))
#@1370 *Functions to run when Erlang mode is activated.
This hook is used to change the behaviour of Erlang mode. It is
normally used by the user to personalise the programming environment.
When used in a site init file, it could be used to customise Erlang
mode for all users on the system.
The functions added to this hook are run every time Erlang mode is
started. See also `erlang-load-hook', a hook which is run once,
when Erlang mode is loaded into Emacs, and `erlang-shell-mode-hook'
which is run every time a new inferior Erlang shell is started.
To use a hook, create an Emacs lisp function to perform your actions
and add the function to the hook by calling `add-hook'.
The following example binds the key sequence C-c C-c to the command
`erlang-compile' (normally bound to C-c C-k). The example also
activates Font Lock mode to fontify the buffer and adds a menu
containing all functions defined in the current buffer.
To use the example, copy the following lines to your `~/.emacs' file:
(add-hook 'erlang-mode-hook 'my-erlang-mode-hook)
(defun my-erlang-mode-hook ()
(local-set-key "\C-c\C-c" 'erlang-compile)
(if window-system
(progn
(setq font-lock-maximum-decoration t)
(font-lock-mode 1)))
(if (and window-system (fboundp 'imenu-add-to-menubar))
(imenu-add-to-menubar "Imenu")))
(defvar erlang-mode-hook nil (#$ . -4718))
#@1095 *Functions to run when Erlang mode is loaded.
This hook is used to change the behaviour of Erlang mode. It is
normally used by the user to personalise the programming environment.
When used in a site init file, it could be used to customize Erlang
mode for all users on the system.
The difference between this hook and `erlang-mode-hook' and
`erlang-shell-mode-hook' is that the functions in this hook
is only called once, when the Erlang mode is loaded into Emacs
the first time.
Natural actions for the functions added to this hook are actions which
only should be performed once, and actions which should be performed
before starting Erlang mode. For example, a number of variables are
used by Erlang mode before `erlang-mode-hook' is run.
The following example sets the variable `erlang-root-dir' so that the
manual pages can be retrieved (note that you must set the value of
`erlang-root-dir' to match the location of Erlang on your system):
(add-hook 'erlang-load-hook 'my-erlang-load-hook)
(defun my-erlang-load-hook ()
(setq erlang-root-dir "/usr/local/erlang"))
(defvar erlang-load-hook nil (#$ . -6138))
#@193 Functions to run when a new Erlang source file is being edited.
A useful function is `tempo-template-erlang-normal-header'.
(This function only exists when the `tempo' package is available.)
(defvar erlang-new-file-hook nil (#$ . 7282))
#@196 *Non-nil means check that module name and file name agrees when saving.
If the value of this variable is the atom `ask', the user is
prompted. If the value is t the source is silently changed.
(defvar erlang-check-module-name 'ask (#$ . -7527))
#@410 *List of activated electric commands.
The list should contain the electric commands which should be active.
Currently, the available electric commands are:
`erlang-electric-comma'
`erlang-electric-semicolon'
`erlang-electric-gt'
`erlang-electric-newline'
Should the variable be bound to t, all electric commands
are activated.
To deactivate all electric commands, set this variable to nil.
(defvar erlang-electric-commands '(erlang-electric-comma erlang-electric-semicolon erlang-electric-gt) (#$ . -7781))
#@392 *Set to non-nil to inhibit newline after electric command.
This is useful since a lot of people press return after executing an
electric command.
In order to work, the command must also be in the
list `erlang-electric-newline-inhibit-list'.
Note that commands in this list are required to set the variable
`erlang-electric-newline-inhibit' to nil when the newline shouldn't be
inhibited.
(defvar erlang-electric-newline-inhibit t (#$ . -8314))
#@47 *Commands which can inhibit the next newline.
(defvar erlang-electric-newline-inhibit-list '(erlang-electric-semicolon erlang-electric-comma erlang-electric-gt) (#$ . -8767))
#@338 *Number of blank lines inserted before header, or nil.
This variable controls the behaviour of `erlang-electric-semicolon'
when a new function header is generated. When nil, no blank line is
inserted between the current line and the new header. When bound to a
number it represents the number of blank lines which should be
inserted.
(defvar erlang-electric-semicolon-insert-blank-lines nil (#$ . -8949))
#@591 *List of functions controlling `erlang-electric-semicolon'.
The functions in this list are called, in order, whenever a semicolon
is typed. Each function in the list is called with no arguments,
and should return one of the following values:
nil -- no determination made, continue checking
'stop -- do not create prototype for next line
(anything else) -- insert prototype, and stop checking
If every function in the list is called with no determination made,
then no prototype is inserted.
The test is performed by the function `erlang-test-criteria-list'.
(defvar erlang-electric-semicolon-criteria '(erlang-next-lines-empty-p erlang-at-keyword-end-p erlang-at-end-of-function-p) (#$ . -9364))
#@583 *List of functions controlling `erlang-electric-comma'.
The functions in this list are called, in order, whenever a comma
is typed. Each function in the list is called with no arguments,
and should return one of the following values:
nil -- no determination made, continue checking
'stop -- do not create prototype for next line
(anything else) -- insert prototype, and stop checking
If every function in the list is called with no determination made,
then no prototype is inserted.
The test is performed by the function `erlang-test-criteria-list'.
(defvar erlang-electric-comma-criteria '(erlang-stop-when-inside-argument-list erlang-stop-when-at-guard erlang-next-lines-empty-p erlang-at-keyword-end-p erlang-at-end-of-function-p) (#$ . -10099))
#@598 *List of functions controlling the arrow aspect of `erlang-electric-gt'.
The functions in this list are called, in order, whenever a `>'
is typed. Each function in the list is called with no arguments,
and should return one of the following values:
nil -- no determination made, continue checking
'stop -- do not create prototype for next line
(anything else) -- insert prototype, and stop checking
If every function in the list is called with no determination made,
then no prototype is inserted.
The test is performed by the function `erlang-test-criteria-list'.
(defvar erlang-electric-arrow-criteria '(erlang-next-lines-empty-p erlang-at-end-of-function-p) (#$ . -10887))
#@840 *List of functions controlling `erlang-electric-newline'.
The electric newline commands indents the next line. Should the
current line begin with a comment the comment start is copied to
the newly created line.
The functions in this list are called, in order, whenever a comma
is typed. Each function in the list is called with no arguments,
and should return one of the following values:
nil -- no determination made, continue checking
'stop -- do not create prototype for next line
(anything else) -- trigger the electric command.
If every function in the list is called with no determination made,
then no prototype is inserted. Should the atom t be a member of the
list, it is treated as a function triggering the electric command.
The test is performed by the function `erlang-test-criteria-list'.
(defvar erlang-electric-newline-criteria '(t) (#$ . -11602))
#@940 *Number of blank lines required to activate an electric command.
Actually, this value controls the behaviour of the function
`erlang-next-lines-empty-p' which normally is a member of the
criteria lists controlling the electric commands. (Please see
the variables `erlang-electric-semicolon-criteria' and
`erlang-electric-comma-criteria'.)
The variable is bound to a threshold value, a number, representing the
number of lines which must be empty.
Setting this variable to zero, electric commands will always be
triggered by `erlang-next-lines-empty-p', unless inhibited by other
rules.
Should this variable be nil, `erlang-next-lines-empty-p' will never
trigger an electric command. The same effect would be reached if the
function `erlang-next-lines-empty-p' would be removed from the criteria
lists.
Note that even if `erlang-next-lines-empty-p' should not trigger an
electric command, other functions in the criteria list could.
(defvar erlang-next-lines-empty-threshold 2 (#$ . -12509))
#@206 *Non-nil means that the arguments are cloned when a clause is generated.
A new function header can be generated by calls to the function
`erlang-generate-new-clause' and by use of the electric semicolon.
(defvar erlang-new-clause-with-arguments nil (#$ . -13514))
#@367 *When nil, go to the directory containing source file when compiling.
This is a workaround for a bug in the `outdir' option of compile. If the
outdir is not in the current load path, Erlang doesn't load the object
module after it has been compiled.
To activate the workaround, place the following in your `~/.emacs' file:
(setq erlang-compile-use-outdir nil)
(defvar erlang-compile-use-outdir t (#$ . -13786))
#@53 *Indentation of Erlang calls/clauses within blocks.
(defvar erlang-indent-level 4 (#$ . -14209))
#@32 *Indentation of Erlang guards.
(defvar erlang-indent-guard 2 (#$ . -14312))
#@118 *Indentation of the first argument in a function call.
When nil, indent to the column after the `(' of the
function.
(defvar erlang-argument-indent 2 (#$ . -14395))
#@148 *Non-nil means TAB in Erlang mode should always re-indent the current line,
regardless of where in the line point is when the TAB command is used.
(defvar erlang-tab-always-indent t (#$ . -14567))
#@39 *Patterns for matching Erlang errors.
(defvar erlang-error-regexp-alist '(("^\\([^:( \n]+\\)[:(][ ]*\\([0-9]+\\)[:) ]" 1 2)) (#$ . -14770))
#@165 Inhibit the creation of the Erlang Manual Pages menu.
The Windows distribution of Erlang does not include man pages, hence
there is no attempt to create the menu.
(defvar erlang-man-inhibit (eq system-type 'windows-nt) (#$ . 14920))
#@326 *The man directories displayed in the Erlang menu.
Each item in the list should be a list with three elements, the first
the name of the menu, the second the directory, and the last a flag.
Should the flag the nil, the directory is absolute, should it be non-nil
the directory is relative to the variable `erlang-root-dir'.
(defvar erlang-man-dirs '(("Man - Commands" "/man/man1" t) ("Man - Modules" "/man/man3" t) ("Man - Files" "/man/man4" t) ("Man - Applications" "/man/man6" t)) (#$ . -15161))
#@56 *The maximum number of menu items in one menu allowed.
(defvar erlang-man-max-menu-size 20 (#$ . -15666))
#@224 *Function used to display man page.
The function is called with one argument, the name of the file
containing the man page. Use this variable when the default
function, `erlang-man-display', does not work on your system.
(defvar erlang-man-display-function 'erlang-man-display (#$ . -15779))
#@109 Regexp which should match an Erlang atom.
The regexp must be surrounded with a pair of regexp parentheses.
(defconst erlang-atom-regexp "\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\)" (#$ . 16080))
#@164 Number of regexp parenthesis pairs in `erlang-atom-regexp'.
This is used to determine parenthesis matches in complex regexps which
contains `erlang-atom-regexp'.
(defconst erlang-atom-regexp-matches 1 (#$ . 16282))
#@113 Regexp which should match an Erlang variable.
The regexp must be surrounded with a pair of regexp parentheses.
(defconst erlang-variable-regexp "\\([A-Z_][a-zA-Z0-9_]*\\)" (#$ . 16505))
#@160 Number of regexp parenthesis pairs in `erlang-variable-regexp'.
This is used to determine matches in complex regexps which contains
`erlang-variable-regexp'.
(defconst erlang-variable-regexp-matches 1 (#$ . 16699))
#@50 Regexp which should match beginning of a clause.
(defvar erlang-defun-prompt-regexp (concat "^" erlang-atom-regexp "\\s *(") (#$ . 16921))
#@493 *Regexp which should match an Erlang file name.
This regexp is used when an Erlang module name is extracted from the
name of an Erlang source file.
The regexp should only match the section of the file name which should
be excluded from the module name.
To match all files set this variable to "\\(\\..*\\|\\)$".
The matches all except the extension. This is useful if the Erlang
tags system should interpret tags on the form `module:tag' for
files written in other languages than Erlang.
(defvar erlang-file-name-extension-regexp "\\.[eh]rl$" (#$ . -17067))
#@30 *Keymap used in Erlang mode.
(defvar erlang-mode-map nil (#$ . -17635))
#@45 Abbrev table in use in Erlang-mode buffers.
(defvar erlang-mode-abbrev-table nil (#$ . 17713))
#@45 Syntax table in use in Erlang-mode buffers.
(defvar erlang-mode-syntax-table nil (#$ . 17814))
#@32 Major version number of Emacs.
(defconst erlang-emacs-major-version (byte-code "\302\300!\203\207\303\304 \"\210\305 \306\224\306\225O!\207" [emacs-major-version emacs-version boundp string-match "\\([0-9]+\\)\\.\\([0-9]+\\)" string-to-int 1] 4) (#$ . 17915))
#@32 Minor version number of Emacs.
(defconst erlang-emacs-minor-version (byte-code "\302\300!\203\207\303\304 \"\210\305 \306\224\306\225O!\207" [emacs-minor-version emacs-version boundp string-match "\\([0-9]+\\)\\.\\([0-9]+\\)" string-to-int 2] 4) (#$ . 18184))
#@51 Non-nil when running under XEmacs or Lucid Emacs.
(defconst erlang-xemacs-p (string-match "Lucid\\|XEmacs" emacs-version) (#$ . 18453))
#@265 Common popup menu for all buffers in Erlang mode.
This variable is destructively modified every time the Erlang menu
is modified. The effect is that all changes take effect in all
buffers in Erlang mode, just like under GNU Emacs.
Never EVER set this variable!
(defvar erlang-xemacs-popup-menu '("Erlang Mode Commands") (#$ . 18596))
#@61 Non-nil means use `compilation-minor-mode' in Erlang shell.
(defconst inferior-erlang-use-cmm (boundp 'minor-mode-overriding-map-alist) (#$ . 18939))
#@877 *Description of all skeleton templates.
Both functions and menu entries will be created.
Each entry in `erlang-skel' should be a list with three or four
elements, or the empty list.
The first element is the name which shows up in the menu. The second
is the `tempo' identifier (The string "erlang-" will be added in
front of it). The third is the skeleton descriptor, a variable
containing `tempo' attributes as described in the function
`tempo-define-template'. The optional fourth elements denotes a
function which should be called when the menu is selected.
Functions corresponding to every template will be created. The name
of the function will be `tempo-template-erlang-X' where `X' is the
tempo identifier as specified in the second argument of the elements
in this list.
A list with zero elements means that the a horizontal line should
be placed in the menu.
(defvar erlang-skel '(("If" "if" erlang-skel-if) ("Case" "case" erlang-skel-case) ("Receive" "receive" erlang-skel-receive) ("Receive After" "after" erlang-skel-receive-after) ("Receive Loop" "loop" erlang-skel-receive-loop) ("Module" "module" erlang-skel-module) ("Author" "author" erlang-skel-author) nil ("Small Header" "small-header" erlang-skel-small-header erlang-skel-header) ("Normal Header" "normal-header" erlang-skel-normal-header erlang-skel-header) ("Large Header" "large-header" erlang-skel-large-header erlang-skel-header) nil ("Small Server" "small-server" erlang-skel-small-server erlang-skel-header) nil ("Application" "application" erlang-skel-application erlang-skel-header) ("Supervisor" "supervisor" erlang-skel-supervisor erlang-skel-header) ("supervisor_bridge" "supervisor-bridge" erlang-skel-supervisor-bridge erlang-skel-header) ("gen_server" "generic-server" erlang-skel-generic-server erlang-skel-header) ("gen_event" "gen-event" erlang-skel-gen-event erlang-skel-header) ("gen_fsm" "gen-fsm" erlang-skel-gen-fsm erlang-skel-header) ("Library module" "gen-lib" erlang-skel-lib erlang-skel-header) ("Corba callback" "gen-corba-cb" erlang-skel-corba-callback erlang-skel-header) ("Erlang test suite TS frontend" "ts-test-suite" erlang-skel-ts-test-suite erlang-skel-header) ("Erlang test suite CT frontend" "ct-test-suite" erlang-skel-ct-test-suite erlang-skel-header)) (#$ . -19096))
#@27 Mail address of the user.
(defvar erlang-skel-mail-address (byte-code "\203 \302\303\"\203\304 \305\306\301!\203 \206\307 Q\207\207" [user-mail-address mail-host-address string-match "(" user-login-name "@" boundp system-name] 4) (#$ . 21390))
#@88 *The skeleton of a `case' expression.
Please see the function `tempo-define-template'.
(defvar erlang-skel-case '((erlang-skel-skip-blank) o > "case " p " of" n> p "_ ->" n> p "ok" n> "end" p) (#$ . -21650))
#@86 The skeleton of an `if' expression.
Please see the function `tempo-define-template'.
(defvar erlang-skel-if '((erlang-skel-skip-blank) o > "if" n> p " ->" n> p "ok" n> "end" p) (#$ . 21864))
#@91 *The skeleton of a `receive' expression.
Please see the function `tempo-define-template'.
(defvar erlang-skel-receive '((erlang-skel-skip-blank) o > "receive" n> p "_ ->" n> p "ok" n> "end" p) (#$ . -22061))
#@114 *The skeleton of a `receive' expression with an `after' clause.
Please see the function `tempo-define-template'.
(defvar erlang-skel-receive-after '((erlang-skel-skip-blank) o > "receive" n> p "_ ->" n> p "ok" n> "after " p "T ->" n> p "ok" n> "end" p) (#$ . -22276))
#@92 *The skeleton of a simple `receive' loop.
Please see the function `tempo-define-template'.
(defvar erlang-skel-receive-loop '(& o "loop(" p ") ->" n> "receive" n> p "_ ->" n> "loop(" p ")" n> "end.") (#$ . -22550))
#@89 *The skeleton of a `module' attribute.
Please see the function `tempo-define-template'.
(defvar erlang-skel-module '(& "-module(" (erlang-add-quotes-if-needed (erlang-get-module-from-file-name)) ")." n) (#$ . -22771))
#@89 *The skeleton of a `author' attribute.
Please see the function `tempo-define-template'.
(defvar erlang-skel-author '(& "-author('" erlang-skel-mail-address "')." n) (#$ . -22995))
#@223 *The skeleton template to generate a version control attribute.
The default is to insert nothing. Example of usage:
(setq erlang-skel-vc '(& "-rcs(\"$Id: $ \").") n)
Please see the function `tempo-define-template'.
(defvar erlang-skel-vc nil (#$ . -23182))
#@90 *The skeleton of an `export' attribute.
Please see the function `tempo-define-template'.
(defvar erlang-skel-export '(& "-export([" n> "])." n) (#$ . -23452))
#@90 *The skeleton of an `import' attribute.
Please see the function `tempo-define-template'.
(defvar erlang-skel-import '(& "%%-import(Module, [Function/Arity, ...])." n) (#$ . -23617))
#@90 *The skeleton of a `compile' attribute.
Please see the function `tempo-define-template'.
(defvar erlang-skel-compile nil (#$ . -23805))
#@98 *Function which returns date string.
Look in the module `time-stamp' for a battery of functions.
(defvar erlang-skel-date-function 'erlang-skel-dd-mmm-yyyy (#$ . -23947))
#@233 *The template for a copyright line in the header, normally empty.
This variable should be bound to a `tempo' template, for example:
'(& "%%% Copyright (C) 2000, Yoyodyne, Inc." n)
Please see the function `tempo-define-template'.
(defvar erlang-skel-copyright-comment nil (#$ . -24125))
#@48 *The template for the "Created:" comment line.
(defvar erlang-skel-created-comment '(& "%%% Created : " (funcall erlang-skel-date-function) " by " (user-full-name) " <" erlang-skel-mail-address ">" n) (#$ . -24420))
#@111 *The template for creating the "Author:" line in the header.
Please see the function `tempo-define-template'.
(defvar erlang-skel-author-comment '(& "%%% Author : " (user-full-name) " <" erlang-skel-mail-address ">" n) (#$ . -24643))
#@111 *The template for creating the "Module:" line in the header.
Please see the function `tempo-define-template'.
(defvar erlang-skel-file-comment '(& "%%% File : " (file-name-nondirectory buffer-file-name) n) (#$ . -24885))
#@104 *The template of a small header without any comments.
Please see the function `tempo-define-template'.
(defvar erlang-skel-small-header '(o (erlang-skel-include erlang-skel-module) n (erlang-skel-include erlang-skel-compile erlang-skel-vc)) (#$ . -25116))
#@84 *The template of a normal header.
Please see the function `tempo-define-template'.
(defvar erlang-skel-normal-header '(o (erlang-skel-include erlang-skel-copyright-comment erlang-skel-file-comment erlang-skel-author-comment) "%%% Description : " p n (erlang-skel-include erlang-skel-created-comment) n (erlang-skel-include erlang-skel-small-header) n) (#$ . -25378))
#@83 *The template of a large header.
Please see the function `tempo-define-template'.
(defvar erlang-skel-large-header '(o (erlang-skel-separator) (erlang-skel-include erlang-skel-copyright-comment erlang-skel-file-comment erlang-skel-author-comment) "%%% Description : " p n "%%%" n (erlang-skel-include erlang-skel-created-comment) (erlang-skel-separator) (erlang-skel-include erlang-skel-small-header)) (#$ . -25751))
#@79 *Template of a small server.
Please see the function `tempo-define-template'.
(defvar erlang-skel-small-server '((erlang-skel-include erlang-skel-large-header) "-export([start/0,init/1])." n n n "start() ->" n> "spawn(" (erlang-get-module-from-file-name) ", init, [self()])." n n "init(From) ->" n> "loop(From)." n n "loop(From) ->" n> "receive" n> p "_ ->" n> "loop(From)" n> "end.") (#$ . -26174))
#@93 *The template of an application behaviour.
Please see the function `tempo-define-template'.
(defvar erlang-skel-application '((erlang-skel-include erlang-skel-large-header) "-behaviour(application)." n n "%% Application callbacks" n "-export([start/2, stop/1])." n n (erlang-skel-double-separator 2) "%% Application callbacks" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Function: start(Type, StartArgs) -> {ok, Pid} |" n "%% {ok, Pid, State} |" n "%% {error, Reason}" n "%% Description: This function is called whenever an application " n "%% is started using application:start/1,2, and should start the processes" n "%% of the application. If the application is structured according to the" n "%% OTP design principles as a supervision tree, this means starting the" n "%% top supervisor of the tree." n (erlang-skel-separator 2) "start(_Type, StartArgs) ->" n> "case 'TopSupervisor':start_link(StartArgs) of" n> "{ok, Pid} -> " n> "{ok, Pid};" n> "Error ->" n> "Error" n> "end." n n (erlang-skel-separator 2) "%% Function: stop(State) -> void()" n "%% Description: This function is called whenever an application" n "%% has stopped. It is intended to be the opposite of Module:start/2 and" n "%% should do any necessary cleaning up. The return value is ignored. " n (erlang-skel-separator 2) "stop(_State) ->" n> "ok." n n (erlang-skel-double-separator 2) "%% Internal functions" n (erlang-skel-double-separator 2)) (#$ . -26580))
#@92 *The template of an supervisor behaviour.
Please see the function `tempo-define-template'.
(defvar erlang-skel-supervisor '((erlang-skel-include erlang-skel-large-header) "-behaviour(supervisor)." n n "%% API" n "-export([start_link/0])." n n "%% Supervisor callbacks" n "-export([init/1])." n n "-define(SERVER, ?MODULE)." n n (erlang-skel-double-separator 2) "%% API functions" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Function: start_link() -> {ok,Pid} | ignore | {error,Error}" n "%% Description: Starts the supervisor" n (erlang-skel-separator 2) "start_link() ->" n> "supervisor:start_link({local, ?SERVER}, ?MODULE, [])." n n (erlang-skel-double-separator 2) "%% Supervisor callbacks" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Func: init(Args) -> {ok, {SupFlags, [ChildSpec]}} |" n "%% ignore |" n "%% {error, Reason}" n "%% Description: Whenever a supervisor is started using " n "%% supervisor:start_link/[2,3], this function is called by the new process " n "%% to find out about restart strategy, maximum restart frequency and child " n "%% specifications." n (erlang-skel-separator 2) "init([]) ->" n> "AChild = {'AName',{'AModule',start_link,[]}," n> "permanent,2000,worker,['AModule']}," n> "{ok,{{one_for_all,0,1}, [AChild]}}." n n (erlang-skel-double-separator 2) "%% Internal functions" n (erlang-skel-double-separator 2)) (#$ . -28113))
#@99 *The template of an supervisor_bridge behaviour.
Please see the function `tempo-define-template'.
(defvar erlang-skel-supervisor-bridge '((erlang-skel-include erlang-skel-large-header) "-behaviour(supervisor_bridge)." n n "%% API" n "-export([start_link/0])." n n "%% supervisor_bridge callbacks" n "-export([init/1, terminate/2])." n n "-define(SERVER, ?MODULE)." n n "-record(state, {})." n n (erlang-skel-double-separator 2) "%% API" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Function: start_link() -> {ok,Pid} | ignore | {error,Error}" n "%% Description: Starts the supervisor bridge" n (erlang-skel-separator 2) "start_link() ->" n> "supervisor_bridge:start_link({local, ?SERVER}, ?MODULE, [])." n n (erlang-skel-double-separator 2) "%% supervisor_bridge callbacks" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Funcion: init(Args) -> {ok, Pid, State} |" n "%% ignore |" n "%% {error, Reason} " n "%% Description:Creates a supervisor_bridge process, linked to the calling" n "%% process, which calls Module:init/1 to start the subsystem. To ensure a" n "%% synchronized start-up procedure, this function does not return until" n "%% Module:init/1 has returned. " n (erlang-skel-separator 2) "init([]) ->" n> "case 'AModule':start_link() of" n> "{ok, Pid} ->" n> "{ok, Pid, #state{}};" n> "Error ->" n> "Error" n> "end." n n (erlang-skel-separator 2) "%% Func: terminate(Reason, State) -> void()" n "%% Description:This function is called by the supervisor_bridge when it is" n "%% about to terminate. It should be the opposite of Module:init/1 and stop" n "%% the subsystem and do any necessary cleaning up.The return value is ignored." (erlang-skel-separator 2) "terminate(Reason, State) ->" n> "'AModule':stop()," n> "ok." n n (erlang-skel-double-separator 2) "%% Internal functions" n (erlang-skel-double-separator 2)) (#$ . -29588))
#@85 *The template of a generic server.
Please see the function `tempo-define-template'.
(defvar erlang-skel-generic-server '((erlang-skel-include erlang-skel-large-header) "-behaviour(gen_server)." n n "%% API" n "-export([start_link/0])." n n "%% gen_server callbacks" n "-export([init/1, handle_call/3, handle_cast/2, " "handle_info/2," n> "terminate/2, code_change/3])." n n "-record(state, {})." n n (erlang-skel-double-separator 2) "%% API" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Function: start_link() -> {ok,Pid} | ignore | {error,Error}" n "%% Description: Starts the server" n (erlang-skel-separator 2) "start_link() ->" n> "gen_server:start_link({local, ?SERVER}, ?MODULE, [], [])." n n (erlang-skel-double-separator 2) "%% gen_server callbacks" n (erlang-skel-double-separator 2) n (erlang-skel-separator 2) "%% Function: init(Args) -> {ok, State} |" n "%% {ok, State, Timeout} |" n "%% ignore |" n "%% {stop, Reason}" n "%% Description: Initiates the server" n (erlang-skel-separator 2) "init([]) ->" n> "{ok, #state{}}." n n (erlang-skel-separator 2) "%% Function: " "%% handle_call(Request, From, State) -> {reply, Reply, State} |" n "%% {reply, Reply, State, Timeout} |" n "%% {noreply, State} |" n "%% {noreply, State, Timeout} |" n "%% {stop, Reason, Reply, State} |" n "%% {stop, Reason, State}" n "%% Description: Handling call messages" n (erlang-skel-separator 2) "handle_call(_Request, _From, State) ->" n> "Reply = ok," n> "{reply, Reply, State}." n n (erlang-skel-separator 2) "%% Function: handle_cast(Msg, State) -> {noreply, State} |" n "%% {noreply, State, Timeout} |" n "%% {stop, Reason, State}" n "%% Description: Handling cast messages" n (erlang-skel-separator 2) "handle_cast(_Msg, State) ->" n> "{noreply, State}." n n (erlang-skel-separator 2) "%% Function: handle_info(Info, State) -> {noreply, State} |" n "%% {noreply, State, Timeout} |" n "%% {stop, Reason, State}" n "%% Description: Handling all non call/cast messages" n (erlang-skel-separator 2) "handle_info(_Info, State) ->" n> "{noreply, State}." n n (erlang-skel-separator 2) "%% Function: terminate(Reason, State) -> void()" n "%% Description: This function is called by a gen_server when it is about to" n "%% terminate. It should be the opposite of Module:init/1 and do any necessary" n "%% cleaning up. When it returns, the gen_server terminates with Reason." n "%% The return value is ignored." n (erlang-skel-separator 2) "terminate(_Reason, _State) ->" n> "ok." n n (erlang-skel-separator 2) "%% Func: code_change(OldVsn, State, Extra) -> {ok, NewState}" n "%% Description: Convert process state when code is changed" n (erlang-skel-separator 2) "code_change(_OldVsn, State, _Extra) ->" n> "{ok, State}." n n (erlang-skel-separator 2) "%%% Internal functions" n (erlang-skel-separator 2)) (#$ . -31539))
#@80 *The template of a gen_event.
Please see the function `tempo-define-template'.
(defvar erlang-skel-gen-event '((erlang-skel-include erlang-skel-large-header) "-behaviour(gen_event)." n "%% API" n "-export([start_link/0, add_handler/0])." n n "%% gen_event callbacks" n "-export([init/1, handle_event/2, handle_call/2, " n> "handle_info/2, terminate/2, code_change/3])." n n "-record(state, {})." n n (erlang-skel-double-separator 2) "%% gen_event callbacks" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Function: start_link() -> {ok,Pid} | {error,Error} " n "%% Description: Creates an event manager." n (erlang-skel-separator 2) "start_link() ->" n> "gen_event:start_link({local, ?SERVER}). " n n (erlang-skel-separator 2) "%% Function: add_handler() -> ok | {'EXIT',Reason} | term()" n "%% Description: Adds an event handler" n (erlang-skel-separator 2) "add_handler() ->" n> "gen_event:add_handler(?SERVER, ?MODULE, [])." n n (erlang-skel-double-separator 2) "%% gen_event callbacks" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Function: init(Args) -> {ok, State}" n "%% Description: Whenever a new event handler is added to an event manager," n "%% this function is called to initialize the event handler." n (erlang-skel-separator 2) "init([]) ->" n> "{ok, #state{}}." n n (erlang-skel-separator 2) "%% Function: " n "%% handle_event(Event, State) -> {ok, State} |" n "%% {swap_handler, Args1, State1, Mod2, Args2} |" n "%% remove_handler" n "%% Description:Whenever an event manager receives an event sent using" n "%% gen_event:notify/2 or gen_event:sync_notify/2, this function is called for" n "%% each installed event handler to handle the event. " n (erlang-skel-separator 2) "handle_event(_Event, State) ->" n> "{ok, State}." n n (erlang-skel-separator 2) "%% Function: " n "%% handle_call(Request, State) -> {ok, Reply, State} |" n "%% {swap_handler, Reply, Args1, State1, " n "%% Mod2, Args2} |" n "%% {remove_handler, Reply}" n "%% Description: Whenever an event manager receives a request sent using" n "%% gen_event:call/3,4, this function is called for the specified event " n "%% handler to handle the request." n (erlang-skel-separator 2) "handle_call(_Request, State) ->" n> "Reply = ok," n> "{ok, Reply, State}." n n (erlang-skel-separator 2) "%% Function: " n "%% handle_info(Info, State) -> {ok, State} |" n "%% {swap_handler, Args1, State1, Mod2, Args2} |" n "%% remove_handler" n "%% Description: This function is called for each installed event handler when" n "%% an event manager receives any other message than an event or a synchronous" n "%% request (or a system message)." n (erlang-skel-separator 2) "handle_info(_Info, State) ->" n> "{ok, State}." n n (erlang-skel-separator 2) "%% Function: terminate(Reason, State) -> void()" n "%% Description:Whenever an event handler is deleted from an event manager," n "%% this function is called. It should be the opposite of Module:init/1 and " n "%% do any necessary cleaning up. " n (erlang-skel-separator 2) "terminate(_Reason, _State) ->" n> "ok." n n (erlang-skel-separator 2) "%% Function: code_change(OldVsn, State, Extra) -> {ok, NewState} " n "%% Description: Convert process state when code is changed" n (erlang-skel-separator 2) "code_change(_OldVsn, State, _Extra) ->" n> "{ok, State}." n n (erlang-skel-separator 2) "%%% Internal functions" n (erlang-skel-separator 2)) (#$ . -34797))
#@78 *The template of a gen_fsm.
Please see the function `tempo-define-template'.
(defvar erlang-skel-gen-fsm '((erlang-skel-include erlang-skel-large-header) "-behaviour(gen_fsm)." n n "%% API" n "-export([start_link/0])." n n "%% gen_fsm callbacks" n "-export([init/1, state_name/2, state_name/3, handle_event/3," n> "handle_sync_event/4, handle_info/3, terminate/3, code_change/4])." n n "-record(state, {})." n n (erlang-skel-double-separator 2) "%% API" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Function: start_link() -> ok,Pid} | ignore | {error,Error}" n "%% Description:Creates a gen_fsm process which calls Module:init/1 to" n "%% initialize. To ensure a synchronized start-up procedure, this function" n "%% does not return until Module:init/1 has returned. " n (erlang-skel-separator 2) "start_link() ->" n> "gen_fsm:start_link({local, ?SERVER}, ?MODULE, [], [])." n n (erlang-skel-double-separator 2) "%% gen_fsm callbacks" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Function: init(Args) -> {ok, StateName, State} |" n "%% {ok, StateName, State, Timeout} |" n "%% ignore |" n "%% {stop, StopReason} " n "%% Description:Whenever a gen_fsm is started using gen_fsm:start/[3,4] or" n "%% gen_fsm:start_link/3,4, this function is called by the new process to " n "%% initialize. " n (erlang-skel-separator 2) "init([]) ->" n> "{ok, state_name, #state{}}." n n (erlang-skel-separator 2) "%% Function: " n "%% state_name(Event, State) -> {next_state, NextStateName, NextState}|" n "%% {next_state, NextStateName, " n "%% NextState, Timeout} |" n "%% {stop, Reason, NewState}" n "%% Description:There should be one instance of this function for each possible" n "%% state name. Whenever a gen_fsm receives an event sent using" n "%% gen_fsm:send_event/2, the instance of this function with the same name as" n "%% the current state name StateName is called to handle the event. It is also " n "%% called if a timeout occurs. " n (erlang-skel-separator 2) "state_name(_Event, State) ->" n> "{next_state, state_name, State}." n n (erlang-skel-separator 2) "%% Function:" n "%% state_name(Event, From, State) -> {next_state, NextStateName, NextState} |" n "%% {next_state, NextStateName, " n "%% NextState, Timeout} |" n "%% {reply, Reply, NextStateName, NextState}|" n "%% {reply, Reply, NextStateName, " n "%% NextState, Timeout} |" n "%% {stop, Reason, NewState}|" n "%% {stop, Reason, Reply, NewState}" n "%% Description: There should be one instance of this function for each" n "%% possible state name. Whenever a gen_fsm receives an event sent using" n "%% gen_fsm:sync_send_event/2,3, the instance of this function with the same" n "%% name as the current state name StateName is called to handle the event." n (erlang-skel-separator 2) "state_name(_Event, _From, State) ->" n> "Reply = ok," n> "{reply, Reply, state_name, State}." n n (erlang-skel-separator 2) "%% Function: " n "%% handle_event(Event, StateName, State) -> {next_state, NextStateName, " n "%% NextState} |" n "%% {next_state, NextStateName, " n "%% NextState, Timeout} |" n "%% {stop, Reason, NewState}" n "%% Description: Whenever a gen_fsm receives an event sent using" n "%% gen_fsm:send_all_state_event/2, this function is called to handle" n "%% the event." n (erlang-skel-separator 2) "handle_event(_Event, StateName, State) ->" n> "{next_state, StateName, State}." n n (erlang-skel-separator 2) "%% Function: " n "%% handle_sync_event(Event, From, StateName, " n "%% State) -> {next_state, NextStateName, NextState} |" n "%% {next_state, NextStateName, NextState, " n "%% Timeout} |" n "%% {reply, Reply, NextStateName, NextState}|" n "%% {reply, Reply, NextStateName, NextState, " n "%% Timeout} |" n "%% {stop, Reason, NewState} |" n "%% {stop, Reason, Reply, NewState}" n "%% Description: Whenever a gen_fsm receives an event sent using" n "%% gen_fsm:sync_send_all_state_event/2,3, this function is called to handle" n "%% the event." n (erlang-skel-separator 2) "handle_sync_event(Event, From, StateName, State) ->" n> "Reply = ok," n> "{reply, Reply, StateName, State}." n n (erlang-skel-separator 2) "%% Function: " n "%% handle_info(Info,StateName,State)-> {next_state, NextStateName, NextState}|" n "%% {next_state, NextStateName, NextState, " n "%% Timeout} |" n "%% {stop, Reason, NewState}" n "%% Description: This function is called by a gen_fsm when it receives any" n "%% other message than a synchronous or asynchronous event" n "%% (or a system message)." n (erlang-skel-separator 2) "handle_info(_Info, StateName, State) ->" n> "{next_state, StateName, State}." n n (erlang-skel-separator 2) "%% Function: terminate(Reason, StateName, State) -> void()" n "%% Description:This function is called by a gen_fsm when it is about" n "%% to terminate. It should be the opposite of Module:init/1 and do any" n "%% necessary cleaning up. When it returns, the gen_fsm terminates with" n "%% Reason. The return value is ignored." n (erlang-skel-separator 2) "terminate(_Reason, _StateName, _State) ->" n> "ok." n n (erlang-skel-separator 2) "%% Function:" n "%% code_change(OldVsn, StateName, State, Extra) -> {ok, StateName, NewState}" n "%% Description: Convert process state when code is changed" n (erlang-skel-separator 2) "code_change(_OldVsn, StateName, State, _Extra) ->" n> "{ok, StateName, State}." n n (erlang-skel-separator 2) "%%% Internal functions" n (erlang-skel-separator 2)) (#$ . -38433))
#@85 *The template of a library module.
Please see the function `tempo-define-template'.
(defvar erlang-skel-lib '((erlang-skel-include erlang-skel-large-header) "%% API" n "-export([])." n n (erlang-skel-double-separator 2) "%% API" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Function: " n "%% Description:" n (erlang-skel-separator 2) n (erlang-skel-double-separator 2) "%% Internal functions" n (erlang-skel-double-separator 2)) (#$ . -44758))
#@85 *The template of a library module.
Please see the function `tempo-define-template'.
(defvar erlang-skel-corba-callback '((erlang-skel-include erlang-skel-large-header) "%% Include files" n n "%% API" n "-export([])." n n "%% Corba callbacks" n "-export([init/1, terminate/2, code_change/3])." n n "-record(state, {})." n n (erlang-skel-double-separator 2) "%% Corba callbacks" n (erlang-skel-double-separator 2) (erlang-skel-separator 2) "%% Function: init(Args) -> {ok, State} |" n "%% {ok, State, Timeout} |" n "%% ignore |" n "%% {stop, Reason}" n "%% Description: Initiates the server" n (erlang-skel-separator 2) "init([]) ->" n> "{ok, #state{}}." n n (erlang-skel-separator 2) "%% Function: terminate(Reason, State) -> void()" n "%% Description: Shutdown the server" n (erlang-skel-separator 2) "terminate(_Reason, _State) ->" n> "ok." n n (erlang-skel-separator 2) "%% Function: code_change(OldVsn, State, Extra) -> {ok, NewState} " n "%% Description: Convert process state when code is changed" n (erlang-skel-separator 2) "code_change(_OldVsn, State, _Extra) ->" n> "{ok, State}." n n (erlang-skel-double-separator 2) "%% Internal functions" n (erlang-skel-double-separator 2)) (#$ . -45228))
#@85 *The template of a library module.
Please see the function `tempo-define-template'.
(defvar erlang-skel-ts-test-suite '((erlang-skel-include erlang-skel-large-header) "%% Note: This directive should only be used in test suites." n "-compile(export_all)." n n "-include(\"test_server.hrl\")." n n (erlang-skel-separator 2) "%% TEST SERVER CALLBACK FUNCTIONS" n (erlang-skel-separator 2) n (erlang-skel-separator 2) "%% Function: init_per_suite(Config0) -> Config1 | {skip,Reason}" n "%%" n "%% Config0 = Config1 = [tuple()]" n "%% A list of key/value pairs, holding the test case configuration." n "%% Reason = term()" n "%% The reason for skipping the suite." n "%%" n "%% Description: Initialization before the suite." n "%%" n "%% Note: This function is free to add any key/value pairs to the Config" n "%% variable, but should NOT alter/remove any existing entries." n (erlang-skel-separator 2) "init_per_suite(Config) ->" n > "Config." n n (erlang-skel-separator 2) "%% Function: end_per_suite(Config) -> void()" n "%%" n "%% Config = [tuple()]" n "%% A list of key/value pairs, holding the test case configuration." n "%%" n "%% Description: Cleanup after the suite." n (erlang-skel-separator 2) "end_per_suite(_Config) ->" n > "ok." n n (erlang-skel-separator 2) "%% Function: init_per_testcase(TestCase, Config0) -> Config1 |" n "%% {skip,Reason}" n "%% TestCase = atom()" n "%% Name of the test case that is about to run." n "%% Config0 = Config1 = [tuple()]" n "%% A list of key/value pairs, holding the test case configuration." n "%% Reason = term()" n "%% The reason for skipping the test case." n "%%" n "%% Description: Initialization before each test case." n "%%" n "%% Note: This function is free to add any key/value pairs to the Config" n "%% variable, but should NOT alter/remove any existing entries." n (erlang-skel-separator 2) "init_per_testcase(_TestCase, Config) ->" n > "Config." n n (erlang-skel-separator 2) "%% Function: end_per_testcase(TestCase, Config) -> void()" n "%%" n "%% TestCase = atom()" n "%% Name of the test case that is finished." n "%% Config = [tuple()]" n "%% A list of key/value pairs, holding the test case configuration." n "%%" n "%% Description: Cleanup after each test case." n (erlang-skel-separator 2) "end_per_testcase(_TestCase, _Config) ->" n > "ok." n n (erlang-skel-separator 2) "%% Function: all(Clause) -> Descr | TestCases | {skip,Reason}" n "%%" n "%% Clause = doc | suite" n "%% Indicates expected return value." n "%% Descr = [string()] | []" n "%% String that describes the test suite." n "%% TestCases = [TestCase] " n "%% TestCase = atom()" n "%% Name of a test case." n "%% Reason = term()" n "%% The reason for skipping the test suite." n "%%" n "%% Description: Returns a description of the test suite (doc) and a" n "%% list of all test cases in the suite (suite)." n (erlang-skel-separator 2) "all(doc) -> " n > "[\"Describe the main purpose of this suite\"];" n n "all(suite) -> " n > "[a_test_case]." n n n (erlang-skel-separator 2) "%% TEST CASES" n (erlang-skel-separator 2) n (erlang-skel-separator 2) "%% Function: TestCase(Arg) -> Descr | Spec | ok | exit() | {skip,Reason}" n "%%" n "%% Arg = doc | suite | Config" n "%% Indicates expected behaviour and return value." n "%% Config = [tuple()]" n "%% A list of key/value pairs, holding the test case configuration." n "%% Descr = [string()] | []" n "%% String that describes the test case." n "%% Spec = [tuple()] | []" n "%% A test specification." n "%% Reason = term()" n "%% The reason for skipping the test case." n "%%" n "%% Description: Test case function. Returns a description of the test" n "%% case (doc), then returns a test specification (suite)," n "%% or performs the actual test (Config)." n (erlang-skel-separator 2) "a_test_case(doc) -> " n > "[\"Describe the main purpose of this test case\"];" n n "a_test_case(suite) -> " n > "[];" n n "a_test_case(Config) when is_list(Config) -> " n > "ok." n) (#$ . -46522))
#@85 *The template of a library module.
Please see the function `tempo-define-template'.
(defvar erlang-skel-ct-test-suite '((erlang-skel-include erlang-skel-large-header) "%% Note: This directive should only be used in test suites." n "-compile(export_all)." n n "-include(\"ct.hrl\")." n n (erlang-skel-separator 2) "%% COMMON TEST CALLBACK FUNCTIONS" n (erlang-skel-separator 2) n (erlang-skel-separator 2) "%% Function: suite() -> Info" n "%%" n "%% Info = [tuple()]" n "%% List of key/value pairs." n "%%" n "%% Description: Returns list of tuples to set default properties" n "%% for the suite." n "%%" n "%% Note: The suite/0 function is only meant to be used to return" n "%% default data values, not perform any other operations." n (erlang-skel-separator 2) "suite() ->" n > "[{timetrap,{minutes,10}}]." n n (erlang-skel-separator 2) "%% Function: init_per_suite(Config0) ->" n "%% Config1 | {skip,Reason} | {skip_and_save,Reason,Config1}" n "%%" n "%% Config0 = Config1 = [tuple()]" n "%% A list of key/value pairs, holding the test case configuration." n "%% Reason = term()" n "%% The reason for skipping the suite." n "%%" n "%% Description: Initialization before the suite." n "%%" n "%% Note: This function is free to add any key/value pairs to the Config" n "%% variable, but should NOT alter/remove any existing entries." n (erlang-skel-separator 2) "init_per_suite(Config) ->" n > "Config." n n (erlang-skel-separator 2) "%% Function: end_per_suite(Config0) -> void() | {save_config,Config1}" n "%%" n "%% Config0 = Config1 = [tuple()]" n "%% A list of key/value pairs, holding the test case configuration." n "%%" n "%% Description: Cleanup after the suite." n (erlang-skel-separator 2) "end_per_suite(_Config) ->" n > "ok." n n (erlang-skel-separator 2) "%% Function: init_per_testcase(TestCase, Config0) ->" n "%% Config1 | {skip,Reason} | {skip_and_save,Reason,Config1}" n "%%" n "%% TestCase = atom()" n "%% Name of the test case that is about to run." n "%% Config0 = Config1 = [tuple()]" n "%% A list of key/value pairs, holding the test case configuration." n "%% Reason = term()" n "%% The reason for skipping the test case." n "%%" n "%% Description: Initialization before each test case." n "%%" n "%% Note: This function is free to add any key/value pairs to the Config" n "%% variable, but should NOT alter/remove any existing entries." n (erlang-skel-separator 2) "init_per_testcase(_TestCase, Config) ->" n > "Config." n n (erlang-skel-separator 2) "%% Function: end_per_testcase(TestCase, Config0) ->" n "%% void() | {save_config,Config1}" n "%%" n "%% TestCase = atom()" n "%% Name of the test case that is finished." n "%% Config0 = Config1 = [tuple()]" n "%% A list of key/value pairs, holding the test case configuration." n "%%" n "%% Description: Cleanup after each test case." n (erlang-skel-separator 2) "end_per_testcase(_TestCase, _Config) ->" n > "ok." n n (erlang-skel-separator 2) "%% Function: sequences() -> Sequences" n "%%" n "%% Sequences = [{SeqName,TestCases}]" n "%% SeqName = atom()" n "%% Name of a sequence." n "%% TestCases = [atom()]" n "%% List of test cases that are part of the sequence" n "%%" n "%% Description: Specifies test case sequences." n (erlang-skel-separator 2) "sequences() -> " n > "[]." n n (erlang-skel-separator 2) "%% Function: all() -> TestCases | {skip,Reason}" n "%%" n "%% TestCases = [TestCase | {sequence,SeqName}]" n "%% TestCase = atom()" n "%% Name of a test case." n "%% SeqName = atom()" n "%% Name of a test case sequence." n "%% Reason = term()" n "%% The reason for skipping all test cases." n "%%" n "%% Description: Returns the list of test cases that are to be executed." n (erlang-skel-separator 2) "all() -> " n > "[a_test_case]." n n n (erlang-skel-separator 2) "%% TEST CASES" n (erlang-skel-separator 2) n (erlang-skel-separator 2) "%% Function: TestCase() -> Info" n "%%" n "%% Info = [tuple()]" n "%% List of key/value pairs." n "%%" n "%% Description: Test case info function - returns list of tuples to set" n "%% properties for the test case." n "%%" n "%% Note: This function is only meant to be used to return a list of" n "%% values, not perform any other operations." n (erlang-skel-separator 2) "a_test_case() -> " n > "[]." n n (erlang-skel-separator 2) "%% Function: TestCase(Config0) ->" n "%% ok | exit() | {skip,Reason} | {comment,Comment} |" n "%% {save_config,Config1} | {skip_and_save,Reason,Config1}" n "%%" n "%% Config0 = Config1 = [tuple()]" n "%% A list of key/value pairs, holding the test case configuration." n "%% Reason = term()" n "%% The reason for skipping the test case." n "%% Comment = term()" n "%% A comment about the test case that will be printed in the html log." n "%%" n "%% Description: Test case function. (The name of it must be specified in" n "%% the all/0 list for the test case to be executed)." n (erlang-skel-separator 2) "a_test_case(Config) -> " n > "ok." n) (#$ . -50616))
#@172 Non-nil when this version of Emacs uses a modern version of Font Lock.
This is determined by checking the version of Emacs used, the actual
font-lock code is not loaded.
(defvar erlang-font-lock-modern-p (byte-code "\303Y\203\304\207 \203\n\305Y\207\306U\203\n\307Y\207\310\207" [erlang-emacs-major-version erlang-xemacs-p erlang-emacs-minor-version 20 t 14 19 29 nil] 2) (#$ . 55693))
#@51 Font lock keyword highlighting a function header.
(defvar erlang-font-lock-keywords-func (byte-code "\301\302Q\303\304\305FC\207" [erlang-atom-regexp "^" "\\s *(" 1 font-lock-function-name-face t] 4) (#$ . 56094))
#@65 Font lock keyword highlighting numbers in ASCII form (e.g. $A).
(defvar erlang-font-lock-keywords-dollar (byte-code "\300\301\302EC\207" ["\\(\\$\\([^\\]\\|\\\\\\([^0-7^\n]\\|[0-7]+\\|\\^[a-zA-Z]\\)\\)\\)" 1 font-lock-string-face] 3) (#$ . 56315))
#@46 Font lock keyword highlighting clause arrow.
(defvar erlang-font-lock-keywords-arrow (byte-code "\300\301\302EC\207" ["\\(->\\|:-\\)\\(\\s \\|$\\)" 2 font-lock-function-name-face] 3) (#$ . 56569))
#@62 Font lock keyword highlighting list comprehension operators.
(defvar erlang-font-lock-keywords-lc (byte-code "\300\301\302E\303\301\302ED\207" ["\\(<-\\)\\(\\s \\|$\\)" 1 font-lock-keyword-face "\\(||\\)\\(\\s \\|$\\)"] 4) (#$ . 56772))
#@49 Font lock keyword highlighting Erlang keywords.
(defvar erlang-font-lock-keywords-keywords (byte-code "\300\301\302EC\207" ["\\<\\(a\\(fter\\|ndalso\\)\\|begin\\|c\\(atch\\|ase\\)\\|end\\|fun\\|if\\|o\\(f\\|relse\\)\\|receive\\|try\\|when\\|query\\)\\([^a-zA-Z0-9_]\\|$\\)" 1 font-lock-keyword-face] 3) (#$ . 57015))
#@44 Font lock keyword highlighting attributes.
(defvar erlang-font-lock-keywords-attr (byte-code "\301\302Q\303\304EC\207" [erlang-atom-regexp "^\\(-" "\\)\\s *\\(\\.\\|(\\)" 1 font-lock-function-name-face] 3) (#$ . 57338))
#@172 Font lock keyword highlighting words in single quotes in comments.
This is not the highlighting of Erlang strings and atoms, which
are highlighted by syntactic analysis.
(defvar erlang-font-lock-keywords-quotes (byte-code "\301\302\203\n\303\202 \304\305FC\207" [erlang-font-lock-modern-p "`\\([-+a-zA-Z0-9_:*][-+a-zA-Z0-9_:*]+\\)'" 1 font-lock-reference-face font-lock-keyword-face t] 4) (#$ . 57566))
#@40 Font lock keyword highlighting guards.
(defvar erlang-font-lock-keywords-guards (byte-code "\301\302\203\n\303\202 \304EC\207" [erlang-font-lock-modern-p "\\<\\(\\(is_\\)*\\(atom\\|boolean\\|function\\|binary\\|constant\\|float\\|integer\\|list\\|number\\|p\\(id\\|ort\\)\\|re\\(ference\\|cord\\)\\|tuple\\)\\)\\s *(" 1 font-lock-reference-face font-lock-keyword-face] 3) (#$ . 57979))
#@52 Font lock keyword highlighting built in functions.
(defvar erlang-font-lock-keywords-bifs (byte-code "\300\301\302EC\207" ["\\<\\(a\\(bs\\|live\\|pply\\|tom_to_list\\)\\|binary_to_\\(list\\|term\\)\\|concat_binary\\|d\\(ate\\|isconnect_node\\)\\|e\\(lement\\|rase\\|xit\\)\\|float\\(\\|_to_list\\)\\|g\\(arbage_collect\\|et\\(\\|_keys\\)\\|roup_leader\\)\\|h\\(alt\\|d\\)\\|i\\(nte\\(ger_to_list\\|rnal_bif\\)\\|s_alive\\)\\|l\\(ength\\|i\\(nk\\|st_to_\\(atom\\|binary\\|float\\|integer\\|pid\\|tuple\\)\\)\\)\\|make_ref\\|no\\(de\\(\\|_\\(link\\|unlink\\)\\|s\\)\\|talive\\)\\|open_port\\|p\\(id_to_list\\|rocess\\(_\\(flag\\|info\\)\\|es\\)\\|ut\\)\\|r\\(egister\\(\\|ed\\)\\|ound\\)\\|s\\(e\\(lf\\|telement\\)\\|ize\\|p\\(awn\\(\\|_link\\)\\|lit_binary\\)\\|tatistics\\)\\|t\\(erm_to_binary\\|hrow\\|ime\\|l\\|r\\(ace\\|unc\\)\\|uple_to_list\\)\\|un\\(link\\|register\\)\\|whereis\\)\\s *(" 1 font-lock-keyword-face] 3) (#$ . 58374))
#@106 Font lock keyword highlighting macros.
This must be placed in front of `erlang-font-lock-keywords-vars'.
(defvar erlang-font-lock-keywords-macros (byte-code "\303\304 \305\260\306\n\203\307\202\310E\311\304 \305\260\312\n\203\"\307\202#\310ED\207" [erlang-atom-regexp erlang-variable-regexp erlang-font-lock-modern-p "?\\s *\\(" "\\|" "\\)\\>" 1 font-lock-reference-face font-lock-type-face "^-\\(define\\|ifn?def\\)\\s *(\\s *\\(" 2] 6) (#$ . 59318))
#@114 Font lock keyword highlighting Erlang records.
This must be placed in front of `erlang-font-lock-keywords-vars'.
(defvar erlang-font-lock-keywords-records (byte-code "\301\302Q\303\304E\305\303\306\307F\310\302Q\303\304EE\207" [erlang-atom-regexp "#\\s *" "\\>" 1 font-lock-type-face "\\<[0-9][0-9]?#\\([0-9a-fA_F]+\\)\\>" nil t "^-record(\\s *"] 5) (#$ . 59787))
#@138 Font lock keyword highlighting Erlang variables.
Must be preceded by `erlang-font-lock-keywords-macros' and `-records'
to work properly.
(defvar erlang-font-lock-keywords-vars (byte-code "\302\303Q\304 \203 \305\202\306EC\207" [erlang-variable-regexp erlang-font-lock-modern-p "\\<" "\\>" 1 font-lock-variable-name-face font-lock-type-face] 3) (#$ . 60160))
#@537 Font-lock keywords used by Erlang Mode.
There exists three levels of Font Lock keywords for Erlang:
`erlang-font-lock-keywords-1' - Function headers and reserved keywords.
`erlang-font-lock-keywords-2' - Bifs, guards and `single quotes'.
`erlang-font-lock-keywords-3' - Variables, macros and records.
To use a specific level, please set the variable
`font-lock-maximum-decoration' to the appropriate level. Note that the
variable must be set before Erlang mode is activated.
Example:
(setq font-lock-maximum-decoration 2)
(defvar erlang-font-lock-keywords-1 (append erlang-font-lock-keywords-func erlang-font-lock-keywords-dollar erlang-font-lock-keywords-arrow erlang-font-lock-keywords-keywords) (#$ . 60529))
#@537 Font-lock keywords used by Erlang Mode.
There exists three levels of Font Lock keywords for Erlang:
`erlang-font-lock-keywords-1' - Function headers and reserved keywords.
`erlang-font-lock-keywords-2' - Bifs, guards and `single quotes'.
`erlang-font-lock-keywords-3' - Variables, macros and records.
To use a specific level, please set the variable
`font-lock-maximum-decoration' to the appropriate level. Note that the
variable must be set before Erlang mode is activated.
Example:
(setq font-lock-maximum-decoration 2)
(defvar erlang-font-lock-keywords-2 (append erlang-font-lock-keywords-1 erlang-font-lock-keywords-attr erlang-font-lock-keywords-quotes erlang-font-lock-keywords-guards erlang-font-lock-keywords-bifs) (#$ . 61262))
#@537 Font-lock keywords used by Erlang Mode.
There exists three levels of Font Lock keywords for Erlang:
`erlang-font-lock-keywords-1' - Function headers and reserved keywords.
`erlang-font-lock-keywords-2' - Bifs, guards and `single quotes'.
`erlang-font-lock-keywords-3' - Variables, macros and records.
To use a specific level, please set the variable
`font-lock-maximum-decoration' to the appropriate level. Note that the
variable must be set before Erlang mode is activated.
Example:
(setq font-lock-maximum-decoration 2)
(defvar erlang-font-lock-keywords-3 (append erlang-font-lock-keywords-2 erlang-font-lock-keywords-macros erlang-font-lock-keywords-records erlang-font-lock-keywords-vars) (#$ . 62020))
#@537 Font-lock keywords used by Erlang Mode.
There exists three levels of Font Lock keywords for Erlang:
`erlang-font-lock-keywords-1' - Function headers and reserved keywords.
`erlang-font-lock-keywords-2' - Bifs, guards and `single quotes'.
`erlang-font-lock-keywords-3' - Variables, macros and records.
To use a specific level, please set the variable
`font-lock-maximum-decoration' to the appropriate level. Note that the
variable must be set before Erlang mode is activated.
Example:
(setq font-lock-maximum-decoration 2)
(defvar erlang-font-lock-keywords erlang-font-lock-keywords-3 (#$ . 62748))
#@333 Syntax table used by Font Lock mode.
The difference between this and the standard Erlang Mode
syntax table is that `_' is treated as part of words by
this syntax table.
Unfortunately, XEmacs hasn't got support for a special Font
Lock syntax table. The effect is that `apply' in the atom
`foo_apply' will be highlighted as a bif.
(defvar erlang-font-lock-syntax-table nil (#$ . 63367))
(byte-code "\300\301!\204\n\301\302M\210\300\303!\204\303\304M\210\300\305!\204\305\306M\210\300\307!\204(\307\310M\210\300\207" [fboundp eval-when-compile (macro . #[(&rest rest) "\300\207" [nil] 1]) unless (macro . #[(condition &rest body) "\302\303 BBB\207" [condition body if nil] 4 "(unless CONDITION BODY...): If CONDITION is false, do BODY, else return nil."]) when (macro . #[(condition &rest body) "\302\303 B\304BBB\207" [condition body if progn (nil)] 4 "(when CONDITION BODY...): If CONDITION is true, do BODY, else return nil."]) char-before (macro . #[(&optional pos) "\301\302\303\304BBDD\207" [pos char-after 1- or ((point))] 5 "Return the character in the current buffer just before POS."])] 2)
#@44 Return the current version of Erlang mode.
(defalias 'erlang-version #[nil "t\203 \301\302\"\210\207" [erlang-version message "Erlang mode version %s, written by Anders Lindgren"] 3 (#$ . 64482) nil])
#@2333 Major mode for editing Erlang source files in Emacs.
It knows about syntax and comment, it can indent code, it is capable
of fontifying the source file, the TAGS commands are aware of Erlang
modules, and the Erlang man pages can be accessed.
Should this module, "erlang.el", be installed properly, Erlang mode
is activated whenever an Erlang source or header file is loaded into
Emacs. To indicate this, the mode line should contain the word
"Erlang".
The main feature of Erlang mode is indentation, press TAB and the
current line will be indented correctly.
Comments starting with only one `%' are indented to the column stored
in the variable `comment-column'. Comments starting with two `%':s
are indented with the same indentation as code. Comments starting
with at least three `%':s are indented to the first column.
However, Erlang mode contains much more, this is a list of the most
useful commands:
TAB - Indent the line.
C-c C-q - Indent current function.
M-; - Create a comment at the end of the line.
M-q - Fill a comment, i.e. wrap lines so that they (hopefully)
will look better.
M-a - Goto the beginning of an Erlang clause.
M-C-a - Ditto for function.
M-e - Goto the end of an Erlang clause.
M-C-e - Ditto for function.
M-h - Mark current Erlang clause.
M-C-h - Ditto for function.
C-c C-z - Start, or switch to, an inferior Erlang shell.
C-c C-k - Compile current file.
C-x ` - Next error.
, - Electric comma.
; - Electric semicolon.
Erlang mode check the name of the file against the module name when
saving, whenever a mismatch occurs Erlang mode offers to modify the
source.
The variable `erlang-electric-commands' controls the electric
commands. To deactivate all of them, set it to nil.
There exists a large number of commands and variables in the Erlang
module. Please press `M-x apropos RET erlang RET' to see a complete
list. Press `C-h f name-of-function RET' and `C-h v name-of-variable
RET'to see the full description of functions and variables,
respectively.
On entry to this mode the contents of the hook `erlang-mode-hook' is
executed.
Please see the beginning of the file `erlang.el' for more information
and examples of hooks.
Other commands:
\{erlang-mode-map}
(defalias 'erlang-mode #[nil "\303 \210\304\305\306 \210\307 \210\310 \210\311 \210\312 \210\313 \210\314\n!\210\315 \210\316 \210\317 \210\320 \210\321\322!\210\323\324 !\2057\321\325!\207" [major-mode mode-name erlang-error-regexp-alist kill-all-local-variables erlang-mode "Erlang" erlang-syntax-table-init erlang-keymap-init erlang-electric-init erlang-menu-init erlang-mode-variables erlang-check-module-name-init erlang-add-compilation-alist erlang-man-init erlang-tags-init erlang-font-lock-init erlang-skel-init run-hooks erlang-mode-hook zerop buffer-size erlang-new-file-hook] 2 (#$ . 64694) nil])
(defalias 'erlang-syntax-table-init #[nil "\204|\302 \303\304\305 #\210\303\306\307 #\210\303\310\311 #\210\303\312\313 #\210\303\314\315 #\210\303\316\311 #\210\303\317\307 #\210\303\320\311 #\210\303\321\311 #\210\303\322\311 #\210\303\323\311 #\210\303\324\311 #\210\303\325\311 #\210\303\326\311 #\210\303\327\311 #\210\303\330\331 #\210\303\332\333 #\210\303\334\311 #\210\303\335\313 #\210 )\336!\207" [erlang-mode-syntax-table table make-syntax-table modify-syntax-entry 10 ">" 34 "\"" 35 "." 36 "'" 37 "<" 38 39 42 43 45 47 58 60 61 62 92 "\\" 95 "_" 124 94 set-syntax-table] 4])
(defalias 'erlang-keymap-init #[nil "\204 \301 \302!\210\303!\207" [erlang-mode-map make-sparse-keymap erlang-mode-commands use-local-map] 2])
(defalias 'erlang-mode-commands #[(map) "\303\304!\204\f\305\306\307#\210\305\310\311#\210\305\312\313#\210\305\314\315#\210\305\316\317#\210\305\320\321#\210 \2037\305\322\323#\210\202=\305\324\323#\210\305\325\326#\210\303\327!\204[\305\330\331#\210\305\332\333#\210\305\334\335#\210\305\336\337#\210\305\340\341#\210\305\342\343#\210\305\344\345#\210\305\346\347#\210\305\350\351#\210\305\352\353#\210\305\354\355#\210\305\356\357#\210\305\360\361#\210\305\362\363#\210\305\364\365#\210\305\366\367#\210\305\370\371#\210\305\372\373#\210\305\374\375#\210\305\376\377#\210\305\201@\201A#\210\n?\205\331\305\201B\201C#\207" [map erlang-xemacs-p inferior-erlang-use-cmm boundp indent-line-function define-key " " erlang-indent-command ";" erlang-electric-semicolon "," erlang-electric-comma "<" erlang-electric-lt ">" erlang-electric-gt " " erlang-electric-newline [(backspace)] backward-delete-char-untabify "" "\361" erlang-fill-paragraph beginning-of-defun-function "\201" erlang-beginning-of-function "\205" erlang-end-of-function "\210" erlang-mark-function "\211" erlang-complete-tag "\211" tempo-complete-tag "\253" erlang-find-next-tag "\341" erlang-beginning-of-clause "\342" tempo-backward-mark "\345" erlang-end-of-clause "\346" tempo-forward-mark "\350" erlang-mark-clause "" comment-region "\n" erlang-generate-new-clause " " erlang-compile "\f" erlang-compile-display "" erlang-show-syntactic-information "" erlang-indent-function "" erlang-uncomment-region "" erlang-clone-arguments "" erlang-align-arrows "" erlang-shell-display "`" erlang-next-error] 4])
(defalias 'erlang-electric-init #[nil "\301\302\303\"\210\304\305\306\307#\210\304\305\310\311#\210\304\312\310\313#\210\304\314\310\315#\210\304\316\306\317#\210\304\316\310\320#\210\321\300!\210\322\211\207" [parse-sexp-lookup-properties mapcar #[(cmd) "\301\302\303#\210\301\304\303#\207" [cmd put delete-selection t pending-delete] 4] (erlang-electric-semicolon erlang-electric-comma erlang-electric-gt) put bitsyntax-open-outer syntax-table (4 . 62) rear-nonsticky (category) bitsyntax-open-inner (category) bitsyntax-close-inner (category) bitsyntax-close-outer (5 . 60) (category) make-local-variable t] 4])
(defalias 'erlang-mode-variables #[nil "\204 \306\300\307\"\210\310\303!\210\311\nP\310\304!\210 \310\305!\210\312\310\313!\210\312 \310\314!\2101\f\310\315!\210\316 \310\317!\210\320\310\321!\210\322\310\323!\210\324\310\325!\210\326\310\327!\210\3302\331X\203f\310\332!\210\330\310\333!\210\312\310\334!\210\307\310\335!\210\336\310\337!\210\340\310\341!\210\342!\310\343!\210\336#\310\344!\210\345$\310\346!\210\307&\310\347!\210\350'\310\351!\210\352)\310\353!\210\354+\310\355!\210\356-\310\357!\210\360\211/\207" [erlang-mode-abbrev-table local-abbrev-table page-delimiter paragraph-start paragraph-separate paragraph-ignore-fill-prefix define-abbrev-table nil make-local-variable "^$\\|" t require-final-newline defun-prompt-regexp comment-start "%" comment-start-skip "%+\\s *" comment-column 48 indent-line-function erlang-indent-command indent-region-function erlang-indent-region comment-indent-function erlang-comment-indent 18 comment-indent-hook parse-sexp-ignore-comments dabbrev-case-fold-search imenu-prev-index-position-function erlang-beginning-of-function imenu-extract-index-name-function erlang-get-function-name tempo-match-finder "[^-a-zA-Z0-9_]\\([-a-zA-Z0-9_]*\\)\\=" beginning-of-defun-function end-of-defun-function erlang-end-of-function open-paren-in-column-0-is-defun-start fill-paragraph-function erlang-fill-paragraph comment-add 1 outline-regexp "[[:lower:]0-9_]+ *(.*) *-> *$" outline-level #[nil "\300\207" [1] 1] add-log-current-defun-function erlang-current-defun erlang-defun-prompt-regexp erlang-emacs-major-version] 3])
(defalias 'erlang-add-compilation-alist #[(alist) "\302\303!\210\304\301!\203#\2050\305@@ \"\204@ BA\211\202 \304\306!\2050\307K\306@@\"\207" [alist compilation-error-regexp-alist require compile boundp assoc compilation-error-regexp set] 4])
#@39 Initialize Font Lock for Erlang mode.
(defalias 'erlang-font-lock-init #[nil "\204\306 !\307\310\311\n#\210\n)\312\303!\210\312\304!\210\313\312\314!\210\315\316!\203,\316J\2028\315\317!\2037\317J\2028\320\211:\203I\321 \236\206G\322 \236\243 \320=\203V\f\202t \323=\203c\f\202t \324=\203p\f\202t\f)\312\325!\210\326\211\207" [erlang-font-lock-syntax-table erlang-mode-syntax-table table font-lock-syntax-table font-lock-beginning-of-syntax-function level copy-syntax-table modify-syntax-entry 95 "w" make-local-variable erlang-beginning-of-clause font-lock-keywords boundp font-lock-maximum-decoration font-lock-use-maximal-decoration nil erlang-mode t 1 2 font-lock-defaults ((erlang-font-lock-keywords erlang-font-lock-keywords-1 erlang-font-lock-keywords-2 erlang-font-lock-keywords-3) nil nil ((95 . "w")) erlang-beginning-of-clause (font-lock-mark-block-function . erlang-mark-clause)) erlang-font-lock-keywords erlang-font-lock-keywords-1 erlang-font-lock-keywords-2 erlang-font-lock-keywords-3] 5 (#$ . 72498)])
#@1301 Replace the face components in a list of keywords.
The first argument, KS, is a list of keywords. The rest of the
arguments are expressions to replace the face information with. The
first expression replaces the face of the first keyword, the second
expression the second keyword etc.
Should an expression be nil, the face of the corresponding keyword is
not changed.
Should fewer expressions than keywords be given, the last expression
is used for all remaining keywords.
Normally, the expressions are just atoms representing the new face.
They could however be more complex, returning different faces in
different situations.
This function only handles keywords with elements on the forms:
(REGEXP NUMBER FACE)
(REGEXP NUMBER FACE OVERWRITE)
This could be used when defining your own special font-lock setup, e.g:
(setq my-font-lock-keywords
(append erlang-font-lock-keywords-func
erlang-font-lock-keywords-dollar
(erlang-font-lock-set-face
erlang-font-lock-keywords-macros 'my-neon-green-face)
(erlang-font-lock-set-face
erlang-font-lock-keywords-lc 'my-deep-red 'my-light-red)
erlang-font-lock-keywords-attr))
For a more elaborate example, please see the beginning of the file
`erlang.el'.
(defalias 'erlang-font-lock-set-face #[(ks &rest faces) "\306 \203U @@ @A@\f\203\f@\203\f@\202\" @AA@ @AAA@\n E\203=C\244\210B A\f\203Q\fA\203Q\fA-\202\237)\207" [res ks regexp number faces new-face nil overwrite new-keyword] 3 (#$ . 73562)])
#@27 Unfontify current buffer.
(defalias 'erlang-font-lock-level-0 #[nil "\300\301!\207" [font-lock-mode 0] 2 (#$ . 75144) nil])
#@111 Fontify current buffer at level 1.
This highlights function headers, reserved keywords, strings and comments.
(defalias 'erlang-font-lock-level-1 #[nil "\302\303!\210\304\305!\210\306K \207" [erlang-font-lock-keywords-1 font-lock-keywords require font-lock font-lock-mode 1 font-lock-fontify-buffer] 2 (#$ . 75275) nil])
#@141 Fontify current buffer at level 2.
This highlights level 1 features (see `erlang-font-lock-level-1')
plus bifs, guards and `single quotes'.
(defalias 'erlang-font-lock-level-2 #[nil "\302\303!\210\304\305!\210\306K \207" [erlang-font-lock-keywords-2 font-lock-keywords require font-lock font-lock-mode 1 font-lock-fontify-buffer] 2 (#$ . 75605) nil])
#@138 Fontify current buffer at level 3.
This highlights level 2 features (see `erlang-font-lock-level-2')
plus variables, macros and records.
(defalias 'erlang-font-lock-level-3 #[nil "\302\303!\210\304\305!\210\306K \207" [erlang-font-lock-keywords-3 font-lock-keywords require font-lock font-lock-mode 1 font-lock-fontify-buffer] 2 (#$ . 75965) nil])
#@361 Init menus for Erlang mode.
The variable `erlang-menu-items' contain a description of the Erlang
mode menu. Normally, the list contains atoms, representing variables
bound to pieces of the menu.
Personal extensions could be added to `erlang-menu-personal-items'.
This function should be called if any variable describing the
menu configuration is changed.
(defalias 'erlang-menu-init #[nil "\302\303 \304$\207" [erlang-menu-items erlang-mode-map erlang-menu-install "Erlang" t] 5 (#$ . 76322)])
#@857 Install a menu in Emacs or XEmacs based on an abstract description.
NAME is the name of the menu.
ITEMS is a list. The elements are either nil representing a horizontal
line or a list with two or three elements. The first is the name of
the menu item, the second the function to call, or a submenu, on the
same same form as ITEMS. The third optional element is an expression
which is evaluated every time the menu is displayed. Should the
expression evaluate to nil the menu item is ghosted.
KEYMAP is the keymap to add to menu to. (When using XEmacs, the menu
will only be visible when this menu is the global, the local, or an
activate minor mode keymap.)
If POPUP is non-nil, the menu is bound to the XEmacs `mode-popup-menu'
variable, i.e. it will popup when pressing the right mouse button.
Please see the variable `erlang-menu-base-items'.
(defalias 'erlang-menu-install #[(name items keymap &optional popup) "\203'\306 \n #\307K\310\f\"\210 \fA\241\210\205%\311\312!\205%\313K\312 \")\207\314Y\203<\315 \316\317\320 !\"\321 \n\"#\207\310\207" [erlang-xemacs-p name items keymap menu erlang-xemacs-popup-menu erlang-menu-xemacs add-submenu nil boundp mode-popup-menu set 19 define-key vector menu-bar intern erlang-menu-make-keymap popup erlang-emacs-major-version] 6 (#$ . 76829)])
#@28 Build a menu for Emacs 19.
(defalias 'erlang-menu-make-keymap #[(name items) "\306K!\307\310\211\211\211\211\311!\211\203\335\203Y@:\204Y@\203Y\312@!\203P@J<\203P\313\311@J!A\"\211\202A\211\204\"@\242@\243\242@\243\243\242 \204\201T\314\315\316\"!\317\202\301\n:\203\241\n@\320=\203\241T\314\315\321\"! \nB\202\301\n9\203\257\n \nB\202\301T\314\315\322\"!\323 \n\"\324\325 !\f#\210 \203\324\326 \327 #\210A\211\204.B\207" [name third second first def id make-sparse-keymap 0 nil reverse boundp append intern format "separator-%d" ("--") lambda "lambda-%d" "submenu-%d" erlang-menu-make-keymap define-key vector put menu-enable count menumap items] 8 (#$ . 78144)])
#@26 Build a menu for XEmacs.
(defalias 'erlang-menu-xemacs #[(name items &optional keymap) "\306\211\211\211\211 \203\234 \203@ @:\204@ @\203@\307 @!\2039 @J<\2039\310\311 @J! A\"\211\202 A\211\204 @\242 @\243\242 @\243\243\242 \204Z\312\fB\202\225\n9\203n\313 \n \206g\314#\fB\202\225\n:\203\213\n@\315=\203\213\313 \316\nD \206\204\314#\fB\202\225 \317 \n\"AB\fB A\211\204\311\f!\203\305\320\321\322E\321\323CE\324\325\326\327EDDF\330\fBB)\f-B\207" [entry third second first res items nil boundp append reverse "------" vector t lambda call-interactively erlang-menu-xemacs or eq global-map current-local-map symbol-value car-safe rassq minor-mode-map-alist :included keymap expr name] 9 (#$ . 78913)])
#@167 Substitute functions in menu described by ITEMS.
The menu ITEMS is updated destructively.
ALIST is list of pairs where the car is the old function and cdr the new.
(defalias 'erlang-menu-substitute #[(items alist) "\305\211\211 \205K @\242 @\243\242\n\203C 9\2032 \205# \f\236\211\203C @AA\240\210\202C :\203> @\306=\204C\307 \f\"\210 A\211\204\n\305+\207" [pair second first items alist nil lambda erlang-menu-substitute] 4 (#$ . 79674)])
#@434 Add menu ENTRY above menu entry ABOVE in menu ITEMS.
Do nothing if the items already should be in the menu.
Should ABOVE not be in the list, the entry is added at
the bottom of the menu.
The new menu is returned. No guarantee is given that the original
menu is left unchanged.
The equality test is performed by `eq'.
Example: (erlang-menu-add-above 'my-erlang-menu-items
'erlang-menu-man-items)
(defalias 'erlang-menu-add-above #[(entry above items) "\303 \n\304$\207" [entry above items erlang-menu-add-below t] 5 (#$ . 80140)])
#@497 Add menu ENTRY below menu items BELOW in the Erlang menu.
Do nothing if the items already should be in the menu.
Should BELOW not be in the list, items is added at the bottom
of the menu.
The new menu is returned. No guarantee is given that the original
menu is left unchanged.
The equality test is performed by `eq'.
Example:
(setq erlang-menu-items
(erlang-menu-add-below 'my-erlang-menu-items
'erlang-menu-base-items
erlang-menu-items))
(defalias 'erlang-menu-add-below #[(entry below items &optional above-p) " >\203 \207\306\211\211 \204U \204\"\307\fC\"\310\211\202 @=\203H \2037\307\f B\"\202A\307\f @ ABB\"\310\211\202\307\f @C\" A\202\n+\207" [entry items res done head below nil append t above-p] 6 (#$ . 80716)])
#@123 Delete ENTRY from menu ITEMS.
The new menu is returned. No guarantee is given that the original
menu is left unchanged.
(defalias 'erlang-menu-delete #[(entry items) "\302 \"\207" [entry items delq] 3 (#$ . 81531)])
#@148 Add menus containing the manual pages of the Erlang.
The variable `erlang-man-dirs' contains entries describing
the location of the manual pages.
(defalias 'erlang-man-init #[nil "?\205\304\n\203\305 \306\n!\"\307\301\310 #\311 \207" [erlang-man-inhibit erlang-menu-man-items erlang-man-dirs erlang-menu-items (nil ("Man - Function" erlang-man-function)) append erlang-man-make-top-menu erlang-menu-add-above erlang-menu-version-items erlang-menu-init] 4 (#$ . 81757) nil])
#@44 Remove the man pages from the Erlang mode.
(defalias 'erlang-man-uninstall #[nil "\301\302\"\303 \207" [erlang-menu-items erlang-menu-delete erlang-menu-man-items erlang-menu-init] 3 (#$ . 82246) nil])
#@115 Create one menu entry per element of DIR-LIST.
The format is described in the documentation of `erlang-man-dirs'.
(defalias 'erlang-man-make-top-menu #[(dir-list) "\304\211\n\203?\305\n@8\203 ;\205! \n@A@P\202!\n@A@\211\2038\306!\2038\n@@\307\310!!D B\nA\211\204 \203H \237\202I\311*\207" [dir menu dir-list erlang-root-dir nil 2 file-readable-p erlang-man-make-middle-menu erlang-man-get-files (("Man Pages" (("Error! Why?" erlang-man-describe-error))))] 5 (#$ . 82457)])
#@133 Create the second level menu from FILELIST.
Should the list be longer than `erlang-man-max-menu-size', a tree of
menus is created.
(defalias 'erlang-man-make-middle-menu #[(filelist) "G X\203 \306!\207\307\310!\307\211\211\203H S\233\n\204+\307\2022\nA\n\307\241\210\306\f!\211@@\311\312 !@@Q D B\202 \237-\207" [filelist erlang-man-max-menu-size pair submenu segment menu erlang-man-make-menu nil copy-sequence " -- " reverse] 6 (#$ . 82955)])
#@37 Make a leaf menu based on FILELIST.
(defalias 'erlang-man-make-menu #[(filelist) "\303\211\n\203\304\n@!\211\203 B\nA\211\204 \237*\207" [item menu filelist nil erlang-man-make-menu-item] 3 (#$ . 83430)])
#@57 Create a menu item containing the name of the man page.
(defalias 'erlang-man-make-menu-item #[(file) "\302\303\"\205\304\224\304\225O\305 !\306\307\310\311\312EF)D\207" [file page string-match ".*/\\([^/]+\\)\\.[^.]$" 1 capitalize lambda nil (interactive) funcall erlang-man-display-function] 7 (#$ . 83653)])
#@32 Return files in directory DIR.
(defalias 'erlang-man-get-files #[(dir) "\301\302\303#\207" [dir directory-files t ".*\\.[0-9]\\'"] 4 (#$ . 83976)])
#@120 Find manual page for MODULE, defaults to module of function under point.
This function is aware of imported functions.
(defalias 'erlang-man-module #[(&optional module) "\204\306 @\203\307\230\203\310\311!\210 \312\313!\314Q\315\211\211\203d \204d\316\317 @8\203= @A@P\202A @A@!\211\203] \204]\320\f\n@\"\203V\n@\nA\211\204G A\211\204' \203o !\202s\310\321\",\207" [module erlang-man-dirs file-list file pat dir-list erlang-get-function-under-point "" error "No Erlang module name given" "/" regexp-quote "\\.[^.]$" nil erlang-man-get-files 2 string-match "No manual page for module %s found" erlang-root-dir erlang-man-display-function] 5 (#$ . 84132) (list (let* ((mod (car-safe (erlang-get-function-under-point))) (input (read-string (format "Manual entry for module%s: " (if (or (null mod) (string= mod "")) "" (format " (default %s)" mod)))))) (if (string= input "") mod input)))])
#@150 Name of function for last `erlang-man-function' call.
Used for communication between `erlang-man-function' and the
patch to `Man-notify-when-ready'.
(defvar erlang-man-function-name nil (#$ . 85061))
#@145 Find manual page for NAME, where NAME is module:function.
The entry for `function' is displayed.
This function is aware of imported functions.
(defalias 'erlang-man-function #[(&optional name) "\305\306\307\217\210\305\211\n\204\310 \211\242 A@)\2028\311\312\n\"\2031\n\313\211\224O\n\313\225\305O\2028\n;\2038\n \203B \314\230\203F\315\316!\210\317\320!\203\\\203U\321 \210\305\322\323\217\202n\324 !\210\205n\325\326\327!\206lp\"*\207" [funcname modname name mod-func erlang-man-function-name nil (byte-code "\300\301!\207" [require man] 2) ((error)) erlang-get-function-under-point string-match ":" 0 "" error "No Erlang module name given" fboundp Man-notify-when-ready erlang-man-patch-notify (erlang-man-module modname) ((error (byte-code "\301\211\207" [erlang-man-function-name nil] 2))) erlang-man-module erlang-man-find-function get-buffer "*Manual Entry*"] 4 (#$ . 85268) (list (let* ((mod-func (erlang-get-function-under-point)) (mod (car-safe mod-func)) (func (nth 1 mod-func)) (input (read-string (format "Manual entry for `module:func' or `module'%s: " (if (or (null mod) (string= mod "")) "" (format " (default %s:%s)" mod func)))))) (if (string= input "") (if (and mod func) (concat mod ":" func) mod) input)))])
#@268 Patch the function `Man-notify-when-ready' to search for function.
The variable `erlang-man-function-name' is assumed to be bound to
the function name, or to nil.
The reason for patching a function is that under Emacs 19, the man
command is executed asynchronously.
(defalias 'erlang-man-patch-notify #[nil "\300\301\302\217\210\303\304!\210\305\306\307\310\300$\210\311\306\300\"\210\306\207" [nil (byte-code "\300\301!\207" [require advice] 2) ((error (error "This command needs the package `advice', please upgrade your Emacs."))) require man ad-add-advice Man-notify-when-ready (erlang-Man-notify-when-ready nil t (advice lambda nil "Set point at the documentation of the function name in\n`erlang-man-function-name' when the man page is displayed." (if erlang-man-function-name (erlang-man-find-function (ad-get-arg 0) erlang-man-function-name)) (setq erlang-man-function-name nil))) after ad-activate] 5 (#$ . 86532)])
#@76 Find manual page for function in `erlang-man-function-name' in buffer BUF.
(defalias 'erlang-man-find-function #[(buf func) "\205,\303 !\211\205+ q\210eb\210\304\305\306Qd\307#\203'\310v\210\311\n`\"\202+\312\313\")\207" [func buf win get-buffer-window re-search-forward "^[ ]+" " ?(" t -1 set-window-point message "Could not find function `%s'"] 5 (#$ . 87464)])
#@159 Display FILE as a `man' file.
This is the default manual page display function.
The variables `erlang-man-display-function' contains the function
to be used.
(defalias 'erlang-man-display #[(file) "\306\307\310\217\210\205Z\311 !\312\313\"\203U\314\224\314\225O\315\224\315\225O\316\317!\2030\317\320 \"\210\2026\321 P B\f\204G \322U\203G\323W\204M\324\n!\202Q\325K\n!*\202Y\326\327\")\207" [file process-environment page dir erlang-xemacs-p erlang-emacs-major-version nil (byte-code "\300\301!\207" [require man] 2) ((error)) copy-sequence string-match "\\(.*\\)/man[^/]*/\\([^/]+\\)\\.[^.]$" 1 2 fboundp setenv "MANPATH" "MANPATH=" 19 29 manual-entry Man-getpage-in-background error "Can't find man page for %s\n" erlang-emacs-minor-version] 4 (#$ . 87844)])
#@46 Describe why the manual pages weren't found.
(defalias 'erlang-man-describe-error #[nil "\300\220\301\302!\221\207" ["*Erlang Man Error*" princ "Normally, this menu should contain Erlang manual pages.\n\nIn order to find the manual pages, the variable `erlang-root-dir'\nshould be bound to the name of the directory containing the Erlang\ninstallation. The name should not include the final slash.\n\nPractically, you should add a line on the following form to\nyour ~/.emacs, or ask your system administrator to add it to\nthe site init file:\n (setq erlang-root-dir \"/the/erlang/root/dir/goes/here\")\n\nFor example:\n (setq erlang-root-dir \"/usr/local/erlang\")\n\nAfter installing the line, kill and restart Emacs, or restart Erlang\nmode with the command `M-x erlang-mode RET'."] 3 (#$ . 88631) nil])
#@251 Generate the skeleton functions and menu items.
The variable `erlang-skel' contains the name and descriptions of
all skeletons.
The skeleton routines are based on the `tempo' package. Should this
package not be present, this function does nothing.
(defalias 'erlang-skel-init #[nil "\305\306\307\217\210\310\311!\205R\305\211\203B\n@\204\305 B\202;\312K\313\n@A@P\314\315\n@8DC\n@A@#\210\316\n@! B\nA\211\204\305\317 \237DD\320\303\321\f#\322 *\207" [erlang-skel menu skel erlang-menu-skel-items erlang-menu-items nil (byte-code "\300\301!\207" [require tempo] 2) ((error)) featurep tempo tempo-define-template "erlang-" erlang-skel-include 2 erlang-skel-make-menu-item "Skeletons" erlang-menu-add-above erlang-menu-version-items erlang-menu-init] 6 (#$ . 89453) nil])
(defalias 'erlang-skel-make-menu-item #[(skel) "\302\303A@P!\3048\204@ D\202&@\305\306\307\310\311\3048D\311 DEFD)\207" [skel func intern "tempo-template-erlang-" 3 lambda nil (interactive) funcall quote] 8])
#@62 Insert skeleton generated by FUNC and goto first tempo mark.
(defalias 'erlang-skel-insert #[(func) "\212 \210)\301K \207" [func tempo-forward-mark] 1 (#$ . 90463)])
#@69 Insert the header generated by FUNC at the beginning of the buffer.
(defalias 'erlang-skel-header #[(func) "eb\210\212 \210)\301K \207" [func tempo-forward-mark] 1 (#$ . 90636)])
(defalias 'erlang-skel-skip-blank #[nil "\300\301x\210\301\207" [" " nil] 2])
#@423 Include a template inside another template.
Example of use, assuming that `erlang-skel-func' is defined:
(defvar foo-skeleton '("%%% New function:"
(erlang-skel-include erlang-skel-func)))
Technically, this function returns the `tempo' attribute`(l ...)' which
can contain other `tempo' attributes. Please see the function
`tempo-define-template' for a description of the `(l ...)' attribute.
(defalias 'erlang-skel-include #[(&rest args) "\303\211\n\203\"\n@\211\203@ BA\211\204\nA\211\204\304 \237*B\207" [entry res args nil l] 3 (#$ . 90902)])
#@29 Return a comment separator.
(defalias 'erlang-skel-separator #[(&optional percent) "\206\301\302\303\"\302\304Z\305\"\306Q)\207" [percent 3 make-string 37 70 45 "\n"] 4 (#$ . 91499)])
#@29 Return a comment separator.
(defalias 'erlang-skel-double-separator #[(&optional percent) "\206\301\302\303\"\302\304Z\305\"\306Q)\207" [percent 3 make-string 37 70 61 "\n"] 4 (#$ . 91695)])
#@125 Return the current date as a string in "DD Mon YYYY" form.
The first character of DD is space if the value is less than 10.
(defalias 'erlang-skel-dd-mmm-yyyy #[nil "\301 \302\303\304\305\306O!\307\310O\311\312O$)\207" [date current-time-string format "%2d %s %s" string-to-int 8 10 4 7 -4 nil] 7 (#$ . 91899)])
#@128 Indent current line as Erlang code.
With argument, indent any additional lines of the same clause
rigidly along with this one.
(defalias 'erlang-indent-command #[(&optional whole-exp) "\2032\305 \306\211\212\f\203\307 \210`\310\311!\210`\nb\210\311y\210`) \nV\2050\312\n \313$+\207\f\204C\212\314\306x\210n)\204C\315 \207\305 \207" [whole-exp end beg shift-amt erlang-tab-always-indent erlang-indent-line nil beginning-of-line erlang-end-of-clause 1 indent-code-rigidly "\n" " " insert-tab] 5 (#$ . 92222) "P"])
#@83 Indent current line as Erlang code.
Return the amount the indentation changed by.
(defalias 'erlang-indent-line #[nil "d`Z\305\211\211\306\307!\210`\310\305w\210\311\312!\203$\f \211iZ\202L\313 \211\2041\314 \202H\n\315=\203>\316\317!\210\202Hgz\320U\203H\nS\niZ\321!\204Y `|\210\nj\210d Z`V\203fd Zb\210,\207" [shift-amt beg indent pos comment-indent-function nil beginning-of-line 1 " " looking-at "%" erlang-calculate-indent current-indentation t error "Erlang mode error" 41 zerop] 5 (#$ . 92755)])
#@105 Indent region of Erlang code.
This is automagically called by the user level function `indent-region'.
(defalias 'erlang-indent-region #[(beg end) "\212\306\307dZ\306\211\211b\210\310 \210`\311 \210` W\203+\312` #\202 \205\254 b\210\313\306w\210\314\315!\203C \202v\314\316!\203N\317\202v\212\320` \")\211\204_\321 \202v\n\307=\203l\322\323!\210\202vgz\324U\203v\nS\325\niZ!\204\205 `|\210\nj\210 b\210\212\326y\210`)\fd ZY\203\235\306\211\202,` W\203+\312` #\202\235.\207" [end state indent indent-point from-end continue nil t beginning-of-line erlang-beginning-of-clause erlang-partial-parse " " looking-at "%" "$" 0 erlang-calculate-stack-indent current-indentation error "Erlang mode error" 41 zerop 1 case-fold-search beg comment-indent-function] 7 (#$ . 93288) "r"])
#@39 Indent current buffer as Erlang code.
(defalias 'erlang-indent-current-buffer #[nil "\212\214~\210\300ed\"*\207" [erlang-indent-region] 3 (#$ . 94113) nil])
#@33 Indent current Erlang function.
(defalias 'erlang-indent-function #[nil "\212\302\303!\210`\304\303!\210`\305 \"+\207" [beg end erlang-end-of-function 1 erlang-beginning-of-function erlang-indent-region] 3 (#$ . 94276) nil])
#@31 Indent current Erlang clause.
(defalias 'erlang-indent-clause #[nil "\212\302\303!\210`\304\303!\210`\305 \"+\207" [beg end erlang-end-of-clause 1 erlang-beginning-of-clause erlang-indent-region] 3 (#$ . 94510) nil])
(defalias 'erlang-push '(macro . #[(x stack) "\302\303 EE\207" [stack x setq cons] 5]))
(defalias 'erlang-pop '(macro . #[(stack) "\301\302DE\207" [stack setq cdr] 4]))
(defalias 'erlang-caddr #[(x) "AA@\207" [x] 1])
#@126 Compute appropriate indentation for current line as Erlang code.
Return nil if line starts inside string, t if in a comment.
(defalias 'erlang-calculate-indent #[(&optional parse-start) "\212`\304\211 \203 b\210\202\305 \210`\nW\203#\306`\n#\202\307\n\",\207" [state case-fold-search indent-point parse-start nil erlang-beginning-of-clause erlang-partial-parse erlang-calculate-stack-indent] 4 (#$ . 94959)])
#@46 Show syntactic information for current line.
(defalias 'erlang-show-syntactic-information #[nil "\212`\303\211\304 \210`\nW\203\305`\n#\202\n\306\307\",\207" [state case-fold-search starting-point nil erlang-beginning-of-clause erlang-partial-parse message "%S"] 4 (#$ . 95387) nil])
#@126 Parse Erlang syntax starting at FROM until TO, with an optional STATE.
Value is list (stack token-start token-type in-what).
(defalias 'erlang-partial-parse #[(from to &optional state) "b\210\306 !\210gz\n@`\307@\f Y\203(\nA@\310\n8@\311\n8\202\321@\312U\203&\313\314!\203Z \203H @@\315=\203H A\211\2049 \203\202 @@\316>\203\202 A\202\202\313\317!\203\202 \203s @@\315=\203s A\211\204d \203\202 @@\320>\203\202 A\313\321!\203\222\322\fiE B\202\313\323!\203\262\212\324\225b\210\306 !\210g)\325=\203\322\fiE B\202\313\326!\203\302\327\fiE B\202\313\330!\204\313\331!\204\313\332!\204\313\333!\203\344\334\fiE B\202\313\335!\203\364\322\fiE B\202\313\336!\203 \322\fiE B\315\fiE B\202\313\317!\203\322\fiE B\315\fiE B\337\324!\210\202\321@\340U\2035\307\341\342\217\210\202\321@\343U\203Ng\340U\203H\324u\210\202\321\324u\210\202\321@\344>\203<g\345U\203p \203j @@\315=\203j A\324u\210\202\321\313\346!\203~\307\324u\210\202\321\313\347!\203\256\212\350 \210\313\351!\203\221 A) \203\241 @@\334=\203\241 A\315\fiE B\310u\210\202\321\313\352!\203\301\353\fiE B\310u\210\202\321\313\354!\203\315\324u\210\202\321\313\355!\203\340\356\fiE B\310u\210\202\321\313\357!\203 @@\360>\203\365 A\211\202\347 @@\356=\203 A\202 @@\361>\203\362\363!\210\202\362\364!\210\310u\210\202\321g\365U\203(\324u\210\202\321@\366U\2036\367\370!\210\202\321\324u\210\202\321@\325U\203P\356\fiE B\324u\210\202\321@\371U\203\256 @@\372>\203f A\211\202X @@\356=\203t A\202\250 @@\322=\203\226 A\211@@\356=\203\215 A\202\250\373\362\363!!\210\202\250 @@\327=\203\250\362\363!\210\374\362\375!!\210\324u\210\202\321@\376U\203\273\310u\210\202\321@\377U\203\316\324u\210\367\201A!\210\202\321\324u\210 \f@ F,\207" [from to state in-what token stack erlang-skip-blank nil 2 3 119 looking-at "\\(end\\|after\\)[^_a-zA-Z0-9]" -> (icr begin) "catch[^,\n\\of]*\n" (icr begin) "\\(if\\|case\\|receive\\|try\\)[^_a-zA-Z0-9]" icr "\\(fun\\)[^_a-zA-Z0-9]" 1 40 "\\(begin\\|query\\)[^_a-zA-Z0-9]" begin "when[^->.]*if[^->.]*->" "when[^->.]*case[^->.]*->" "when[^->.]*receive[^->.]*->" "when [^->.]*->" when "after[.]+->" "after[^_a-zA-Z0-9->]" forward-sexp 34 (byte-code "\302\303!\210`V\203\304b\210\302\207" [to in-what forward-sexp 1 string] 2) ((error (byte-code "\302 b\207" [in-what to string] 1))) 39 (46 95) 59 "\\.\\(\\s \\|\n\\|\\s<\\)" "->\\|:-" back-to-indentation "after[^_a-zA-Z0-9]" "||" || "," "<<" \( ">>" (|| ->) (icr begin) error "Missing `end'" "Unbalanced parentheses" 63 46 skip-syntax-forward "." 41 (|| ->) else t "Unbalanced parenthesis" 47 92 cs "w"] 5 (#$ . 95687)])
#@119 From the given last position and state (stack) calculate indentation.
Return nil if inside string, t if in a comment.
(defalias 'erlang-calculate-stack-indent #[(indent-point state) "\205@A@ \205 @\204\306\202\351\3078\203(\3078\310=\202\351 \204:\311\312!\2036\f\202\351\306\202\351 @\313=\203l \204L\314 8T\202\351 A@b\210\311\315!\203^\316 \\\202\351 A@Tb\210\317\320w\210i\202\351 @\321=\203\351\311\322!\203\200\314 8\210\202\254\212 A@b\210\311\323!\203\226\314 8)\\\210\202\253\324\320w\210\317\320w\210g\325>\203\253\314 8)\\\210)\311\326!\203\270\314 8\202\351\212 A@b\210\311\323!\203\315\314 8)\\\202\345\324\320w\210\317\320w\210g\327>\203\344\314 8)\\\202\345i)\202\351 @\330>\203\233 A@b\210)\314*+ A\203 @\331=\203\332*\202 @\333=\203)\211\\\306\\+\334 ,+*$-\nb\210\311\335!\2036-\202\227\336 \203Bi)\\\202\227gz\337U\204N\340 \203V-)\\\202\227,b\210g\341>\203g\316 \\\202\227\311\342!\203\207 @@\333=\203x A \203\203\343 @!\202\227\306\202\227g\344U\203\222-\202\227-)\\+\202\351 @\345=\205\351 A@b\210\311\346!\203\341 A\211\203\335 @@\321=\203\335 @A@b\210\314 @8\f\\\311\347!\203\323)\202\331)\211\\\306\\\\\202\351\f\202\351\350u\210\317\320w\210i+\207" [state stack token stack-top erlang-indent-guard erlang-argument-indent 0 3 comment looking-at "when[^_a-zA-Z0-9]" \( 2 "[({]\\s *\\($\\|%\\)" erlang-indent-find-preceding-expr " " nil icr "after[^_a-zA-Z0-9]" "case[^_a-zA-Z0-9]" "a-z" (37 10) "catch[^_a-zA-Z0-9]" (37 10) (-> || begin) begin 5 -> erlang-indent-find-base "||\\|,\\|->\\|:-" erlang-at-keyword 46 erlang-at-operator (40 123) "\\(end\\|after\\|catch\\)[^_a-zA-Z0-9]\\|$" erlang-caddr 37 when "when\\s *\\($\\|%\\)" "[a-z]+\\s *\\($\\|%\\)" 4 erlang-indent-level skip off indent-point base] 6 (#$ . 98403)])
#@41 Find the base column for current stack.
(defalias 'erlang-indent-find-base #[(stack indent-point &optional offset skip) "\204\306 \204\f\n\212 @\211A@b\210u\210\307\310!\2039\f@\311>\203( A \2035\312 @! \\\202>\n\202>\313 !\210i*\207" [skip offset erlang-indent-level stack stack-top indent-point 2 looking-at "\\s *\\($\\|%\\)" (-> ||) erlang-caddr erlang-skip-blank] 3 (#$ . 100258)])
#@147 Return the first column of the preceding expression.
This assumes that the preceding expression is either simple
(i.e. an atom) or parenthesized.
(defalias 'erlang-indent-find-preceding-expr #[nil "\212\301\302!\210i\303\304x\210h\305>\204\202\302u\210\301\302!\210i*\207" [col forward-sexp -1 " " nil (35 58)] 2 (#$ . 100666)])
#@56 Skip over whitespace and comments until limit reached.
(defalias 'erlang-skip-blank #[(&optional lim) "\204d\302 \204F`W\203Fg\303U\203\304w\210\202g\305U\203,\306w\210\202\307\310!\203@\311\312\313#\203\314u\210\202\315\211\203\f )\207" [lim stop nil 37 "^\n" 10 "\n" looking-at "\\s " re-search-forward "\\S " move -1 t] 5 (#$ . 101008)])
#@70 Are we looking at an Erlang keyword which will increase indentation?
(defalias 'erlang-at-keyword #[nil "\300\301!\207" [looking-at "\\(when\\|if\\|fun\\|case\\|begin\\|query\\|of\\|receive\\|after\\|catch\\)[^_a-zA-Z0-9]"] 2 (#$ . 101380)])
#@39 Are we looking at an Erlang operator?
(defalias 'erlang-at-operator #[nil "\300\301!\207" [looking-at "\\(bnot\\|div\\|mod\\|band\\|bor\\|bxor\\|bsl\\|bsr\\)[^_a-zA-Z0-9]"] 2 (#$ . 101628)])
#@118 Compute Erlang comment indentation.
Used both by `indent-for-comment' and the Erlang specific indentation
commands.
(defalias 'erlang-comment-indent #[nil "\301\302!\203\303\207\301\304!\203\305 \206(\306 \207\212\307\310x\210n\203#\303\202%iT])\207" [comment-column looking-at "%%%" 0 "%%" erlang-calculate-indent current-indentation " " nil] 2 (#$ . 101826)])
#@135 Move backward to previous start of clause.
With argument, do this that many times.
Return t unless search stops due to end of buffer.
(defalias 'erlang-beginning-of-clause #[(&optional arg) "\204\302\303W\203(o\203\304\305!\204(\302u\210\202(\306u\210\304\307!\203(\302u\210\310\311\312\313[$\205>\314\224\211\203< b\210)\315\207" [arg beg 1 0 looking-at "\n" -1 "\\`\n" re-search-forward "\\(\\`\\|\\`\n\\|[^\\]\n\\)\\([a-z]\\|'\\|-\\)" nil move 2 t] 6 (#$ . 102205) "p"])
#@80 Move to the end of the current clause.
With argument, do this that many times.
(defalias 'erlang-end-of-clause #[(&optional arg) "\204\302\303\304!\203\305\302y!\204\306[!\210\307 \210\310o?\205; \205;\311y\210\312\313w\210\303\314!\204\313\210\313\202)\207" [arg continue 1 looking-at "[ ]*[%\n]" zerop erlang-beginning-of-clause beginning-of-line t -1 " " nil "[%\n]"] 2 (#$ . 102700) "p"])
#@48 Put mark at end of clause, point at beginning.
(defalias 'erlang-mark-clause #[nil "\300`!\210\301\302!\210\303\304\305\217\210\306\302!\210\307\310!\205\311K\310\303\"\207" [push-mark erlang-end-of-clause 1 nil (byte-code "\300`\301\302#\207" [push-mark nil t] 4) ((error (byte-code "\300`!\207" [push-mark] 2))) erlang-beginning-of-clause boundp deactivate-mark set] 3 (#$ . 103119) nil])
#@187 Move backward to previous start of function.
With positive argument, do this that many times.
With negative argument, search forward.
Return t unless search stops due to end of buffer.
(defalias 'erlang-beginning-of-function #[(&optional arg) "\204\305\306V\203H\306V\203\217\307\305!\203\217`\310 \311 \307\305!\203=\n\310 \230\203= \203= \311 \232\203=`\202 b\210+S\211\202 \306W\203\217\312\210\307\305!\210\306W\203\217\310 \311 \307\313!\f\203\203\n\310 \230\203\203 \203\203 \311 \232\203\203\307\313!\211\204i\f+\203\217T\211\202V\314!\207" [arg arity name start found 1 0 erlang-beginning-of-clause erlang-name-of-function erlang-get-function-arity nil -1 zerop] 5 (#$ . 103519) "p"])
#@143 Move forward to next end of function.
With argument, do this that many times.
With negative argument go towards the beginning of the buffer.
(defalias 'erlang-end-of-function #[(&optional arg) "\204\303\304\305V\203N`dW\203N` \203#\303u\210\306\303!\204.o\204*\307u\210\306\307!\210\310\311 \210\312\310w\210\313\314!\203@\303y\210`\nX\204)S\211\202 \305W\205\212`\306\303!\210\311 \210\303y\210`\nY\203\202\315\316!\203\311 \210\312\310w\210\313\314!\203\202\303y\210\202\202eb\210)T\211\202O)\207" [arg first pos 1 t 0 erlang-beginning-of-clause -1 nil erlang-pass-over-function " " looking-at "[%\n]" erlang-beginning-of-function 2] 3 (#$ . 104261) "p"])
(byte-code "\300\301!\203\302\303\304\"\210\202\302\303\305\"\210\300\207" [default-boundp beginning-of-defun-function defalias erlang-mark-function mark-defun #[nil "\300`!\210\301\302!\210\303\304\305\217\210\306\302!\210\307\310!\205\311K\310\303\"\207" [push-mark erlang-end-of-function 1 nil (byte-code "\300`\301\302#\207" [push-mark nil t] 4) ((error (byte-code "\300`!\207" [push-mark] 2))) erlang-beginning-of-function boundp deactivate-mark set] 3 "Put mark at end of function, point at beginning." nil]] 3)
(defalias 'erlang-pass-over-function #[nil "\300 \210\301\302!\204m\204\303\304!\210\202m?\205\304u\207" [erlang-skip-blank looking-at "\\.\\(\\s \\|\n\\|\\s<\\)" forward-sexp 1] 2])
(defalias 'erlang-name-of-function #[nil "\212\301\302!\203 \303\302\304\305#\210`\306\307!\210`{*\207" [start looking-at "-[ ]*" re-search-forward nil move forward-sexp 1] 4])
#@208 Like \[fill-paragraph], but handle Erlang comments.
If any of the current line is a comment, fill the comment or the
paragraph of it that point is in, preserving the comment's indentation
and initial `%':s.
(defalias 'erlang-fill-paragraph #[(&optional justify) "\306\211\212\307 \210\310\311\nP!\203\312\313\224\313\225{\202S\310\314!\204@\315\306w\210`f\316=\2032\317u\210\202`f\320=\203\321\322!\210\202\310\n!\203S\312\323i\324\"\313\224\313\225{P) \204^\325 !\202\225\214\212\326\327y!\203m\310\330!\204`\310\330!\204v\322y\210`)\212\322y\210\310\330!\204y`)}\210\f\331P\f\331P\325 !,*\207" [comment-fill-prefix has-comment comment-start-skip justify paragraph-start fill-prefix nil beginning-of-line looking-at "\\s *" t 0 "%\\|$" "^%\n\"\\\\" 92 2 34 forward-sexp 1 make-string 32 fill-paragraph zerop -1 "^\\s *%" "\\|^[ %]*$" paragraph-separate] 3 (#$ . 105854) "P"])
#@46 Uncomment all commented lines in the region.
(defalias 'erlang-uncomment-region #[(beg end) "\302 \303#\207" [beg end comment-region -1] 4 (#$ . 106767) "r"])
#@308 Create additional Erlang clause header.
Parses the source file for the name of the current Erlang function.
Create the header containing the name, A pair of parentheses,
and an arrow. The space between the function name and the
first parenthesis is preserved. The point is placed between
the parentheses.
(defalias 'erlang-generate-new-clause #[nil "\212\303 \205 \304\305!)\212\303 \205\306 )\203 \204!\307\310!\210n\203)l\204/\311\210\312 \210 c\210\212\313\261\210)\n\205?\314 *\207" [arrow name erlang-new-clause-with-arguments erlang-beginning-of-clause erlang-get-function-name t erlang-get-function-arrow error "Can't find name of current Erlang function" nil newline ") " erlang-clone-arguments] 2 (#$ . 106934) nil])
#@143 Insert, at the point, the argument list of the previous clause.
The mark is set at the beginning of the inserted text, the point
at the end.
(defalias 'erlang-clone-arguments #[nil "\212\302 \210\303 \205 \304 )`\211\204\305\306!\210 c\210\307!*\207" [p args beginning-of-line erlang-beginning-of-clause erlang-get-function-arguments error "Can't clone argument list" set-mark] 3 (#$ . 107684) nil])
#@96 Like `buffer-substring-no-properties'.
Although, this function works on all versions of Emacs.
(defalias 'erlang-buffer-substring #[(beg end) "\302\303!\203\f\303K \"\207 {\207" [beg end fboundp buffer-substring-no-properties] 3 (#$ . 108097)])
#@111 Return the name of the module as specified by `-module'.
Return nil if file contains no `-module' attribute.
(defalias 'erlang-get-module #[nil "\212\214~\210eb\210\301 \302\216\303\304d\305#\205\306\307\310\224\310\225\"!,\207" [md match-data ((store-match-data md)) re-search-forward "^-module\\s *(\\s *\\(\\(\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\)\\)?\\)\\s *)\\s *\\." t erlang-remove-quotes erlang-buffer-substring 1] 4 (#$ . 108352)])
#@492 Extract the module name from a file name.
First, the directory part is removed. Second, the part of the file name
matching `erlang-file-name-extension-regexp' is removed.
Should the match fail, nil is returned.
By modifying `erlang-file-name-extension-regexp' to match files other
than Erlang source files, Erlang specific functions could be applied on
non-Erlang files. Most notably; the support for Erlang modules in the
tags system could be used by files written in other languages.
(defalias 'erlang-get-module-from-file-name #[(&optional file) "\204 \205\303!\304\n\"\205\305\211\224O\207" [file buffer-file-name erlang-file-name-extension-regexp file-name-nondirectory string-match 0] 3 (#$ . 108807)])
#@387 Parse list of `function/arity' as used by `-import' and `-export'.
Point must be before the opening bracket. When the
function returns the point will be placed after the closing bracket.
The function does not return an error if the list is incorrectly
formatted.
Return list of (function . arity). The order of the returned list
corresponds to the order of the parsed Erlang list.
(defalias 'erlang-get-function-arity-list #[nil "\302\303 \210\304u\210h\305=\203=\303 \210\306\307!\203=\310\311\304\224\304\225\"!\312\311 T\224 T\225\"!BB\313\225b\210\303 \210\304u\210h\314=\204\237)\207" [res erlang-atom-regexp-matches nil erlang-skip-blank 1 91 looking-at "\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\)/\\([0-9]+\\)\\>" erlang-remove-quotes erlang-buffer-substring string-to-int 0 44] 5 (#$ . 109541)])
#@66 Return a list of `(function . arity)' as specified by `-export'.
(defalias 'erlang-get-export #[nil "\212eb\210\302 \303\304\216\305\306d\307#\203\310 \210\311 \244\202 ,\207" [res md match-data nil ((store-match-data md)) re-search-forward "^-export\\s *(" t erlang-skip-blank erlang-get-function-arity-list] 4 (#$ . 110363)])
#@161 Parse an Erlang source file for imported functions.
Return an alist with module name as car part and list of conses containing
function and arity as cdr part.
(defalias 'erlang-get-import #[nil "\212eb\210\306 \307\310\216\311\312d\313#\203Y\314 \210\315\n!\203 \316\317\320\224\320\225\"!\320\225b\210\314 \210g\321=\203U\322u\210\314 \210\323 \324 \"\f\203N\f\211A \244\241\210\202T BB*)\202 \237,\207" [res md erlang-atom-regexp module pair funcs match-data nil ((store-match-data md)) re-search-forward "^-import\\s *(" t erlang-skip-blank looking-at erlang-remove-quotes erlang-buffer-substring 0 44 1 erlang-get-function-arity-list assoc] 4 (#$ . 110706)])
#@360 Return name of current function, or nil.
If optional argument is non-nil, everything up to and including
the first `(' is returned.
Normally used in conjunction with `erlang-beginning-of-clause', e.g.:
(save-excursion
(if (not (eobp)) (forward-char 1))
(and (erlang-beginning-of-clause)
(erlang-get-function-name t)))
(defalias 'erlang-get-function-name #[(&optional arg) "\203\302\202 \303\304\305!\205\306 \224 \225\")\207" [arg n 0 1 looking-at "^\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\)\\s *(" erlang-buffer-substring] 3 (#$ . 111393)])
#@331 Return arrow of current function, could be "->", ":-" or nil.
The ":-" arrow is used by mnesia queries.
Normally used in conjunction with `erlang-beginning-of-clause', e.g.:
(save-excursion
(if (not (eobp)) (forward-char 1))
(and (erlang-beginning-of-clause)
(erlang-get-function-arrow)))
(defalias 'erlang-get-function-arrow #[nil "\212\300\301d\302#\210\303`S`T\")\207" [re-search-forward "[^-:]*-\\|:" t erlang-buffer-substring] 4 (#$ . 111990)])
#@62 Return the number of arguments of function at point, or nil.
(defalias 'erlang-get-function-arity #[nil "\300\301!\205\212\302\225b\210\303\304\305\217)\207" [looking-at "^\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\)\\s *(" 0 nil (byte-code "\302\303\203Lm\203\304\211\211\202\305\306!\203 \304\211\202\305\307!\203,\310y\210\202\305\311!\203< T\302\225b\210\202\312 !\203E T\313\310!\210\202 *\207" [cont res 0 t nil looking-at "\\s *)" "\\s *\\($\\|%\\)" 1 "\\s *," zerop forward-sexp] 3) ((error))] 3 (#$ . 112487)])
#@47 Return arguments of current function, or nil.
(defalias 'erlang-get-function-arguments #[nil "\300\301!\205\f\212\302\303\304\217)\207" [looking-at "^\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\)\\s *(" nil (byte-code "\301\225\211Sb\210\302 \210\303`S\")\207" [start 0 forward-sexp erlang-buffer-substring] 4) ((error))] 3 (#$ . 113037)])
#@425 Return the module and function under the point, or nil.
Should no explicit module name be present at the point, the
list of imported functions is searched.
The following could be returned:
("module" "function") -- Both module and function name found.
(nil "function") -- No module name was found.
nil -- No function name found
In the future the list may contain more elements.
(defalias 'erlang-get-function-under-point #[nil "\212\306 \307gz\310=\203\311\307x\210\312\307x\210\313\314!\2032\315\316\317\224\317\225\"!\315\316\nT\224\nT\225\"!D\202m\313 !\203m\315\316\320\224\320\225\"!\307\321 \f\203g \204g\322\f@A\"\203`\f@@\202G\fA\211\204K D+\323 !\210+\207" [res md erlang-atom-regexp-matches erlang-atom-regexp imports mod match-data nil 32 " " "a-zA-Z0-9_:'" looking-at "\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\):\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\)" erlang-remove-quotes erlang-buffer-substring 1 0 erlang-get-import assoc store-match-data fk] 6 (#$ . 113383)])
#@35 Return STR, possibly with quotes.
(defalias 'erlang-add-quotes-if-needed #[(str) ";\203\301\302\"\204\303\304!\203\304\305\306\307\211%\305\305Q\207\207" [str string-match "\\`\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\)\\'" fboundp replace-regexp-in-string "'" "\\'" t] 6 (#$ . 114439)])
#@40 Return STR without quotes, if present.
(defalias 'erlang-remove-quotes #[(str) "\302 \303\304 \"\203 \305\306O\202 \307!\210)\207" [md str match-data string-match "\\`'\\(.*\\)'\\'" 1 -1 store-match-data] 3 (#$ . 114743)])
#@288 Initialize the functionality to compare file and module names.
Unless we have `before-save-hook', we redefine the function
`set-visited-file-name' since it clears the variable
`local-write-file-hooks'. The original function definition is
stored in `erlang-orig-set-visited-file-name'.
(defalias 'erlang-check-module-name-init #[nil "\300\301!\203 \302\301\303\304\305$\207\306\307!\210\310\311!\204#\312\311\313\314\304$\210\315\311\304\"\210\302\316\303\"\207" [boundp before-save-hook add-hook erlang-check-module-name nil t require advice ad-advised-definition-p set-visited-file-name ad-add-advice (erlang-set-visited-file-name nil t (advice lambda nil (if (eq major-mode 'erlang-mode) (add-hook 'local-write-file-hooks 'erlang-check-module-name)))) after ad-activate local-write-file-hooks] 5 (#$ . 114979)])
#@372 If the module name doesn't match file name, ask for permission to change.
The variable `erlang-check-module-name' controls the behaviour of this
function. It it is nil, this function does nothing. If it is t, the
source is silently changed. If it is set to the atom `ask', the user
is prompted.
This function is normally placed in the hook `local-write-file-hooks'.
(defalias 'erlang-check-module-name #[nil "\203F\303 \304\305 !\211;\203E ;\203E\n \230\204E\306=\204(\307\310!\203E\212\214~\210eb\210\311\312d\306#\203D\313\224b\210\313\224\313\225|\210 c\210**\314\207" [erlang-check-module-name fn mn erlang-get-module erlang-get-module-from-file-name buffer-file-name t y-or-n-p "Module does not match file name. Modify source? " re-search-forward "^-module\\s *(\\s *\\(\\(\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\)\\)?\\)\\s *)\\s *\\." 1 nil] 5 (#$ . 115804)])
#@721 Insert a semicolon character and possibly a prototype for the next line.
The variable `erlang-electric-semicolon-criteria' states a criterion,
when fulfilled a newline is inserted, the next line is indented and a
prototype for the next line is inserted. Normally the prototype
consists of " ->". Should the semicolon end the clause a new clause
header is generated.
The variable `erlang-electric-semicolon-insert-blank-lines' controls
the number of blank lines inserted between the current line and new
function header.
Behaves just like the normal semicolon when supplied with a
numerical arg, point is inside string or comment, or when there are
non-whitespace characters following the point on the current line.
(defalias 'erlang-electric-semicolon #[(&optional arg) "\304\305!!\210\204& <\203\306 >\203&\307 \204&\310\311!\203&\312\n!\204*\313\211\207\314\315 \210\313\210\316 \210\313\317\320\217\205In\204E\212\321c)\207\313\322\323\217\207" [arg erlang-electric-commands erlang-electric-semicolon-criteria erlang-electric-newline-inhibit self-insert-command prefix-numeric-value erlang-electric-semicolon erlang-in-literal looking-at "\\s *\\(%.*\\)?$" erlang-test-criteria-list nil t undo-boundary newline (byte-code "\300 \210\301\207" [erlang-indent-line t] 1) ((error (byte-code "n\205\300\301!\207" [delete-backward-char 1] 2))) " ->" (byte-code "\301 \210\205\212\302 \210\303!)\207" [erlang-electric-semicolon-insert-blank-lines erlang-generate-new-clause beginning-of-line newline] 2) ((error (byte-code "n\205\300\301!\207" [delete-backward-char 1] 2)))] 3 (#$ . 116694) "P"])
#@386 Insert a comma character and possibly a new indented line.
The variable `erlang-electric-comma-criteria' states a criterion,
when fulfilled a newline is inserted and the next line is indented.
Behaves just like the normal comma when supplied with a
numerical arg, point is inside string or comment, or when there are
non-whitespace characters following the point on the current line.
(defalias 'erlang-electric-comma #[(&optional arg) "\304\305!!\210\204& <\203\306 >\203&\307 \204&\310\311!\203&\312\n!\204*\313\211\207\314\315 \210\313\210\316 \210\313\317\320\217\207" [arg erlang-electric-commands erlang-electric-comma-criteria erlang-electric-newline-inhibit self-insert-command prefix-numeric-value erlang-electric-comma erlang-in-literal looking-at "\\s *\\(%.*\\)?$" erlang-test-criteria-list nil t undo-boundary newline (erlang-indent-line) ((error (byte-code "n\205\300\301!\207" [delete-backward-char 1] 2)))] 3 (#$ . 118321) "P"])
#@67 Insert a less-than sign, and optionally mark it as an open paren.
(defalias 'erlang-electric-lt #[(&optional arg) "\301!\210`\302W?\205K\212\303u\210`f\304=\205J\305`\306\"\307=?\205J\310``T\306\311$\210\312u\210\310``T\306\307$\210\312u\210`f\304=\205J\313``T\314#\210\312u\210\2026)\207" [arg self-insert-command 2 -2 60 get-text-property category bitsyntax-open-inner put-text-property bitsyntax-open-outer 1 remove-text-properties (category nil)] 5 (#$ . 119286) "p"])
#@79 Return t if point is immediately after a bit-syntax close parenthesis (`>>').
(defalias 'erlang-after-bitsyntax-close #[nil "`\300Y\205\212\301u\210`f\302=\205\303`\304\"\305=?)\207" [2 -2 62 get-text-property category bitsyntax-close-outer] 3 (#$ . 119771)])
#@68 Return true if point is immediately after a function arrow (`->').
(defalias 'erlang-after-arrow #[nil "`\302Y\205-\212\303u\210`Sf)\304=\205-<\203\305>\205-\306 ?\205-\307\310!\205-\311 !\207" [erlang-electric-commands erlang-electric-arrow-criteria 2 -1 45 erlang-electric-gt erlang-in-literal looking-at "\\s *\\(%.*\\)?$" erlang-test-criteria-list] 2 (#$ . 120041)])
#@70 Insert a greater-than sign, and optionally mark it as a close paren.
(defalias 'erlang-electric-gt #[(&optional arg) "\302!\210\303 \2039\212\304u\210\305``T\306\307$\210\310u\210\305``T\306\311$\210\310u\210`f\312=\2057\313``T\314#\210\310u\210\202#)\207\315 \203O\316\317 \210\310\210\320 \210\310\321\322\217)\207\310\207" [arg erlang-electric-newline-inhibit self-insert-command erlang-after-bitsyntax-close -2 put-text-property category bitsyntax-close-inner nil bitsyntax-close-outer 62 remove-text-properties (category nil) erlang-after-arrow t undo-boundary newline (erlang-indent-line) ((error (byte-code "n\205\300\301!\207" [delete-backward-char 1] 2)))] 5 (#$ . 120427) "p"])
#@594 Insert a '>'-sign and possibly a new indented line.
This command is only `electric' when the `>' is part of an `->' arrow.
The variable `erlang-electric-arrow-criteria' states a sequence of
criteria, which decides when a newline should be inserted and the next
line indented.
It behaves just like the normal greater than sign when supplied with a
numerical arg, point is inside string or comment, or when there are
non-whitespace characters following the point on the current line.
After being split/merged into `erlang-after-arrow' and
`erlang-electric-gt', it is now unused and disabled.
(defalias 'erlang-electric-arrow\ off #[(&optional arg) "h\305\306 !!\210 \204.\n<\203\307\n>\203.\310=\203.\311 \204.\312\313!\203.\314 !\2044\315\211\202C\316\317 \210\315\210\320 \210\315\321\322\217)\207" [prec arg erlang-electric-commands erlang-electric-arrow-criteria erlang-electric-newline-inhibit self-insert-command prefix-numeric-value erlang-electric-arrow 45 erlang-in-literal looking-at "\\s *\\(%.*\\)?$" erlang-test-criteria-list nil t undo-boundary newline (erlang-indent-line) ((error (byte-code "n\205\300\301!\207" [delete-backward-char 1] 2)))] 3 (#$ . 121131) "P"])
#@474 Break line at point and indent, continuing comment if within one.
The variable `erlang-electric-newline-criteria' states a criterion,
when fulfilled a newline is inserted and the next line is indented.
Should the current line begin with a comment, and the variable
`comment-multi-line' be non-nil, a new comment start is inserted.
Should the previous command be another electric command we assume that
the user pressed newline out of old habit, hence we will do nothing.
(defalias 'erlang-electric-newline #[(&optional arg) "\204 \203\n >\203\306\207\204%\f<\203\307\f>\203%\310 !\204+\311\312!!\207\203W\212\313 \210\314\315P!)\203W\316\225\206E\317\224\317\225`^{\311 \210\320 \210c)\207\311 \210\320 \210\321 \207" [arg erlang-electric-newline-inhibit last-command erlang-electric-newline-inhibit-list erlang-electric-commands erlang-electric-newline-criteria nil erlang-electric-newline erlang-test-criteria-list newline prefix-numeric-value beginning-of-line looking-at "\\s *" 1 0 undo-boundary indent-according-to-mode comment-multi-line comment-start-skip str] 3 (#$ . 122336) "P"])
#@669 Given a list of criterion functions, test if criteria are fulfilled.
Each element in the criteria list can a function returning nil, t or
the atom `stop'. t means that the criterion is fulfilled, `stop' means
that it isn't fulfilled and that the search should stop,
and nil means continue searching.
Should the list contain the atom t the criterion is assumed to be
fulfilled, unless preceded by a function returning `stop', of course.
Should the argument be the atom t instead of a list, the criterion is
assumed to be trivially true.
Should all functions return nil, the criteria are assumed not to be
fulfilled.
Return t if criteria fulfilled, nil otherwise.
(defalias 'erlang-test-criteria-list #[(criteria) "\302=\203\302\207\212\303\203* \204*@\302=\203\302\202#@ A\211\204 \2056 \304=?\2056\302*\207" [criteria answer t nil stop] 3 (#$ . 123461)])
#@207 Test if point is in string, quoted atom or comment.
Return one of the three atoms `atom', `string', and `comment'.
Should the point be inside none of the above mentioned types of
context, nil is returned.
(defalias 'erlang-in-literal #[(&optional lim) "\212\206 \212\302 \210`)\303\304!\203\304 \202\305`\"\306 8\307=\203(\310\202=\306 8\2032\311\202=\312 8\203<\313\202=\314+\207" [lim state erlang-beginning-of-clause fboundp syntax-ppss parse-partial-sexp 3 39 atom string 4 comment nil] 3 (#$ . 124349)])
#@110 Test if point is at end of an Erlang function.
This function is designed to be a member of a criteria list.
(defalias 'erlang-at-end-of-function-p #[nil "\212\300 \210`)\212\301\302!\210`)=\207" [erlang-skip-blank erlang-beginning-of-function -1] 3 (#$ . 124881)])
#@219 Return `stop' if inside parenthesis list, nil otherwise.
Knows about the list comprehension syntax. When the point is
after `||', `stop' is not returned.
This function is designed to be a member of a criteria list.
(defalias 'erlang-stop-when-inside-argument-list #[nil "\212\300\301\302\217)\207" [nil (byte-code "`\302\303\304!\210g\305=\204\306\2021` W\203!\307` #\202@\205,@@@\310=?\2051\306*\207" [state orig-point nil up-list -1 91 stop erlang-partial-parse ||] 4) ((error))] 3 (#$ . 125154)])
#@102 Return `stop' when at function guards.
This function is designed to be a member of a criteria list.
(defalias 'erlang-stop-when-at-guard #[nil "\212\300 \210\301\302!\205\301\303!?\205\304)\207" [beginning-of-line looking-at "^\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\)\\s *(" "^\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\).*\\(->\\|:-\\)" stop] 2 (#$ . 125678)])
#@265 Return non-nil if next lines are empty.
The variable `erlang-next-lines-empty-threshold' contains the number
of lines required to be empty.
A line containing only spaces and tabs is considered empty.
This function is designed to be a member of a criteria list.
(defalias 'erlang-next-lines-empty-p #[nil "\205\"\212\303 \203 \n\304V\203 \305y\210\306\307!\nS\202 +\207" [erlang-next-lines-empty-threshold cont left t 0 1 looking-at "\\s *$"] 2 (#$ . 126050)])
#@111 Test if next readable token is the keyword end.
This function is designed to be a member of a criteria list.
(defalias 'erlang-at-keyword-end-p #[nil "\212\300 \210\301\302!)\207" [erlang-skip-blank looking-at "end[^_a-zA-Z0-9]"] 2 (#$ . 126531)])
#@59 Alist of old tags commands and the replacement functions.
(defvar erlang-tags-function-alist '((find-tag . erlang-find-tag) (find-tag-other-window . erlang-find-tag-other-window) (find-tag-regexp . erlang-find-tag-regexp) (find-tag-other-frame . erlang-find-tag-other-frame)) (#$ . 126786))
#@51 Non-nil when the Erlang tags system is installed.
(defvar erlang-tags-installed nil (#$ . 127083))
#@69 List of files in tag list. Used when finding tag on form `module:'.
(defvar erlang-tags-file-list nil (#$ . 127188))
#@75 Like `tags-completion-table', this table contains `tag' and `module:tag'.
(defvar erlang-tags-completion-table nil (#$ . 127311))
#@61 Non-nil when Erlang module recognising functions installed.
(defvar erlang-tags-buffer-installed-p nil (#$ . 127447))
#@28 Temporary list of buffers.
(defvar erlang-tags-buffer-list nil (#$ . 127571))
#@48 Temporary storage for `tags-completion-table'.
(defvar erlang-tags-orig-completion-table nil (#$ . 127655))
#@45 Temporary storage for `find-tag-tag-order'.
(defvar erlang-tags-orig-tag-order nil (#$ . 127769))
#@52 Temporary storage for `find-tag-regexp-tag-order'.
(defvar erlang-tags-orig-regexp-tag-order nil (#$ . 127873))
#@51 Temporary storage for `find-tag-search-function'.
(defvar erlang-tags-orig-search-function nil (#$ . 127991))
#@58 Temporary storage for `find-tag-regexp-search-function'.
(defvar erlang-tags-orig-regexp-search-function nil (#$ . 128107))
#@50 Temporary storage for `tags-table-format-hooks'.
(defvar erlang-tags-orig-format-hooks nil (#$ . 128237))
#@54 Temporary storage for `tags-table-format-functions'.
(defvar erlang-tags-orig-format-functions nil (#$ . 128349))
#@649 Install an alternate version of tags, aware of Erlang modules.
After calling this function, the tags functions are aware of
Erlang modules. Tags can be entered on the for `module:tag' as well
as on the old form `tag'.
In the completion list, `module:tag' and `module:' shows up.
Call this function from an appropriate init file, or add it to
Erlang mode hook with the commands:
(add-hook 'erlang-mode-hook 'erlang-tags-init)
(add-hook 'erlang-shell-mode-hook 'erlang-tags-init)
This function only works under Emacs 18 and Emacs 19. Currently, It
is not implemented under XEmacs. (Hint: The Emacs 19 etags module
works under XEmacs.)
(defalias 'erlang-tags-init #[nil "\302U\203\303\304!\210\305\306 !\210\307\211\207\303\310!\210\311\312!\205%\305\306 !\210\307\211\207" [erlang-emacs-major-version erlang-tags-installed 18 require tags erlang-tags-define-keys current-local-map t etags fboundp find-tag-noselect] 2 (#$ . 128470) nil])
#@59 Bind tags commands to keymap MAP aware of Erlang modules.
(defalias 'erlang-tags-define-keys #[(map) "\211\2030 @@ @A\306\307\n\f\"!\211\203(\310 @ #\210 A\211\204+ A\211\204)\311\f\"\210\312 \207" [erlang-tags-function-alist alist old new global-map keys append where-is-internal define-key erlang-menu-substitute erlang-menu-init map erlang-menu-base-items] 5 (#$ . 129433)])
#@108 Return the default tag.
Search `-import' list of imported functions.
Single quotes are been stripped away.
(defalias 'erlang-find-tag-default #[nil "\301 \211\204 \302\202@\204A@\202@\303A@Q)\207" [mod-func erlang-get-function-under-point nil ":"] 4 (#$ . 129835)])
#@121 Like `find-tag'. Capable of retrieving Erlang modules.
Tags can be given on the forms `tag', `module:', `module:tag'.
(defalias 'erlang-find-tag #[(modtagname &optional next-p regexp-p) "\303\304 \n#!\210\305\207" [modtagname next-p regexp-p switch-to-buffer erlang-find-tag-noselect t] 5 (#$ . 130120) (erlang-tag-interactive "Find `module:tag' or `tag': ")])
#@59 Like `find-tag-other-window' but aware of Erlang modules.
(defalias 'erlang-find-tag-other-window #[(tagname &optional next-p regexp-p) "\300\306 !\307 \n #\211q\210`\310\306 \311\f!\210\310\306 \"\210\"+\207" [window-point tagname next-p regexp-p tagbuf tagpoint selected-window erlang-find-tag-noselect set-window-point switch-to-buffer-other-window] 6 (#$ . 130490) (erlang-tag-interactive "Find `module:tag' or `tag' other window: ")])
#@58 Like `find-tag-other-frame' but aware of Erlang modules.
(defalias 'erlang-find-tag-other-frame #[(tagname &optional next-p) "\303\304 \n\")\207" [pop-up-frames tagname next-p t erlang-find-tag-other-window] 3 (#$ . 130941) (erlang-tag-interactive "Find `module:tag' or `tag' other frame: ")])
#@53 Like `find-tag-regexp' but aware of Erlang modules.
(defalias 'erlang-find-tag-regexp #[(regexp &optional next-p other-window) "\203\303\202 \304 \n\305#\207" [other-window regexp next-p erlang-find-tag-other-window erlang-find-tag t] 4 (#$ . 131242) (byte-code "\300\301!\203\n\302\303!\207\304\305!\207" [fboundp find-tag-regexp erlang-tag-interactive "Find `module:regexp' or `regexp': " error "This version of Emacs can't find tags by regexps"] 2)])
#@50 Find next tag, like \[find-tag] with prefix arg.
(defalias 'erlang-find-next-tag #[nil "\302 \203\f\303\304!\202\303\305!)\207" [current-prefix-arg erlang-tags-installed (4) call-interactively erlang-find-tag find-tag] 2 (#$ . 131707) nil])
#@55 Like `find-tag-noselect' but aware of Erlang modules.
(defalias 'erlang-find-tag-noselect #[(modtagname &optional next-p regexp-p) "\204\301J\302K\301\"\210\303\304!\203\302K\304\305\"\210\306\213\207" [modtagname last-tag set boundp tags-loop-form (erlang-find-tag nil t) ((byte-code "\306\307\"\203|\310\211\224O\311 \204\212\312 \210\313K ) \204m\f\204O\212\314\315!\203@\312K\316!\203@\312K\317!\203@\313K \202N\320\321 \203J\322\202K\323#\210)\f\203\324\f@!\211;\203f\n \230\203f\f@\fA)\202\325 !\206v\326 !q\210*\202\323\306\327\"\203\313\330\331!\203\232\332 \210\333\216\334K #\210)\202\323\310\211\224O\310\225\311O\211\311\334K #\210\317\324 !\211;\203\254\n \230\203\254,\202\323\334K #\210p\207" [modtagname file modname next-p erlang-tags-file-list this-module string-match ":$" 0 nil visit-tags-table-buffer tags-table-files featurep etags same t error "No %stags containing %s" "more " "" erlang-get-module-from-file-name get-file-buffer find-file-noselect ":" boundp find-tag-tag-order erlang-tags-install-module-check ((erlang-tags-remove-module-check)) find-tag regexp-p tagname last-tag buffer-file-name] 5))] 3 (#$ . 131958) (erlang-tag-interactive "Find `module:tag' or `tag': ")])
(defalias 'erlang-tag-interactive #[(prompt) "\304\305\306\217\210\203\304\307!\310W\203\311\202\312D\207\313 \211\203(\314\315\n #\202)\n\316\317!\2037\320\n\321\"\202:\322\n!\211\323\232\203K \206L\324\325!\202L +C\207" [current-prefix-arg default prompt spec nil (byte-code "\300\301!\207" [require etags] 2) ((error (byte-code "\300\301!\207" [require tags] 2))) prefix-numeric-value 0 - t erlang-find-tag-default format "%s(default %s) " featurep etags completing-read erlang-tags-complete-tag read-string "" error "There is no default tag"] 5])
#@39 Install our own tag search functions.
(defalias 'erlang-tags-install-module-check #[nil "\305Y\203\306J\307K\306\310 B\"\210\311\202\312J\212\313J\211\205?\f@;\2037\314\f@!\2037\314\f@!q\210\315 \210\fA\211\204!\311*\207" [erlang-emacs-major-version erlang-tags-orig-format-functions erlang-tags-buffer-list erlang-tags-orig-format-hooks files 20 tags-table-format-functions set erlang-tags-recognize-tags-table nil tags-table-format-hooks tags-table-computed-list get-file-buffer erlang-tags-install-local] 5 (#$ . 133800)])
#@53 Install our tag search functions in current buffer.
(defalias 'erlang-tags-install-local #[nil "?\205H\306\300!\210\307p B\306\302!\210\310J\306\303!\210\311J\306\304!\210\312J\306\305!\210\313J\306\312!\210\314\n\306\313!\210\315 \306\310!\210\316\306\311!\210\317\211 \207" [erlang-tags-buffer-installed-p erlang-tags-buffer-list erlang-tags-orig-tag-order erlang-tags-orig-regexp-tag-order erlang-tags-orig-search-function erlang-tags-orig-regexp-search-function make-local-variable t find-tag-tag-order find-tag-regexp-tag-order find-tag-search-function find-tag-regexp-search-function erlang-tags-search-forward erlang-tags-regexp-search-forward (erlang-tag-match-module-p) (erlang-tag-match-module-regexp-p)] 2 (#$ . 134346)])
#@39 Remove our own tags search functions.
(defalias 'erlang-tags-remove-module-check #[nil "\305Y\203\306K\307 \"\210\202\306K\310\n\"\210\212 \211\2052\311\f@!\203*\f@q\210\312 \210\fA\211\204\313*\207" [erlang-emacs-major-version erlang-tags-orig-format-functions erlang-tags-orig-format-hooks erlang-tags-buffer-list buffers 20 set tags-table-format-functions tags-table-format-hooks buffer-name erlang-tags-remove-local nil] 4 (#$ . 135098)])
#@54 Remove our tag search functions from current buffer.
(defalias 'erlang-tags-remove-local #[nil "\205!\305K\300\306\"\210\305K\307 \"\210\305K\310\n\"\210\305K\311 \"\210\305K\312\f\"\207" [erlang-tags-buffer-installed-p erlang-tags-orig-tag-order erlang-tags-orig-regexp-tag-order erlang-tags-orig-search-function erlang-tags-orig-regexp-search-function set nil find-tag-tag-order find-tag-regexp-tag-order find-tag-search-function find-tag-regexp-search-function] 3 (#$ . 135558)])
#@163 Install our functions in all loaded TAGS files.
This function is added to `tags-table-format-hooks/functions' when searching
for a tag on the form `module:tag'.
(defalias 'erlang-tags-recognize-tags-table #[nil "\300K \205\n\301 \210\302\207" [etags-recognize-tags-table erlang-tags-install-local t] 1 (#$ . 136050)])
#@57 Forward search function, aware of Erlang module prefix.
(defalias 'erlang-tags-search-forward #[(tag &optional bound noerror count) "\305\306\"\203 \307\225\310O \311=\203\312\n \f$\207 \n \f$\207" [tag erlang-tags-orig-search-function bound noerror count string-match ":" 0 nil erlang-tags-search-forward search-forward] 5 (#$ . 136376)])
#@64 Forward regexp search function, aware of Erlang module prefix.
(defalias 'erlang-tags-regexp-search-forward #[(tag &optional bound noerror count) "\305\306\"\203 \307\225\310O \311=\203\312\n \f$\207 \n \f$\207" [tag erlang-tags-orig-regexp-search-function bound noerror count string-match ":" 0 nil erlang-tags-regexp-search-forward re-search-forward] 5 (#$ . 136730)])
(defalias 'erlang-tag-match-module-p #[(tag) "\302 \"\207" [tag erlang-tags-orig-tag-order erlang-tag-match-module-common-p] 3])
(defalias 'erlang-tag-match-module-regexp-p #[(tag) "\302 \"\207" [tag erlang-tags-orig-regexp-tag-order erlang-tag-match-module-common-p] 3])
(defalias 'erlang-tag-match-module-common-p #[(tag order) "\304\211\305\306\n\"\203\n\307\211\224O\n\307\225\304O \2033\2043 @\310>?\205+ @\n! A\211\204\205B ?\206B \311\312 !\230*\207" [found mod tag order nil string-match ":" 0 (erlang-tag-match-module-p erlang-tag-match-module-regexp-p) erlang-get-module-from-file-name file-of-tag] 4])
#@200 Perform tags completion on the text around point.
Completes to the set of names listed in the current tags table.
Should the Erlang tags system be installed this command knows
about Erlang modules.
(defalias 'erlang-complete-tag #[nil "\302\303\304\217\210\203\305\306!\203\307K\307\310KM\210\311\216\306K *\207\305\306!\203(\306K \207\305\312!\2032\312K \207\313\314!\207" [erlang-tags-installed orig-tags-complete-tag nil (byte-code "\300\301!\207" [require etags] 2) ((error)) fboundp complete-tag tags-complete-tag erlang-tags-complete-tag ((byte-code "\301M\207" [orig-tags-complete-tag tags-complete-tag] 2)) tag-complete-symbol error "This version of Emacs can't complete tags"] 3 (#$ . 137748) nil])
(defalias 'erlang-tags-complete-tag #[(string predicate what) "\212\304\305 \210) \304=\203\306\n\307 #\202\310\n\307 #)\207" [enable-recursive-minibuffers what string predicate t visit-tags-table-buffer all-completions erlang-tags-completion-table try-completion] 4])
#@66 Build completion table. Tags on the form `tag' or `module:tag'.
(defalias 'erlang-tags-completion-table #[nil "\301K\301\302KM\210\303\216\302 )\207" [erlang-tags-orig-completion-table tags-completion-table erlang-tags-completion-table-1 ((byte-code "\301M\207" [erlang-tags-orig-completion-table tags-completion-table] 2))] 2 (#$ . 138748)])
(defalias 'erlang-tags-completion-table-1 #[nil "\304\300!\210\206\305\306 \210\n\211*\207" [erlang-tags-completion-table tags-completion-table-function tags-completion-table erlang-tags-orig-completion-table make-local-variable nil erlang-etags-tags-completion-table] 2])
(defalias 'erlang-etags-tags-completion-table #[nil "\304\305\306\"\307\212eb\210g\310=\203$\311\312!\203$\313\224\313\225{\306\225b\210\202 \314\315\307\316#\203d\317\224\2039\317\224\317\225{\202>\320\224\320\225{\205E\321!\322 \"\210\n;\203`\322\n\323 Q \"\210\322\n\323P \"\210*\202 ) *\207" [file table module tag make-vector 511 0 nil 12 looking-at "\f\n\\([^,\n]*\\),.*\n" 1 re-search-forward "^\\(\\([^]+[^-a-zA-Z0-9_$]+\\)?\\([-a-zA-Z0-9_$?:]+\\)[^-a-zA-Z0-9_$?:]*\\)\\(\\([^\n]+\\)\\)?\\([0-9]+\\)?,\\([0-9]+\\)?\n" t 5 3 erlang-get-module-from-file-name intern ":"] 4])
#@117 Command to execute start a new Erlang shell.
Change this variable to use your favorite
Erlang compilation package.
(defvar erlang-shell-function 'inferior-erlang (#$ . 139985))
#@116 Command to execute to display Erlang shell.
Change this variable to use your favorite
Erlang compilation package.
(defvar erlang-shell-display-function 'inferior-erlang-run-or-select (#$ . 140170))
#@118 Command to execute to compile current buffer.
Change this variable to use your favorite
Erlang compilation package.
(defvar erlang-compile-function 'inferior-erlang-compile (#$ . 140376))
#@117 Command to execute to view last compilation.
Change this variable to use your favorite
Erlang compilation package.
(defvar erlang-compile-display-function 'inferior-erlang-run-or-select (#$ . 140572))
#@139 Command to execute to go to the next error.
Change this variable to use your favorite Erlang compilation
package. Not used in Emacs 21.
(defvar erlang-next-error-function 'inferior-erlang-next-error (#$ . 140781))
#@226 Start a new Erlang shell.
The variable `erlang-shell-function' decides which method to use,
default is to start a new Erlang host. It is possible that, in the
future, a new shell on an already running host will be started.
(defalias 'erlang-shell #[nil "\301!\207" [erlang-shell-function call-interactively] 2 (#$ . 141004) nil])
(defalias 'run-erlang 'erlang-shell)
#@42 Display an Erlang shell, or start a new.
(defalias 'erlang-shell-display #[nil "\301!\207" [erlang-shell-display-function call-interactively] 2 (#$ . 141380) nil])
#@42 Compile Erlang module in current buffer.
(defalias 'erlang-compile #[nil "\301!\207" [erlang-compile-function call-interactively] 2 (#$ . 141551) nil])
#@29 Display compilation output.
(defalias 'erlang-compile-display #[nil "\301!\207" [erlang-compile-display-function call-interactively] 2 (#$ . 141710) nil])
#@57 Display next error message from the latest compilation.
(defalias 'erlang-next-error #[nil "\301!\207" [erlang-next-error-function call-interactively] 2 (#$ . 141872) nil])
#@43 The name of the Erlang link shell buffer.
(defvar erlang-shell-buffer-name "*erlang*" (#$ . 142052))
#@31 Keymap used by Erlang shells.
(defvar erlang-shell-mode-map nil (#$ . 142159))
#@555 *User functions to run when an Erlang shell is started.
This hook is used to change the behaviour of Erlang mode. It is
normally used by the user to personalise the programming environment.
When used in a site init file, it could be used to customise Erlang
mode for all users on the system.
The function added to this hook is run every time a new Erlang
shell is started.
See also `erlang-load-hook', a hook which is run once, when Erlang
mode is loaded, and `erlang-mode-hook' which is run every time a new
Erlang source file is loaded into Emacs.
(defvar erlang-shell-mode-hook nil (#$ . -142245))
#@74 *When non-nil, file name used to store Erlang shell history information.
(defvar erlang-input-ring-file-name "~/.erlang_history" (#$ . -142856))
#@169 Major mode for interacting with an Erlang shell.
We assume that we already are in Comint mode.
The following special commands are available:
\{erlang-shell-mode-map}
(defalias 'erlang-shell-mode #[nil "\306\307\310 \210\n\204\311 !\312\n!\210\313\n!\210\f\2041\314\305!\210\315\316!\314\317!\210\320\314\321!\210\320p+\322,!\210\323-\324\211./\324\21101\320\325\326\217\210\327\330!\203d23\330\324!\210\314\331!\210\332\331\333\"\210\f\203\240\334\316!\210\314\335!\210\334\336 4\337\340!\203\211\3414\342\343#\210\3414\344\345#\210\337\346!\203\231\3414\347\350&B#\2104)BC\351\352!\207" [major-mode mode-name erlang-shell-mode-map comint-mode-map inferior-erlang-use-cmm compilation-parsing-end erlang-shell-mode "Erlang Shell" erlang-mode-variables copy-keymap erlang-shell-mode-commands use-local-map make-local-variable copy-marker 1 compilation-error-list nil compilation-old-error-list erlang-add-compilation-alist "^[^>=]*> *" t (byte-code "\300\301!\210\302\301\303\304\305$\210\302\301\306\304\305$\207" [make-local-hook comint-output-filter-functions add-hook inferior-erlang-strip-delete nil t inferior-erlang-strip-ctrl-m] 5) ((error (byte-code "\300\301\302\"\210\300\301\303\"\207" [add-hook comint-output-filter-functions inferior-erlang-strip-delete inferior-erlang-strip-ctrl-m] 3))) fboundp comint-read-input-ring kill-buffer-hook add-hook comint-write-input-ring compilation-minor-mode minor-mode-overriding-map-alist make-sparse-keymap boundp compilation-skip-threshold define-key [mouse-2] erlang-mouse-2-command " " erlang-RET-command compilation-menu-map [menu-bar compilation] "Errors" run-hooks erlang-shell-mode-hook compilation-last-buffer erlang-error-regexp-alist comint-prompt-regexp comint-eol-on-send comint-input-ignoredups comint-scroll-show-maximum-output comint-scroll-to-bottom-on-output erlang-input-ring-file-name comint-input-ring-file-name map] 7 (#$ . 143008) nil])
#@114 Command bound to `mouse-2' in inferior Erlang buffer.
Selects Comint or Compilation mode command as appropriate.
(defalias 'erlang-mouse-2-command #[(event) "\302\213\203\f\303\304\305\"!\207\303\304 \306\"!\207" [compilation-mode-map comint-mode-map ((byte-code "\212\301!\210\302\303 \304\"):\207" [event mouse-set-point get-text-property line-beginning-position message] 3)) call-interactively lookup-key [mouse-2] [mouse-2]] 4 (#$ . 144957) "e"])
#@110 Command bound to `RET' in inferior Erlang buffer.
Selects Comint or Compilation mode command as appropriate.
(defalias 'erlang-RET-command #[nil "\302\303 \304\":\203\305\306\307\"!\207\305\306 \307\"!\207" [compilation-mode-map comint-mode-map get-text-property line-beginning-position message call-interactively lookup-key " "] 4 (#$ . 145418) nil])
(defalias 'erlang-shell-mode-commands #[(map) "\302\303\304#\210\302\305\306#\210\302\307\310#\210\302\311\312#\210\302\313\314#\210 ?\205(\302\315\316#\207" [map inferior-erlang-use-cmm define-key "\211" erlang-complete-tag "" comint-bol "" beginning-of-line "" nil "\215" compile-goto-error "`" erlang-next-error] 4])
#@138 *When nil, `inferior-erlang-display-buffer' use only selected frame.
When t, all frames are searched. When 'raise, the frame is raised.
(defvar inferior-erlang-display-buffer-any-frame nil (#$ . -146112))
#@267 The type of Erlang shell to use.
When this variable is set to the atom `oldshell', the old shell is used.
When set to `newshell' the new shell is used. Should the variable be
nil, the default shell is used.
This variable influence the setting of other variables.
(defvar inferior-erlang-shell-type 'newshell (#$ . 146325))
#@32 *The name of the Erlang shell.
(defvar inferior-erlang-machine "erl" (#$ . -146657))
#@86 *The options used when activating the Erlang shell.
This must be a list of strings.
(defvar inferior-erlang-machine-options nil (#$ . -146748))
#@42 The name of the inferior Erlang process.
(defvar inferior-erlang-process-name "inferior-erlang" (#$ . 146899))
#@41 The name of the inferior Erlang buffer.
(defvar inferior-erlang-buffer-name erlang-shell-buffer-name (#$ . 147016))
#@277 *Number of seconds before `inferior-erlang-wait-prompt' timeouts.
The time specified is waited after every output made by the inferior
Erlang shell. When this variable is t, we assume that we always have
a prompt. When nil, we will wait forever, or until \[keyboard-quit].
(defvar inferior-erlang-prompt-timeout 60 (#$ . -147139))
#@50 Process of last invoked inferior Erlang, or nil.
(defvar inferior-erlang-process nil (#$ . 147479))
#@49 Buffer of last invoked inferior Erlang, or nil.
(defvar inferior-erlang-buffer nil (#$ . 147585))
#@532 Run an inferior Erlang.
This is just like running Erlang in a normal shell, except that
an Emacs buffer is used for input and output.
\<comint-mode-map>
The command line history can be accessed with \[comint-previous-input] and \[comint-next-input].
The history is saved between sessions.
Entry to this mode calls the functions in the variables
`comint-mode-hook' and `erlang-shell-mode-hook' with no arguments.
The following commands imitate the usual Unix interrupt and
editing control characters:
\{erlang-shell-mode-map}
(defalias 'inferior-erlang #[nil "\306\307!\210\n\310=\203\311 B\202\n\312=\203\313\314 \"\315\316 \f\317 %)\320 !\321!\210\322 !\210\323=\204E\n\312=\203E\324\317\325\326\217\210\327 \207" [inferior-erlang-machine-options opts inferior-erlang-shell-type inferior-erlang-process-name inferior-erlang-machine inferior-erlang-buffer require comint oldshell "-oldshell" newshell append ("-newshell" "-env" "TERM" "vt100") apply make-comint nil get-buffer-process process-kill-without-query switch-to-buffer windows-nt t (rename-buffer inferior-erlang-buffer-name t) ((error (rename-buffer inferior-erlang-buffer-name))) erlang-shell-mode inferior-erlang-process system-type comint-process-echoes] 6 (#$ . 147690) nil])
#@69 Switch to an inferior Erlang buffer, possibly starting new process.
(defalias 'inferior-erlang-run-or-select #[nil "\300 \204\301 \207\302\303!\207" [inferior-erlang-running-p inferior-erlang inferior-erlang-display-buffer t] 2 (#$ . 148964) nil])
#@619 Make the inferior Erlang process visible.
The window is returned.
Should `inferior-erlang-display-buffer-any-frame' be nil the buffer is
displayed in the current frame. Should it be non-nil, and the buffer
already is visible in any other frame, no new window will be created.
Should it be the atom 'raise, the frame containing the window will
be raised.
Should the optional argument SELECT be non-nil, the window is
selected. Should the window be in another frame, that frame is raised.
Note, should the mouse pointer be places outside the raised frame, that
frame will become deselected before the next command.
(defalias 'inferior-erlang-display-buffer #[(&optional select) "\306 \204 \307\310!\210\311!\312\313!\211\204)\314 \212\315\f!\210\314 )\316 !\210)\202K \203K \203K\204<\317=\203K\313 \320\n!=\204K\321\320\n!!\210\203T\316\n!\210\322\323!\210\n*\207" [inferior-erlang-display-buffer-any-frame frames-p win old-win inferior-erlang-buffer window-system inferior-erlang-running-p error "No inferior Erlang process is running" inferior-erlang-window fboundp selected-frame selected-window switch-to-buffer-other-window select-window raise window-frame raise-frame sit-for 0 select] 4 (#$ . 149221) nil])
#@45 Non-nil when an inferior Erlang is running.
(defalias 'inferior-erlang-running-p #[nil "\205\302!\303>\205 \205\304 !\207" [inferior-erlang-process inferior-erlang-buffer process-status (run open) buffer-name] 2 (#$ . 150464)])
#@59 Return the window containing the inferior Erlang, or nil.
(defalias 'inferior-erlang-window #[(&optional all-frames) "\303 \205\203 \304Y\203\305\n\306\"\207\305\n!\207" [all-frames erlang-emacs-major-version inferior-erlang-buffer inferior-erlang-running-p 19 get-buffer-window t] 3 (#$ . 150706)])
#@54 Wait until the inferior Erlang shell prompt appears.
(defalias 'inferior-erlang-wait-prompt #[nil "\305=?\205F\306 \204\307\310!\210\212 q\210\311\212\312 !b\210\313y\210\314\f!)\204>\n\2040\305\315\316!\210\317 \"\204\307\320!\210\202\n\205E\315\321!*\207" [inferior-erlang-prompt-timeout inferior-erlang-buffer msg inferior-erlang-process comint-prompt-regexp t inferior-erlang-running-p error "No inferior Erlang shell is running" nil process-mark 0 looking-at message "Waiting for Erlang shell prompt (press C-g to abort)." accept-process-output "No Erlang shell prompt before timeout" ""] 3 (#$ . 151019)])
(autoload 'comint-send-input "comint")
#@270 Send command CMD to the inferior Erlang.
The contents of the current command line (if any) will
be placed at the next prompt.
If optional second argument is non-nil the command is inserted into
the history list.
Return the position after the newly inserted command.
(defalias 'inferior-erlang-send-command #[(cmd &optional hist) "\306 \204 \307\310!\210p\311\312!! \203\313\202\nGTq\210\fb\210\nc\210\314\2032\2023\315\316 \210* \204E\317\320\314\321#\210 q\210\f \\+\207" [inferior-erlang-process comint-process-echoes cmd insert-length insert-point old-buffer inferior-erlang-running-p error "No inferior Erlang process is running" marker-position process-mark 0 nil ignore comint-send-input walk-windows #[(window) "\304! =\205\305!\nU\205\306\n \\\"\207" [window inferior-erlang-buffer insert-point insert-length window-buffer window-point set-window-point] 4] t inferior-erlang-buffer hist comint-input-filter comint-eol-on-send] 4 (#$ . 151691)])
#@68 Remove `^H' (delete) and the characters it was supposed to remove.
(defalias 'inferior-erlang-strip-delete #[(&optional s) "\300\301!\2055\300\302!\2055\212t\203\301J\202\302Jb\210\303\304w\210`d=?\2054\305\306!\210n\204\307\306!\210\202)\207" [boundp comint-last-input-end comint-last-output-start "^" nil delete-char 1 backward-delete-char] 2 (#$ . 152682) nil])
#@63 Strip trailing `^M' characters from the current output group.
(defalias 'inferior-erlang-strip-ctrl-m #[(&optional string) "\301\302!\2052\301\303!\2052\304\305p!!\212t\203\302J\202\303Jb\210\306\307\310#\2051\311\312\310\211#\210\202 *\207" [pmark boundp comint-last-input-end comint-last-output-start process-mark get-buffer-process re-search-forward " +$" t replace-match ""] 4 (#$ . 153065) nil])
#@540 Compile the file in the current buffer.
With prefix arg, compiles for debug.
Should Erlang return `{error, nofile}' it could not load the object
module after completing the compilation. This is due to a bug in the
compile command `c' when using the option `outdir'.
There exists two workarounds for this bug:
1) Place the directory in the Erlang load path.
2) Set the Emacs variable `erlang-compile-use-outdir' to nil.
To do so, place the following line in your `~/.emacs'-file:
(setq erlang-compile-use-outdir nil)
(defalias 'inferior-erlang-compile #[(arg) "\306 \210\307 \204 \212\310 \210)\307 \204\311\312!\210\313\314 !\314 \315\316O\317\320\321\322 \210\323 \210\324 \203G\203?\325\326 \f#\202_\325\327 \f#\202_\325\330\331\203S\332\202T\333Q \n\f \n\211 & \321\"\323 \210\212q\210\321\321\223\210)\211 -\207" [end tmpvar2 tmpvar noext dir erlang-compile-use-outdir save-some-buffers inferior-erlang-running-p inferior-erlang error "Error starting inferior Erlang shell" file-name-directory buffer-file-name 0 -4 "Tmp7236" "Tmp8742" nil inferior-erlang-display-buffer inferior-erlang-wait-prompt inferior-erlang-send-command format "c(\"%s\", [{outdir, \"%s\"}, debug_info, export_all])." "c(\"%s\", [{outdir, \"%s\"}])." "f(%s), {ok, %s} = file:get_cwd(), " "file:set_cwd(\"%s\"), " "%s = c(\"%s\", [debug_info, export_all]), file:set_cwd(%s), f(%s), %s." "%s = c(\"%s\"), file:set_cwd(%s), f(%s), %s." current-prefix-arg inferior-erlang-buffer compilation-error-list compilation-parsing-end compilation-last-buffer] 11 (#$ . 153483) "P"])
#@89 Just like `next-error'.
Capable of finding error messages in an inferior Erlang buffer.
(defalias 'inferior-erlang-next-error #[(&optional argp) "\305\306\300!\205\307 !\203*\212 q\210 \310=\205\311\211)\203*\312\216\313\314\f!\210)\n\2061\314\f!*\207" [compilation-last-buffer buf done major-mode argp nil boundp bufferp erlang-shell-mode compilation-mode ((byte-code "\212q\210\302)\302\207" [buf major-mode erlang-shell-mode] 1)) t next-error] 3 (#$ . 155090) "P"])
#@105 Make the inferior Erlang change directory.
The default is to go to the directory of the current buffer.
(defalias 'inferior-erlang-change-directory #[(&optional dir) "\204 \301\302 !\303 \204\304\305!\210\306 \210\307 \210\310\311\312\"\313\"\207" [dir file-name-directory buffer-file-name inferior-erlang-running-p error "No inferior Erlang is running" inferior-erlang-display-buffer inferior-erlang-wait-prompt inferior-erlang-send-command format "cd('%s')." nil] 4 (#$ . 155580) nil])
#@413 Align arrows ("->") in function clauses from START to END.
When called interactively, aligns arrows after function clauses inside
the region.
With a prefix argument, aligns all arrows, not just those in function
clauses.
Example:
sum(L) -> sum(L, 0).
sum([H|T], Sum) -> sum(T, Sum + H);
sum([], Sum) -> Sum.
becomes:
sum(L) -> sum(L, 0).
sum([H|T], Sum) -> sum(T, Sum + H);
sum([], Sum) -> Sum.
(defalias 'erlang-align-arrows #[(start end) "\212\203 \306\202\n\307\203\310\202 T\311\312\nb\210\313 b\210\314 \315#\203C\224b\210\316 \210` B\f\317 ]\202& \311\211\223\210\320\321 \".\207" [current-prefix-arg erlang-atom-regexp-matches end end-marker most-indent arrow-positions "^.*\\(\\)->" "^\\([a-z][a-zA-Z0-9_]*\\|'[^\n']*[^\\]'\\).*\\(\\)->" 1 nil 0 point-marker re-search-forward t just-one-space erlang-column-number mapcar #[(arrow-pos) "b\210 \303 Z\211\304V\205\305\306\n\")\207" [arrow-pos most-indent pad erlang-column-number 0 insert-char 32] 4] arrow-match-pos re start] 5 (#$ . 156081) "r"])
#@115 Return the column number of the current position in the buffer.
Tab characters are counted by their visual width.
(defalias 'erlang-column-number #[nil "\300\301 `{!\207" [string-width line-beginning-position] 3 (#$ . 157141)])
#@46 `add-log-current-defun-function' for Erlang.
(defalias 'erlang-current-defun #[nil "\212\300 \210\301\302!\205 \303\304!)\207" [erlang-beginning-of-function looking-at "[a-z0-9_]+" match-string 0] 2 (#$ . 157375)])
#@173 Make the obsolete function SYM refer to the defined function NEWDEF.
Simplified version of a combination `defalias' and `make-obsolete',
it assumes that NEWDEF is loaded.
(defalias 'erlang-obsolete #[(sym newdef) "\302 K\"\210\303\304!\205\304 \"\207" [sym newdef defalias fboundp make-obsolete] 3 (#$ . 157598)])
(byte-code "\301\302\303\"\210\301\304\305\"\210\301\306\307\"\210\301\310\311\"\210\301\312\313\"\210\301\314\315\"\210\301\316\317\"\210\301\320\321\"\210\301\322\323\"\210\301\324\325\"\210\301\326\327\"\210\301\330\331\"\210\332B\333\334C!\210\335\336!\210\337\340!\207" [current-load-list erlang-obsolete calculate-erlang-indent erlang-calculate-indent calculate-erlang-stack-indent erlang-calculate-stack-indent at-erlang-keyword erlang-at-keyword at-erlang-operator erlang-at-operator beginning-of-erlang-clause erlang-beginning-of-clause end-of-erlang-clause erlang-end-of-clause mark-erlang-clause erlang-mark-clause beginning-of-erlang-function erlang-beginning-of-function end-of-erlang-function erlang-end-of-function mark-erlang-function erlang-mark-function pass-over-erlang-clause erlang-pass-over-function name-of-erlang-function erlang-name-of-function erlang-unload-hook (lambda (#1=#:defconst-tmp-var) (defconst erlang-unload-hook #1#)) #[nil "\300\301\302\"\210\303\304!\205\305\306!\210\305\301!\207" [defalias set-visited-file-name erlang-orig-set-visited-file-name featurep advice ad-unadvise Man-notify-when-ready] 3] provide erlang run-hooks erlang-load-hook] 3)
Jump to Line
Something went wrong with that request. Please try again.