[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
array? not working since long time
From: |
Roland Orre |
Subject: |
array? not working since long time |
Date: |
Tue, 12 Oct 2004 15:48:31 +0200 |
The predicate (array? arg) hasn't been working for long time.
E.g:
(array? 'hi)
#t
(array? '(list))
#t
The simple code below is what I use, but of course that is too simple
as it doesn't handle the optional prototype. The code in unif.c I don't
understand (that with smobs). Maybe also (array? "string") => #t
Best regards
Roland
SCM_PROC (s_array_p, "array?", 1, 0, 0, scm_array_p);
SCM scm_array_p( SCM what )
{
if (SCM_IMP(what))
return SCM_BOOL_F;
else switch (SCM_TYP7(what))
{
case scm_tc7_fvect:
case scm_tc7_svect:
case scm_tc7_bvect:
case scm_tc7_ivect:
case scm_tc7_uvect:
case scm_tc7_dvect:
case scm_tc7_vector:
return SCM_BOOL_T;
}
return SCM_BOOL_F;
} /* scm_array_p */
- array? not working since long time,
Roland Orre <=