<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Matthew Flatt schreef:
<blockquote cite="mid200505231928.j4NJS8OU048745@slow.flux.utah.edu"
type="cite"><br>
<pre wrap="">You're right --- it won't work. MzScheme semaphores work only with the
MzScheme thread scheduler.
You'll need to use whatever synchronization primitives the C thread
system provides, and then connect to the MzScheme scheduler through
scheme_block_until() or scheme_add_evt().
Matthew
</pre>
</blockquote>
Will this cause problems?<br>
<br>
<em>"C functions that can invoke MzScheme (and also be invoked
by MzScheme) depend on strict function-call nesting.</em> For example,
suppose a function F uses an internal stack, pushing items on to the
stack on entry and popping the same items on exit. Suppose also that
F invokes MzScheme to evaluate an expression. If the evaluate on
this expression invoked F again in a new thread, but then returns to
the first thread before completing the second F, then F's internal
stack will be corrupted."<br>
<br>
Hans<br>
<br>
<br>
<br>
<br>
</body>
</html>