var searchIndex = {}; searchIndex["context"] = {"doc":"This project provides an easy interface to the famous **Boost.Context** library\nand thus the building blocks for higher-level abstractions, like coroutines,\ncooperative threads (userland threads) or an equivalent to the C# keyword "yield".","items":[[0,"context","context","Provides the `Context` and `Transfer` types for\nsaving and restoring the current state of execution.",null,null],[3,"Context","context::context","A `Context` stores a `ContextFn`'s state of execution, for it to be resumed later.",null,null],[3,"Transfer","","Contains the previously active `Context` and the `data` passed to resume the current one and\nis used as the return value by `Context::resume()` and `Context::resume_ontop()`",null,null],[12,"context","","The previously executed `Context` which yielded to resume the current one.",0,null],[12,"data","","The `data` which was passed to `Context::resume()` or\n`Context::resume_ontop()` to resume the current `Context`.",0,null],[6,"ContextFn","","Functions of this signature are used as the entry point for a new `Context`.",null,null],[6,"ResumeOntopFn","","Functions of this signature are used as the callback while resuming ontop of a `Context`.",null,null],[11,"new","","Creates a new `Context` prepared to execute `f` at the beginning of `stack`.",1,{"inputs":[{"name":"stack"},{"name":"contextfn"}],"output":{"name":"context"}}],[11,"resume","","Yields the execution to another `Context`.",1,null],[11,"resume_ontop","","Yields the execution to another `Context` and executes a function "ontop" of it's stack.",1,null],[11,"fmt","","",1,null],[11,"fmt","","",0,null],[11,"new","","Returns a new `Transfer` struct with the members set to their respective arguments.",0,{"inputs":[{"name":"context"},{"name":"usize"}],"output":{"name":"transfer"}}],[0,"stack","context","Provides utilities to allocate memory suitable as stack memory for `Context`.",null,null],[3,"Stack","context::stack","Represents any kind of stack memory.",null,null],[3,"FixedSizeStack","","A very simple and straightforward implementation of `Stack`.",null,null],[3,"ProtectedFixedSizeStack","","A more secure, but slightly slower version of `FixedSizeStack`.",null,null],[4,"StackError","","Error type returned by stack allocation methods.",null,null],[13,"ExceedsMaximumSize","","Contains the maximum amount of memory allowed to be allocated as stack space.",2,null],[13,"IoError","","Returned if some kind of I/O error happens during allocation.",2,null],[11,"fmt","","",2,null],[11,"fmt","","",3,null],[11,"new","","Creates a (non-owning) representation of some stack memory.",3,null],[11,"top","","Returns the top of the stack from which on it grows downwards towards bottom().",3,null],[11,"bottom","","Returns the bottom of the stack and thus it's end.",3,null],[11,"len","","Returns the size of the stack between top() and bottom().",3,null],[11,"min_size","","Returns the minimal stack size allowed by the current platform.",3,{"inputs":[],"output":{"name":"usize"}}],[11,"max_size","","Returns the maximum stack size allowed by the current platform.",3,{"inputs":[],"output":{"name":"usize"}}],[11,"default_size","","Returns a implementation defined default stack size.",3,{"inputs":[],"output":{"name":"usize"}}],[11,"fmt","","",4,null],[11,"new","","Allocates a new stack of **at least** `size` bytes.",4,{"inputs":[{"name":"usize"}],"output":{"name":"result"}}],[11,"deref","","",4,null],[11,"default","","",4,{"inputs":[],"output":{"name":"fixedsizestack"}}],[11,"drop","","",4,null],[11,"fmt","","",5,null],[11,"new","","Allocates a new stack of **at least** `size` bytes + one additional guard page.",5,{"inputs":[{"name":"usize"}],"output":{"name":"result"}}],[11,"deref","","",5,null],[11,"default","","",5,{"inputs":[],"output":{"name":"protectedfixedsizestack"}}],[11,"drop","","",5,null]],"paths":[[3,"Transfer"],[3,"Context"],[4,"StackError"],[3,"Stack"],[3,"FixedSizeStack"],[3,"ProtectedFixedSizeStack"]]}; initSearch(searchIndex);