MMCT TEAM
Server IP : 111.118.215.189  /  Your IP : 18.117.158.174
Web Server : Apache
System : Linux md-in-83.webhostbox.net 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64
User : a1673wkz ( 2475)
PHP Version : 8.2.25
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0755) :  /usr/share/emacs/24.3/lisp/progmodes/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : //usr/share/emacs/24.3/lisp/progmodes/cc-styles.elc
;ELC
;;; Compiled by mockbuild@buildfarm06-new.corp.cloudlinux.com on Fri Oct 11 10:09:19 2024
;;; from file /builddir/build/BUILD/emacs-24.3/lisp/progmodes/cc-styles.el
;;; in Emacs version 24.3.1
;;; with all optimizations.

;;; This file uses dynamic docstrings, first added in Emacs 19.29.

;;; This file does not contain utf-8 non-ASCII characters,
;;; and so can be loaded in Emacs versions earlier than 23.

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;


(byte-code "\300\301!\210\300\302!\210\300\303!\207" [require cc-defs cc-vars cc-align] 2)
#@1337 Styles of indentation.
Elements of this alist are of the form:

  (STYLE-STRING [BASE-STYLE] (VARIABLE . VALUE) [(VARIABLE . VALUE) ...])

where STYLE-STRING is a short descriptive string used to select a
style, VARIABLE is any Emacs variable, and VALUE is the intended value
for that variable when using the selected style.

Optional BASE-STYLE if present, is a string and must follow
STYLE-STRING.  BASE-STYLE names a style that this style inherits from.
By default, all styles inherit from the "user" style, which is
computed at run time.  Style loops generate errors.

Two variables are treated specially.  When VARIABLE is
`c-offsets-alist', the VALUE is a list containing elements of the
form:

  (SYNTACTIC-SYMBOL . OFFSET)

as described in `c-offsets-alist'.  These are passed directly to
`c-set-offset' so there is no need to set every syntactic symbol in
your style, only those that are different from the default.

When VARIABLE is `c-special-indent-hook', its VALUE is added to
`c-special-indent-hook' using `add-hook'.  If VALUE is a list, each
element of the list is added with `add-hook'.

Do not change this variable directly.  Use the function `c-add-style'
to add new styles or modify existing styles (it is not a good idea to
modify existing styles -- you should create a new style that inherits
the existing style).
(defvar c-style-alist '(("gnu" (c-basic-offset . 2) (c-comment-only-line-offset 0 . 0) (c-hanging-braces-alist (substatement-open before after) (arglist-cont-nonempty)) (c-offsets-alist (statement-block-intro . +) (knr-argdecl-intro . 5) (substatement-open . +) (substatement-label . 0) (label . 0) (statement-case-open . +) (statement-cont . +) (arglist-intro . c-lineup-arglist-intro-after-paren) (arglist-close . c-lineup-arglist) (inline-open . 0) (brace-list-open . +) (topmost-intro-cont first c-lineup-topmost-intro-cont c-lineup-gnu-DEFUN-intro-cont)) (c-special-indent-hook . c-gnu-impose-minimum) (c-block-comment-prefix . #1="")) ("k&r" (c-basic-offset . 5) (c-comment-only-line-offset . 0) (c-offsets-alist (statement-block-intro . +) (knr-argdecl-intro . 0) (substatement-open . 0) (substatement-label . 0) (label . 0) (statement-cont . +))) ("bsd" (c-basic-offset . 8) (c-comment-only-line-offset . 0) (c-offsets-alist (statement-block-intro . +) (knr-argdecl-intro . +) (substatement-open . 0) (substatement-label . 0) (label . 0) (statement-cont . +) (inline-open . 0) (inexpr-class . 0))) ("stroustrup" (c-basic-offset . 4) (c-comment-only-line-offset . 0) (c-offsets-alist (statement-block-intro . +) (substatement-open . 0) (substatement-label . 0) (label . 0) (statement-cont . +))) ("whitesmith" (c-basic-offset . 4) (c-comment-only-line-offset . 0) (c-offsets-alist (defun-open . +) (defun-close . c-lineup-whitesmith-in-block) (defun-block-intro add c-lineup-whitesmith-in-block c-indent-multi-line-block) (class-open . +) (class-close . +) (inline-open . +) (inline-close . c-lineup-whitesmith-in-block) (knr-argdecl-intro . +) (block-open . 0) (block-close . c-lineup-whitesmith-in-block) (brace-list-open . +) (brace-list-close . c-lineup-whitesmith-in-block) (brace-list-intro add c-lineup-whitesmith-in-block c-indent-multi-line-block) (brace-list-entry add c-lineup-after-whitesmith-blocks c-indent-multi-line-block) (brace-entry-open add c-lineup-after-whitesmith-blocks c-indent-multi-line-block) (statement add c-lineup-after-whitesmith-blocks c-indent-multi-line-block) (statement-block-intro add c-lineup-whitesmith-in-block c-indent-multi-line-block) (substatement-open . +) (substatement-label . +) (label . 0) (arglist-intro add c-lineup-whitesmith-in-block c-indent-multi-line-block) (arglist-cont add c-lineup-after-whitesmith-blocks c-indent-multi-line-block) (arglist-cont-nonempty add c-lineup-whitesmith-in-block c-indent-multi-line-block) (arglist-close . c-lineup-whitesmith-in-block) (inclass . c-lineup-whitesmith-in-block) (extern-lang-open . +) (namespace-open . +) (module-open . +) (composition-open . +) (extern-lang-close . +) (namespace-close . +) (module-close . +) (composition-close . +) (inextern-lang . c-lineup-whitesmith-in-block) (innamespace . c-lineup-whitesmith-in-block) (inmodule . c-lineup-whitesmith-in-block) (incomposition . c-lineup-whitesmith-in-block) (inexpr-class . 0))) ("ellemtel" (c-basic-offset . 3) (c-comment-only-line-offset . 0) (c-hanging-braces-alist (substatement-open before after) (arglist-cont-nonempty)) (c-offsets-alist (topmost-intro . 0) (substatement . +) (substatement-open . 0) (case-label . +) (access-label . -) (inclass . +) (inline-open . 0))) ("linux" (c-basic-offset . 8) (c-comment-only-line-offset . 0) (c-hanging-braces-alist (brace-list-open) (brace-entry-open) (substatement-open after) (block-close . c-snug-do-while) (arglist-cont-nonempty)) (c-cleanup-list brace-else-brace) (c-offsets-alist (statement-block-intro . +) (knr-argdecl-intro . 0) (substatement-open . 0) (substatement-label . 0) (label . 0) (statement-cont . +))) ("python" (indent-tabs-mode . t) (fill-column . 78) (c-basic-offset . 8) (c-offsets-alist (substatement-open . 0) (inextern-lang . 0) (arglist-intro . +) (knr-argdecl-intro . +)) (c-hanging-braces-alist (brace-list-open) (brace-list-intro) (brace-list-close) (brace-entry-open) (substatement-open after) (block-close . c-snug-do-while) (arglist-cont-nonempty)) (c-block-comment-prefix . #1#)) ("java" (c-basic-offset . 4) (c-comment-only-line-offset 0 . 0) (c-offsets-alist (inline-open . 0) (topmost-intro-cont . +) (statement-block-intro . +) (knr-argdecl-intro . 5) (substatement-open . +) (substatement-label . +) (label . +) (statement-case-open . +) (statement-cont . +) (arglist-intro . c-lineup-arglist-intro-after-paren) (arglist-close . c-lineup-arglist) (access-label . 0) (inher-cont . c-lineup-java-inher) (func-decl-cont . c-lineup-java-throws))) ("awk" (c-basic-offset . 4) (c-comment-only-line-offset . 0) (c-hanging-braces-alist (defun-open after) (defun-close . c-snug-1line-defun-close) (substatement-open after) (block-close . c-snug-do-while) (arglist-cont-nonempty)) (c-hanging-semi&comma-criteria) (c-cleanup-list) (c-offsets-alist (statement-block-intro . +) (substatement-open . 0) (statement-cont . +)))) (#$ . 655))
(defalias 'c-set-style-1 #[(conscell dont-override) "@A\211\304=\203&\306=\203\f\202\205\307\304!\310\311	\")\202\201\n\312=\203W\306=\2037\n\202>\205>\307\312!?\205\201	<\203N\310\313	\"\202\201\314\312	\306\211$\202\201\203u\n>\203u\306=\203m\nJ\202p\307\n!\315=\205\201\n	L\210\n\316=\205\201\317 *\207" [conscell val attr dont-override c-offsets-alist offsets t default-value mapcar #[(langentry) "@A\211\236?\205\304\n	\"*\207" [langentry offset langelem offsets c-set-offset] 4] c-special-indent-hook #[(func) "\301\302\303\211$\207" [func add-hook c-special-indent-hook t] 5] add-hook set-from-style c-comment-prefix-regexp c-setup-paragraph-variables c-style-variables] 6])
(defalias 'c-get-style-variables #[(style basestyles) "\204\306	!\207\307\227\n\"\206(\307\226\n\"\206(\307\n\"\206(\310\311\"\210\312 \210\313A\211\242;\2056@\227A\211
>\203H\310\314\f
#\210\312 \202R\315\f\211
B\"\306!\244*\207" [style c-fallback-style c-style-alist vars base basestyles copy-alist assoc message "Undefined style: %s" ding nil "Style loop detected: %s in %s" c-get-style-variables] 5])
(defvar c-set-style-history nil)
#@1037 Set the current buffer to use the style STYLENAME.
STYLENAME, a string, must be an existing CC Mode style - These are contained
in the variable `c-style-alist'.

The variable `c-indentation-style' will get set to STYLENAME.

"Setting the style" is done by setting CC Mode's "style variables" to the
values indicated by the pertinent entry in `c-style-alist'.  Other variables
might get set too.

If DONT-OVERRIDE is neither nil nor t, style variables whose default values
have been set (more precisely, whose default values are not the symbol
`set-from-style') will not be changed.  This avoids overriding global settings
done in your init file.  It is useful to call c-set-style from a mode hook
in this way.

If DONT-OVERRIDE is t, style variables that already have values (i.e., whose
values are not the symbol `set-from-style') will not be overridden.  CC Mode
calls c-set-style internally in this way whilst initializing a buffer; if
cc-set-style is called like this from anywhere else, it will usually behave as
a null operation.
(defalias 'c-set-style #[(stylename &optional dont-override) "\204\n\306\307\310 \"\210	;\204\306\311!\210\312 \210\313	\314\"\204#\315\304!\316\317\320=\2030\n\237\2021\n\"\210)	\321\322!\205@\320\211\207" [c-buffer-is-cc-mode stylename vars dont-override c-special-indent-hook c-indentation-style error "Buffer %s is not a CC Mode buffer (c-set-style)" buffer-name "Argument to c-set-style was not a string" c-initialize-builtin-style c-get-style-variables nil default-value mapc #[(elem) "\302	\"\207" [elem dont-override c-set-style-1] 3] t boundp zmacs-region-stays] 4 (#$ . 8064) (list (let ((completion-ignore-case t) (prompt (format "Which %s indentation style? " mode-name))) (completing-read prompt c-style-alist nil t nil 'c-set-style-history c-indentation-style)))])
#@460 Adds a style to `c-style-alist', or updates an existing one.
STYLE is a string identifying the style to add or update.  DESCRIPTION
is an association list describing the style and must be of the form:

  ([BASESTYLE] (VARIABLE . VALUE) [(VARIABLE . VALUE) ...])

See the variable `c-style-alist' for the semantics of BASESTYLE,
VARIABLE and VALUE.  This function also sets the current style to
STYLE using `c-set-style' if the optional SET-P flag is non-nil.
(defalias 'c-add-style #[(style description &optional set-p) "\227\305	\"\211\203\n\306!\241\210\202B	B)\f\205#\307!\207" [style c-style-alist s description set-p assoc copy-alist c-set-style] 4 (#$ . 9902) (let ((stylename (completing-read "Style to add: " c-style-alist nil nil nil 'c-set-style-history)) (descr (eval-minibuffer "Style description: "))) (list stylename descr (y-or-n-p "Set the style too? ")))])
(defvar c-read-offset-history nil)
(defalias 'c-read-offset #[(langelem) "	\236\206\301\306N\236\243\307!\310\311\n\"\312\313\fQ\314\fQ\315 \316\317\211 \320!\"\210\321\322\323#\210\204m\324\317\325\326\310\327\n\"& \330 !\203d \211\202B\331 \210
\202@.\n\207" [langelem c-offsets-alist oldoff symname defstr errmsg c-stylevar-fallback symbol-name format "(default %s): " "Offset must be int, func, var, vector, list, " "or [+,-,++,--,*,/] " " offset " make-sparse-keymap fboundp nil set-keymap-parent define-key " " self-insert-command read-from-minibuffer t c-read-offset-history "%s" c-valid-offset ding prompt keymap obarray minibuffer-completion-table minibuffer-completion-predicate offset input minibuffer-local-completion-map] 10])
#@254 Change the value of a syntactic element symbol in `c-offsets-alist'.
SYMBOL is the syntactic element symbol to change and OFFSET is the new
offset for that syntactic element.  The optional argument is not used
and exists only for compatibility reasons.
(defalias 'c-set-offset #[(symbol offset &optional ignored) "\305!\2032	\n\236\211\203\241\210\202.	\302\306N\236\203&	B\nB\202.\307\310	\"\210\311 \210)\202;\307\312	#\210\311 \210\313\304!\205D\314\211\207" [offset symbol c-offsets-alist entry zmacs-region-stays c-valid-offset c-stylevar-fallback message "%s is not a valid syntactic symbol" ding "Invalid indentation setting for symbol %s: %S" boundp t] 5 (#$ . 11585) (let* ((langelem (intern (completing-read (concat "Syntactic symbol to change" (if current-prefix-arg " or add" "") ": ") (mapcar #'(lambda (langelem) (cons (format "%s" (car langelem)) nil)) (get 'c-offsets-alist 'c-stylevar-fallback)) nil (not current-prefix-arg) (and c-buffer-is-cc-mode (let* ((modified (buffer-modified-p)) (buffer-undo-list t) (inhibit-read-only t) (inhibit-point-motion-hooks t) before-change-functions after-change-functions deactivate-mark buffer-file-name buffer-file-truename (syntax (c-guess-basic-syntax)) (len (length syntax)) (ic (format "%s" (car (nth (1- len) syntax))))) (unwind-protect (progn (cons ic 0)) (and (not modified) (buffer-modified-p) (set-buffer-modified-p nil)))))))) (offset (c-read-offset langelem))) (list langelem offset current-prefix-arg))])
#@225 Fix things up for paragraph recognition and filling inside comments and
strings by incorporating the values of `c-comment-prefix-regexp',
`sentence-end', `paragraph-start' and `paragraph-separate' in the relevant
variables.
(defalias 'c-setup-paragraph-variables #[nil "\204\n\306\307\310 \"\210	<\203\311\n	\"\206\311\312	\"\243\202	\313\314\"\315\316Q\317
P!\317\f\2038\314\2029\315
\f\203B\314\202C\320R\211\"#\321$R%\"&\321$R'\322\211()!\323\324!\203p\315\323\324!\325Q\202q\314P\326\327!\203\205\330\327!\210\331!\332Q,\333*\334+\335\336\337 )\325\321\340\325\260\211,\207" [c-buffer-is-cc-mode c-comment-prefix-regexp major-mode c-current-comment-prefix empty-is-prefix nonws-comment-line-prefix error "Buffer %s is not a CC Mode buffer (c-setup-paragraph-variables)" buffer-name assoc other string-match "" "\\(" "\\)[ 	]*" "[ 	]*" "\\)?" "\\|" t default-value adaptive-fill-regexp "\\)" boundp adaptive-fill-first-line-regexp make-local-variable "\\`" "\\'" "\f\\|[ 	]*\\\\?$" "[ 	\f]*\\\\?$" "\\(\\(" nil sentence-end "[.?!][]\"')}]* ?\\\\\\($\\)[ 	\n]*" comment-line-prefix blank-or-comment-line-prefix c-paragraph-start page-delimiter paragraph-start c-paragraph-separate paragraph-separate paragraph-ignore-fill-prefix adaptive-fill-mode c-string-par-start c-string-par-separate c-sentence-end-with-esc-eol] 7 (#$ . 13081) nil])
#@287 Convenience function to configure Kyle E. Jones' Filladapt mode for
CC Mode by making sure the proper entries are present on
`filladapt-token-table', `filladapt-token-match-table', and
`filladapt-token-conversion-table'.  This is intended to be used on
`c-mode-common-hook' or similar.
(defalias 'c-setup-filladapt #[nil "\305	\211\203\242\243\242\306=\204\243\211\204\203$@\n\240\210\202/\307	@\n\306DD	A\")\306\236\204;\307\310\"\306\f\236?\205H\307\311\f\"\211\207" [p filladapt-token-table c-current-comment-prefix filladapt-token-match-table filladapt-token-conversion-table nil c-comment append ((c-comment c-comment)) ((c-comment . exact))] 5 (#$ . 14472)])
(defalias 'c-initialize-builtin-style #[nil "\306\307N?\205d\310\306\307\311#\210\312\313\"\204Q	\314\211\211
\203K
@\211J
A\f\315=\203<\203\315B\nB\202\316=\204\fB\nB\202\317\313\n\"\210,\312\320\"\204]\317\320\321\"\210\205d\322 \207" [c-style-alist c-style-variables uservars val var vars c-initialize-builtin-style is-run put t assoc "user" nil c-offsets-alist set-from-style c-add-style "cc-mode" ("user") c-make-styles-buffer-local c-style-variables-are-local-p] 5])
#@429 Make all CC Mode style variables buffer local.
If `this-buf-only-p' is non-nil, the style variables will be made
buffer local only in the current buffer.  Otherwise they'll be made
permanently buffer local in any buffer that changes their values.

The buffer localness of the style variables are normally controlled
with the variable `c-style-variables-are-local-p', so there's seldom
any reason to call this function directly.
(defalias 'c-make-styles-buffer-local #[(&optional this-buf-only-p) "\203\305\202	\306\307\310	!B\311\312\n\"\210\313\n\"\210?\205&\306\312!\210\314\211*\207" [this-buf-only-p c-style-variables varsyms func c-style-variables-are-local-p make-local-variable make-variable-buffer-local c-indentation-style copy-alist delq c-special-indent-hook mapc t] 4 (#$ . 15670)])
#@108 Return suitable style for MODE from DEFAULT-STYLE.
DEFAULT-STYLE has the same format as `c-default-style'.
(defalias 'cc-choose-style-for-mode #[(mode default-style) ";\203\207	\236A\206\302\236A\206\303\207" [default-style mode other "gnu"] 2 (#$ . 16482)])
(provide 'cc-styles)

MMCT - 2023