scsh-0.6/scheme/bcomp
mainzelm b7bb1fa2e5 Subject: Extend type<->sexp conversion to variable type
type->sexp was not capable of converting the variable type to a
sexp. This caused problems if the module system wanted to tell the
user that the types of exported bindings did not match:

config> (define-structure foo (export (bar :syntax)) (open scheme) (begin (define bar 1)))
; no values returned
config> ,user
> ,open foo

Error: exception
       wrong-type-argument
       (checked-record-ref '(variable #{Type :value #f #f}) '#{Record-type 14 meta-type} 1)

I've now extended TYPE->SEXP by a check for the variable type and let
it produce a list with 'VARIABLE as first and the actual type as
second element. Likewise, I extended SEXP->TYPE to produce a variable
type if 'VARIABEL is the first element of a list.

This seems to work but a second look by someone who really understands
the type system would be appreciated.

(Merge from s48 rev 423)
2003-08-04 07:31:33 +00:00
..
binding.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
cenv.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
comp-exp.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
comp-package.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
comp-prim.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
comp.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
config.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
ddata.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
for-reify.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
interface.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
module-language.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
mtype.scm Subject: Extend type<->sexp conversion to variable type 2003-08-04 07:31:33 +00:00
name.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
node.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
optimize.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
package-undef.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
package.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
primop.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
read-form.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
recon.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
rules.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
scan-package.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
schemify.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
segment.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
stack-check.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
state.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
syntax.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
thingie.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
transform.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
type.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
usual.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00
var-util.scm GC_PROTECT some variables. 2003-05-01 10:21:33 +00:00