int minsize;
extern char *index ();
- if (XTYPE (Vdoc_directory) != Lisp_String
- || XTYPE (Vdoc_file_name) != Lisp_String)
+ if (!STRINGP (Vdoc_directory) || !STRINGP (Vdoc_file_name))
return Qnil;
minsize = XSTRING (Vdoc_directory)->size;
if (XVECTOR (fun)->size <= COMPILED_DOC_STRING)
return Qnil;
tem = XVECTOR (fun)->contents[COMPILED_DOC_STRING];
- if (XTYPE (tem) == Lisp_String)
+ if (STRINGP (tem))
doc = tem;
- else if (XTYPE (tem) == Lisp_Int && XINT (tem) >= 0)
+ else if (INTEGERP (tem) && XINT (tem) >= 0)
doc = get_doc_string (XFASTINT (tem));
else
return Qnil;
case Lisp_Cons:
funcar = Fcar (fun);
- if (XTYPE (funcar) != Lisp_Symbol)
+ if (!SYMBOLP (funcar))
return Fsignal (Qinvalid_function, Fcons (fun, Qnil));
else if (EQ (funcar, Qkeymap))
return build_string ("Prefix command (definition is a keymap associating keystrokes with\n\
|| EQ (funcar, Qautoload))
{
tem = Fcar (Fcdr (Fcdr (fun)));
- if (XTYPE (tem) == Lisp_String)
+ if (STRINGP (tem))
doc = tem;
- else if (XTYPE (tem) == Lisp_Int && XINT (tem) >= 0)
+ else if (INTEGERP (tem) && XINT (tem) >= 0)
doc = get_doc_string (XFASTINT (tem));
else
return Qnil;
register Lisp_Object tem;
tem = Fget (sym, prop);
- if (XTYPE (tem) == Lisp_Int)
+ if (INTEGERP (tem))
tem = get_doc_string (XINT (tem) > 0 ? XINT (tem) : - XINT (tem));
- if (NILP (raw) && XTYPE (tem) == Lisp_String)
+ if (NILP (raw) && STRINGP (tem))
return Fsubstitute_command_keys (tem);
return tem;
}
/* The type determines where the docstring is stored. */
/* Lisp_Subrs have a slot for it. */
- if (XTYPE (fun) == Lisp_Subr)
+ if (SUBRP (fun))
XSUBR (fun)->doc = (char *) - offset;
/* If it's a lisp form, stick it in the form. */
if (EQ (tem, Qlambda) || EQ (tem, Qautoload))
{
tem = Fcdr (Fcdr (fun));
- if (CONSP (tem) &&
- XTYPE (XCONS (tem)->car) == Lisp_Int)
+ if (CONSP (tem) && INTEGERP (XCONS (tem)->car))
XFASTINT (XCONS (tem)->car) = offset;
}
else if (EQ (tem, Qmacro))
}
/* Bytecode objects sometimes have slots for it. */
- else if (XTYPE (fun) == Lisp_Compiled)
+ else if (COMPILEDP (fun))
{
/* This bytecode object must have a slot for the
docstring, since we've found a docstring for it. */
{
end = index (p, '\n');
sym = oblookup (Vobarray, p + 2, end - p - 2);
- if (XTYPE (sym) == Lisp_Symbol)
+ if (SYMBOLP (sym))
{
/* Attach a docstring to a variable? */
if (p[1] == 'V')