about summary refs log tree commit diff
path: root/src/rt/rust_kernel.cpp
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2013-06-29 02:34:43 -0700
committerbors <bors@rust-lang.org>2013-06-29 02:34:43 -0700
commitc80e3bac3e676abb106f7ef8ac7da5b153c65c8e (patch)
treedc1a7abef3d983d7a13e9a94f987e63b2fb78e44 /src/rt/rust_kernel.cpp
parenta229c980c8c8e628571008882bd7da71f2b3ef7a (diff)
parente0788c7f523dc13609179b8f40c09af5c8668df6 (diff)
downloadrust-c80e3bac3e676abb106f7ef8ac7da5b153c65c8e.tar.gz
rust-c80e3bac3e676abb106f7ef8ac7da5b153c65c8e.zip
auto merge of #7244 : bblum/rust/once, r=nikomatsakis
@graydon suggested that once closures not be part of the language for 1.0, but that they might be hidden behind a -Z compile flag as an "experimental feature" in case people decide they need them.

Regardless of whether ```-Z once-fns``` is set, this PR will parse the ```once``` keyword and will prevent closures labelled with it from being called more than once. It will also permit moving out of captured vars in heap closures, just to let the runtime writers stop using ```Cell``` sooner. Setting ```-Z once-fns``` only toggles whether the move-out-from-capture privilege is also given for stack closures.

r? @nikomatsakis
Diffstat (limited to 'src/rt/rust_kernel.cpp')
0 files changed, 0 insertions, 0 deletions