239 |
|
|
240 |
{ |
{ |
241 |
|
|
242 |
|
if(type_of(sym) != t_symbol && !setf_fn_form(sym)) { |
243 |
|
/* stack_string(s,"Function Identifier"); */ |
244 |
|
/* TYPE_ERROR(sym,s); */ |
245 |
|
FEwrong_type_argument(sLfunction_identifier,sym); |
246 |
|
} |
247 |
|
|
248 |
/*FIXME -- store a symbol in plist for setf functions as opposed to |
/*FIXME -- store a symbol in plist for setf functions as opposed to |
249 |
the function itself, and centralize function name resolution. |
the function itself, and centralize function name resolution. |
250 |
Allow for tracing, etc. thereby. 20050307 CM*/ |
Allow for tracing, etc. thereby. 20050307 CM*/ |
251 |
|
|
252 |
if (type_of(sym)==t_cons && sym->c.c_car==sLsetf |
if (setf_fn_form(sym)) { |
|
&& type_of(sym->c.c_cdr->c.c_car)==t_symbol |
|
|
&& sym->c.c_cdr->c.c_cdr==Cnil) { |
|
|
|
|
|
if (get(sym->c.c_cdr->c.c_car,sSsetf_function,OBJNULL)==OBJNULL) |
|
|
FEundefined_function(sym); |
|
|
remf(&sym->c.c_cdr->c.c_car->s.s_plist,sSsetf_function); |
|
|
RETURN1(sym); |
|
253 |
|
|
254 |
|
if (get(sym->c.c_cdr->c.c_car,sSsetf_function,OBJNULL)!=OBJNULL) |
255 |
|
/* FEundefined_function(sym); */ |
256 |
|
remf(&sym->c.c_cdr->c.c_car->s.s_plist,sSsetf_function); |
257 |
|
RETURN1(sym); |
258 |
} |
} |
259 |
|
|
260 |
/* 1 args */ |
/* 1 args */ |
|
if(type_of(sym) != t_symbol && !setf_fn_form(sym)) { |
|
|
stack_string(s,"Function Identifier"); |
|
|
TYPE_ERROR(sym,s); |
|
|
} |
|
261 |
|
|
262 |
if (sym->s.s_sfdef != NOT_SPECIAL) { |
if (sym->s.s_sfdef != NOT_SPECIAL) { |
263 |
if (sym->s.s_mflag) { |
if (sym->s.s_mflag) { |