Skip to content

Commit fb85124

Browse files
committed
Promote 'pub' and 'priv' from restricted to strict keywords
1 parent 8672b90 commit fb85124

File tree

5 files changed

+6
-7
lines changed

5 files changed

+6
-7
lines changed

src/libcore/core.rc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ export option_iter;
6767

6868
// This creates some APIs that I do not want to commit to, but it must be
6969
// exported from core in order for uv to remain in std (see #2648).
70-
export priv;
70+
export private;
7171

7272

7373
// Built-in-type support modules
@@ -241,7 +241,7 @@ mod rt;
241241
// For internal use, not exported
242242

243243
mod unicode;
244-
mod priv;
244+
mod private;
245245
mod cmath;
246246
mod stackwalk;
247247

src/libcore/os.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ mod global_env {
174174
fn get_global_env_chan() -> comm::Chan<Msg> {
175175
let global_ptr = rustrt::rust_global_env_chan_ptr();
176176
unsafe {
177-
priv::chan_from_global_ptr(global_ptr, || {
177+
private::chan_from_global_ptr(global_ptr, || {
178178
// FIXME (#2621): This would be a good place to use a very
179179
// small foreign stack
180180
task::task().sched_mode(task::SingleThreaded).unlinked()
@@ -184,7 +184,7 @@ mod global_env {
184184

185185
fn global_env_task(msg_po: comm::Port<Msg>) {
186186
unsafe {
187-
do priv::weaken_task |weak_po| {
187+
do private::weaken_task |weak_po| {
188188
loop {
189189
match comm::select2(msg_po, weak_po) {
190190
either::Left(MsgGetEnv(n, resp_ch)) => {
File renamed without changes.

src/libstd/uv_global_loop.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use ll = uv_ll;
66
use iotask = uv_iotask;
77
use get_gl = get;
88
use iotask::{IoTask, spawn_iotask};
9-
use priv::{chan_from_global_ptr, weaken_task};
9+
use private::{chan_from_global_ptr, weaken_task};
1010
use comm = core::comm;
1111
use comm::{Port, Chan, select2, listen};
1212
use task::TaskBuilder;

src/libsyntax/parse/token.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -414,7 +414,6 @@ fn restricted_keyword_table() -> HashMap<~str, ()> {
414414
~"const", ~"copy",
415415
~"fail", ~"fn",
416416
~"impl",
417-
~"priv", ~"pub",
418417
~"unsafe"
419418
];
420419
for keys.each |word| {
@@ -435,7 +434,7 @@ fn strict_keyword_table() -> HashMap<~str, ()> {
435434
~"if",
436435
~"let", ~"log", ~"loop",
437436
~"match", ~"mod", ~"move", ~"mut",
438-
~"pure",
437+
~"priv", ~"pub", ~"pure",
439438
~"ref", ~"return",
440439
~"struct",
441440
~"true", ~"trait", ~"type",

0 commit comments

Comments
 (0)