Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
2203e1e8
Commit
2203e1e8
authored
Jan 09, 1996
by
Erik Naggum
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(Fsyntax_table_p, Fchar_syntax, Fmatching_paren, Fmodify_syntax_entry):
Harmonize arguments with documentation.
parent
5806161b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
22 deletions
+23
-22
src/syntax.c
src/syntax.c
+23
-22
No files found.
src/syntax.c
View file @
2203e1e8
...
...
@@ -111,13 +111,13 @@ find_defun_start (pos)
}
DEFUN
(
"syntax-table-p"
,
Fsyntax_table_p
,
Ssyntax_table_p
,
1
,
1
,
0
,
"Return t if
ARG
is a syntax table.
\n
\
"Return t if
OBJECT
is a syntax table.
\n
\
Currently, any char-table counts as a syntax table."
)
(
obj
)
Lisp_Object
obj
;
(
obj
ect
)
Lisp_Object
obj
ect
;
{
if
(
CHAR_TABLE_P
(
obj
)
&&
XCHAR_TABLE
(
obj
)
->
purpose
==
Qsyntax_table
)
if
(
CHAR_TABLE_P
(
obj
ect
)
&&
XCHAR_TABLE
(
obj
ect
)
->
purpose
==
Qsyntax_table
)
return
Qt
;
return
Qnil
;
}
...
...
@@ -237,27 +237,28 @@ syntax_parent_lookup (table, character)
}
DEFUN
(
"char-syntax"
,
Fchar_syntax
,
Schar_syntax
,
1
,
1
,
0
,
"Return the syntax code of CHAR, described by a character.
\n
\
For example, if CHAR is a word constituent, the character `?w' is returned.
\n
\
"Return the syntax code of CHARACTER, described by a character.
\n
\
For example, if CHARACTER is a word constituent,
\n
\
the character `w' is returned.
\n
\
The characters that correspond to various syntax codes
\n
\
are listed in the documentation of `modify-syntax-entry'."
)
(
ch
)
Lisp_Object
ch
;
(
ch
aracter
)
Lisp_Object
ch
aracter
;
{
int
char_int
;
CHECK_NUMBER
(
ch
,
0
);
char_int
=
XINT
(
ch
);
CHECK_NUMBER
(
ch
aracter
,
0
);
char_int
=
XINT
(
ch
aracter
);
return
make_number
(
syntax_code_spec
[(
int
)
SYNTAX
(
char_int
)]);
}
DEFUN
(
"matching-paren"
,
Fmatching_paren
,
Smatching_paren
,
1
,
1
,
0
,
"Return the matching parenthesis of CHAR, or nil if none."
)
(
ch
)
Lisp_Object
ch
;
"Return the matching parenthesis of CHAR
ACTER
, or nil if none."
)
(
ch
aracter
)
Lisp_Object
ch
aracter
;
{
int
char_int
,
code
;
CHECK_NUMBER
(
ch
,
0
);
char_int
=
XINT
(
ch
);
CHECK_NUMBER
(
ch
aracter
,
0
);
char_int
=
XINT
(
ch
aracter
);
code
=
SYNTAX
(
char_int
);
if
(
code
==
Sopen
||
code
==
Sclose
)
return
make_number
(
SYNTAX_MATCH
(
char_int
));
...
...
@@ -287,19 +288,19 @@ The second character of S is the matching parenthesis,\n\
used only if the first character is `(' or `)'.\n\
Any additional characters are flags.\n\
Defined flags are the characters 1, 2, 3, 4, b, and p.\n\
1 means C is the start of a two-char comment start sequence.\n\
2 means C is the second character of such a sequence.\n\
3 means C is the start of a two-char comment end sequence.\n\
4 means C is the second character of such a sequence.\n\
1 means C
HAR
is the start of a two-char comment start sequence.\n\
2 means C
HAR
is the second character of such a sequence.\n\
3 means C
HAR
is the start of a two-char comment end sequence.\n\
4 means C
HAR
is the second character of such a sequence.\n\
\n\
There can be up to two orthogonal comment sequences. This is to support\n\
language modes such as C++. By default, all comment sequences are of style\n\
a, but you can set the comment sequence style to b (on the second character\n\
of a comment-start, or the first character of a comment-end sequence) using\n\
this flag:\n\
b means C is part of comment sequence b.\n\
b means C
HAR
is part of comment sequence b.\n\
\n\
p means C is a prefix character for `backward-prefix-chars';\n\
p means C
HAR
is a prefix character for `backward-prefix-chars';\n\
such characters are treated as whitespace when they occur\n\
between expressions.")
(char, s, table)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment