1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-04-30 03:40:34 +02:00
guile/module/rnrs
Andy Wingo b071ce2147 redo the SCM tagging strategy
Currently failing some guardian tests.

* libguile/tags.h: Refactor tagging so that tc3 bits for a pair live in
  the SCM value, not in the heap words.  Do the same for structs.  This
  more rational tagging strategy will make native code generation
  easier.  Note that this means that to check a heap pointer for its
  type, you first have to ensure that it has the expected tc3, as not
  all the type bits are on the heap.
  (SCM_TYP3): Check the SCM tag type, not the bits in the cell.
  (SCM_HAS_TYP3): New helper.
  (SCM_I_CONSP): Redefine to just check the typ3.
  (scm_tcs_cons_imcar, scm_tcs_cons_nimcar, scm_tcs_struct): Remove, as
  they are no longer necessary.

* libguile/array-handle.c (scm_i_array_implementation_for_obj): Check
  for heap objects before checking type bits, so we don't check pairs.

* libguile/evalext.c (scm_self_evaluating_p):
* libguile/gc.c (scm_i_tag_name):
* libguile/goops.c (scm_class_of)
* libguile/hash.c (scm_hasher):
* libguile/print.c (iprin1): Adapt to tagging changes.

* libguile/gc.c (scm_storage_prehistory): Register all displacements
  here.  There are the same displacements as before, unfortunately.

* libguile/list.c (SCM_I_CONS):
* libguile/pairs.c (scm_cons):
* libguile/pairs.h (scm_is_pair):
* libguile/vm-engine.h (CONS): Tag pairs with scm_tc3_pair.

* libguile/modules.c (scm_post_boot_init_modules):
* libguile/modules.h (SCM_MODULEP):
* libguile/struct.c (struct_finalizer_trampoline, scm_i_alloc_struct):
  (scm_make_vtable_vtable):
* libguile/struct.h (SCM_STRUCTP, SCM_STRUCT_VTABLE_DATA):
  (SCM_STRUCT_VTABLE_SLOTS):
* libguile/vm-i-scheme.c (make-struct): Adapt to struct tagging
  changes.

* libguile/numbers.h (SCM_I_INUMP):
* module/rnrs/arithmetic/fixnums.scm (fixnum?, inline-fixnum?): Adapt
  to the new fixnum tag.

* libguile/numbers.h (SCM_INEXACTP): Make sure of the tc3 before looking
  at the cell type.
2013-01-15 19:13:03 +01:00
..
arithmetic redo the SCM tagging strategy 2013-01-15 19:13:03 +01:00
io All r6rs ports are both textual and binary 2013-01-15 16:32:52 +01:00
records Fix R6RS `fold-left' so the accumulator is the first argument. 2011-11-01 01:11:46 +01:00
base.scm R6RS `string-for-each' should accept multiple string arguments 2012-11-22 22:26:16 +01:00
bytevectors.scm add #:version (6) to rnrs bytevectors and ports 2010-06-02 22:19:40 +02:00
conditions.scm Some tweaks to the R6RS support 2010-11-25 23:04:12 +01:00
control.scm remove duplicate when/unless definitions 2012-01-20 21:16:50 +01:00
enums.scm Enumeration set universe comparisons should be done with `equal?' 2010-11-21 15:35:44 -05:00
eval.scm remove encoding of versions into the file system (for now?) 2010-06-16 22:20:28 +02:00
exceptions.scm install r6rs exception printer 2011-02-11 16:07:44 +01:00
files.scm Reorganize the R6RS I/O condition types 2010-11-24 23:04:24 +01:00
hashtables.scm Fix argument passing for external hash functions in `(rnrs hashtables)'. 2010-07-14 01:16:19 -04:00
lists.scm Fix R6RS `fold-left' so the accumulator is the first argument. 2011-11-01 01:11:46 +01:00
mutable-pairs.scm fix ^L typo 2010-06-19 14:45:03 +02:00
mutable-strings.scm typo in mutable-strings 2010-06-19 15:40:25 +02:00
programs.scm remove encoding of versions into the file system (for now?) 2010-06-16 22:20:28 +02:00
r5rs.scm remove encoding of versions into the file system (for now?) 2010-06-16 22:20:28 +02:00
sorting.scm remove encoding of versions into the file system (for now?) 2010-06-16 22:20:28 +02:00
syntax-case.scm Fix make-variable-transformer export 2010-09-19 12:15:37 +02:00
unicode.scm remove encoding of versions into the file system (for now?) 2010-06-16 22:20:28 +02:00