diff options
| author | bors <bors@rust-lang.org> | 2014-01-09 20:21:17 -0800 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-01-09 20:21:17 -0800 |
| commit | f78293c274be2a23889f20942d75e9e45352a336 (patch) | |
| tree | 3d2f7a36b53f2f5db5719901fb0e6b382814a613 /src/libstd/rt | |
| parent | 28ddc6537fcec5eb6033c78709b288abf72e8ae7 (diff) | |
| parent | 65ce505819b0f2e06ed39802d293bff182aedc16 (diff) | |
| download | rust-f78293c274be2a23889f20942d75e9e45352a336.tar.gz rust-f78293c274be2a23889f20942d75e9e45352a336.zip | |
auto merge of #11360 : huonw/rust/stack_bounds, r=alexcrichton
We just approximate with a 2MB stack for native::start.
Diffstat (limited to 'src/libstd/rt')
| -rw-r--r-- | src/libstd/rt/mod.rs | 3 | ||||
| -rw-r--r-- | src/libstd/rt/task.rs | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/libstd/rt/mod.rs b/src/libstd/rt/mod.rs index d839ef62af9..e7adb5ad7dd 100644 --- a/src/libstd/rt/mod.rs +++ b/src/libstd/rt/mod.rs @@ -154,7 +154,8 @@ pub trait Runtime { // you're in. fn spawn_sibling(~self, cur_task: ~Task, opts: TaskOpts, f: proc()); fn local_io<'a>(&'a mut self) -> Option<rtio::LocalIo<'a>>; - fn stack_bounds(&self) -> Option<(uint, uint)>; // (lo, hi) + /// The (low, high) edges of the current stack. + fn stack_bounds(&self) -> (uint, uint); // (lo, hi) // XXX: This is a serious code smell and this should not exist at all. fn wrap(~self) -> ~Any; diff --git a/src/libstd/rt/task.rs b/src/libstd/rt/task.rs index 6c94f237789..b4ead4252ca 100644 --- a/src/libstd/rt/task.rs +++ b/src/libstd/rt/task.rs @@ -289,7 +289,7 @@ impl Task { /// Returns the stack bounds for this task in (lo, hi) format. The stack /// bounds may not be known for all tasks, so the return value may be /// `None`. - pub fn stack_bounds(&self) -> Option<(uint, uint)> { + pub fn stack_bounds(&self) -> (uint, uint) { self.imp.get_ref().stack_bounds() } } |
