diff options
author | Marius Vollmer <mvo@zagadka.de> | 2005-01-11 16:55:29 +0000 |
---|---|---|
committer | Marius Vollmer <mvo@zagadka.de> | 2005-01-11 16:55:29 +0000 |
commit | 1f366ef7f04cccb99ef26489153a6e3db37cd7fa (patch) | |
tree | 87fa43d2678214cd7f94fa4820444747509824b9 /libguile/deprecated.c | |
parent | 8789459042bae679e332515b6b15e30405935ac2 (diff) | |
download | guile-1f366ef7f04cccb99ef26489153a6e3db37cd7fa.tar.gz |
(SCM_ARRAYP, SCM_ARRAY_NDIM, SCM_ARRAY_CONTP, SCM_ARRAY_MEM,
SCM_ARRAY_V, SCM_ARRAY_BASE, SCM_ARRAY_DIMS, scm_t_array): New
deprecated versions.
Diffstat (limited to 'libguile/deprecated.c')
-rw-r--r-- | libguile/deprecated.c | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/libguile/deprecated.c b/libguile/deprecated.c index 91cb86ccf..1429e2238 100644 --- a/libguile/deprecated.c +++ b/libguile/deprecated.c @@ -1297,6 +1297,66 @@ scm_vector_equal_p (SCM x, SCM y) return scm_equal_p (x, y); } +int +SCM_ARRAYP (SCM a) +{ + scm_c_issue_deprecation_warning + ("SCM_ARRAYP is deprecated. Use scm_is_array instead."); + return SCM_I_ARRAYP(a) || SCM_I_ENCLOSED_ARRAYP(a); +} + +size_t +SCM_ARRAY_NDIM (SCM a) +{ + scm_c_issue_deprecation_warning + ("SCM_ARRAY_NDIM is deprecated. " + "Use scm_c_array_rank or scm_array_handle_rank instead."); + return scm_c_array_rank (a); +} + +int +SCM_ARRAY_CONTP (SCM a) +{ + scm_c_issue_deprecation_warning + ("SCM_ARRAY_CONTP is deprecated. Do not use it."); + return SCM_I_ARRAY_CONTP (a); +} + +scm_t_array * +SCM_ARRAY_MEM (SCM a) +{ + scm_c_issue_deprecation_warning + ("SCM_ARRAY_MEM is deprecated. Do not use it."); + return (scm_t_array *)SCM_I_ARRAY_MEM (a); +} + +SCM +SCM_ARRAY_V (SCM a) +{ + /* We could use scm_shared_array_root here, but it is better to move + them away from expecting vectors as the basic storage for arrays. + */ + scm_c_issue_deprecation_warning + ("SCM_ARRAY_V is deprecated. Do not use it."); + return SCM_I_ARRAY_V (a); +} + +size_t +SCM_ARRAY_BASE (SCM a) +{ + scm_c_issue_deprecation_warning + ("SCM_ARRAY_BASE is deprecated. Do not use it."); + return SCM_I_ARRAY_BASE (a); +} + +scm_t_array_dim * +SCM_ARRAY_DIMS (SCM a) +{ + scm_c_issue_deprecation_warning + ("SCM_ARRAY_DIMS is deprecated. Use scm_array_handle_dims instead."); + return SCM_I_ARRAY_DIMS (a); +} + void scm_i_init_deprecated () { |