Changeset 187

Show
Ignore:
Timestamp:
08/01/07 15:04:41 (1 year ago)
Author:
JarrettBillingsley
Message:

--

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/docs/minid.compiler.html

    r186 r187  
    163163            Page was generated with 
    164164            <img src="candydoc/img/candydoc.gif" style="vertical-align:middle; position:relative; top:-1px"> 
    165             on Wed Aug  1 13:47:15 2007 
     165            on Wed Aug  1 15:04:31 2007 
    166166 
    167167        </td></tr> 
  • trunk/docs/minid.minid.html

    r185 r187  
    417417            Page was generated with 
    418418            <img src="candydoc/img/candydoc.gif" style="vertical-align:middle; position:relative; top:-1px"> 
    419             on Wed Aug  1 13:47:15 2007 
     419            on Wed Aug  1 15:04:31 2007 
    420420 
    421421        </td></tr> 
  • trunk/docs/minid.types.html

    r186 r187  
    11111111This is a closure, that is a function and all the environment it needs to execute correctly. 
    11121112It can hold either a MiniD closure (a "script closure"), or a reference to a native D function 
    1113 (a "native closure").  In most cases this distinction is transparent, except with coroutines. 
    1114 Coroutines can only be created with script closures. 
     1113(a "native closure").  In virtually all cases this distinction is transparent, except when it 
     1114comes to coroutines.  You cannot yield out of a coroutine across the boundary of a native function 
     1115call. 
    11151116<br><br> 
    11161117 
     
    11661167    an MDValue which represents the thread from which this closure was called, and the number of parameters 
    11671168    (not including the context 'this' parameter, which is always present) with which the function was called. 
    1168     The MDState parameter contains all the parameter which were passed to the function, as well as being a 
     1169    The MDState parameter contains all the parameters which were passed to the function, as well as being a 
    11691170    very important interface through which much of the native API is used.  Native functions return an integer, 
    1170     which is how many values it is returning (which were pushed onto the MDState's stack prior to returning). 
     1171    which is how many values they are returning (which were pushed onto the MDState's stack prior to returning). 
    11711172 
    11721173<br><br> 
     
    16601661<script>explorer.outline.writeEnabled = true;</script> 
    16611662<dt><span class="decl">void  
     1663<span class="currsymbol">sort</span> 
     1664<script>explorer.outline.addDecl('sort');</script> 
     1665 
     1666(bool delegate(MDValue , MDValue ) <span class="funcparam">predicate</span>); 
     1667</span></dt> 
     1668<script>explorer.outline.writeEnabled = false;</script> 
     1669 
     1670 
     1671<dd>Sorts the array, using a custom <span class="funcparam">predicate</span>.  This <span class="funcparam">predicate</span> takes two values and should return '<b>true</b>' 
     1672    if the first is less than the second, and '<b>false</b>' otherwise. 
     1673     
     1674<br><br> 
     1675 
     1676</dd> 
     1677 
     1678<script>explorer.outline.writeEnabled = true;</script> 
     1679<dt><span class="decl">void  
    16621680<span class="currsymbol">reverse</span> 
    16631681<script>explorer.outline.addDecl('reverse');</script> 
     
    28052823This is really just a name and the code for the top-level function of the module.  This can 
    28062824be serialized and deserialized using the minid.utils serialization protocol.  This can also 
    2807 be loaded by the MDGlobalState class, but that's a very low-level API. 
     2825be loaded by the MDContext class, but that's a very low-level API. 
    28082826<br><br> 
    28092827 
     
    30533071 
    30543072 
    3055 <dd>An instance of the above struct.  You can access  
    3056 <span class="currsymbol">globals</span> 
    3057 <script>explorer.outline.addDecl('globals');</script> 
    3058  
    3059  by writing things like "MDGlobalState(). 
    3060 <span class="currsymbol">globals</span> 
    3061 <script>explorer.outline.addDecl('globals');</script> 
    3062  
    3063 ["x"d] = 5". 
     3073<dd>An instance of the above struct.  You can access globals by writing things like "context.globals["x"d] = 5". 
    30643074     
    30653075<br><br> 
     
    34113421 
    34123422<dd>Construct a new thread.  A default thread of execution, the 'main thread', is created for 
    3413     you by MDGlobalState, so you'll really only need this for creating coroutines. 
     3423    you by MDContext, so you'll really only need this for creating coroutines. 
    34143424<br><br> 
    34153425If you pass a script function closure to this constructor, this thread will be a coroutine.  It 
     
    44924502            Page was generated with 
    44934503            <img src="candydoc/img/candydoc.gif" style="vertical-align:middle; position:relative; top:-1px"> 
    4494             on Wed Aug  1 13:47:14 2007 
     4504            on Wed Aug  1 15:04:30 2007 
    44954505 
    44964506        </td></tr> 
  • trunk/docs/minid.utils.html

    r186 r187  
    584584            Page was generated with 
    585585            <img src="candydoc/img/candydoc.gif" style="vertical-align:middle; position:relative; top:-1px"> 
    586             on Wed Aug  1 13:47:15 2007 
     586            on Wed Aug  1 15:04:31 2007 
    587587 
    588588        </td></tr>