diff options
author | Ludovic Courtès <ludo@gnu.org> | 2009-01-18 16:42:17 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2009-01-18 16:42:17 +0100 |
commit | c891a40e9fc5f718bfaf6e70f8fd0b19311d14a6 (patch) | |
tree | 734b544458f5f18ab87bdfbff15e686468bdfc3c /libguile/smob.c | |
parent | d0cad2492cd880fded45b4ab52afb61e6047b1ac (diff) | |
download | guile-c891a40e9fc5f718bfaf6e70f8fd0b19311d14a6.tar.gz |
Publish the maximum number of SMOB types as `SCM_I_MAX_SMOB_TYPE_COUNT'.
* libguile/goops.c (create_smob_classes): Refer to
`SCM_I_MAX_SMOB_TYPE_COUNT' rather than 255 (which is wrong) or 256.
* libguile/smob.c (MAX_SMOB_COUNT): Alias for `SCM_I_MAX_SMOB_TYPE_COUNT'.
* libguile/smob.h (SCM_I_MAX_SMOB_TYPE_COUNT): New macro.
Diffstat (limited to 'libguile/smob.c')
-rw-r--r-- | libguile/smob.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libguile/smob.c b/libguile/smob.c index 0ad4a35ca..ddff2a00b 100644 --- a/libguile/smob.c +++ b/libguile/smob.c @@ -1,4 +1,4 @@ -/* Copyright (C) 1995,1996,1998,1999,2000,2001, 2003, 2004, 2006 Free Software Foundation, Inc. +/* Copyright (C) 1995,1996,1998,1999,2000,2001, 2003, 2004, 2006, 2009 Free Software Foundation, Inc. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -49,7 +49,8 @@ * tags for smobjects (if you know a tag you can get an index and conversely). */ -#define MAX_SMOB_COUNT 256 +#define MAX_SMOB_COUNT SCM_I_MAX_SMOB_TYPE_COUNT + long scm_numsmob; scm_smob_descriptor scm_smobs[MAX_SMOB_COUNT]; |