<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.6000.16525" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face="Courier New" size=2>Hi,</FONT></DIV>
<DIV><FONT face="Courier New" size=2>Given a module that wants to provide
an opaque struct-type. When required from a module there is no way to
circumvent the opaqueness, because the invoked module is executed before the
invoking unit is executed. Hence the invoking unit cannot play with inspectors
before the invoked unit is executed. But at top level it is possible to
circumvent the opaqueness. See the example below. Is this simply a top level
problem, or is there a some way to make structs provided by a module realy
opaque for the top level?</FONT></DIV>
<DIV><FONT face="Courier New" size=2>Jos Koot</FONT></DIV>
<DIV><FONT face="Courier New" size=2></FONT> </DIV>
<DIV><FONT face="Courier New" size=2>; module a required within module
b<BR>(module a mzscheme<BR> (define-struct a ()
#;(current-inspector))<BR> (provide (all-defined)))<BR>(module b
mzscheme<BR> (define ci (current-inspector))<BR> (current-inspector
(make-inspector))<BR> (require a)<BR> (current-inspector
ci)<BR> (printf "~s~n" (struct? (make-a)))) ; #f, ok<BR>(require
b)</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face="Courier New" size=2>; module c required at top level<BR>(module
c mzscheme<BR> (define-struct c () #;(current-inspector))<BR> (provide
(all-defined)))<BR>(define ci (current-inspector))<BR>(current-inspector
(make-inspector))<BR>(require c)<BR>(current-inspector ci)<BR>(printf "~s~n"
(struct? (make-c))) ; #t</FONT></DIV>
<DIV><FONT face="Courier New" size=2></FONT> </DIV></BODY></HTML>