about summary refs log tree commit diff
path: root/src/lib/std.rc
blob: e691fb9d72c44fcc932477b8e329e53c581814f4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
meta (name = "std",
      desc = "Rust standard library",
      uuid = "122bed0b-c19b-4b82-b0b7-7ae8aead7297",
      url = "http://rust-lang.org/src/std",
      ver = "0.0.1");

// Built-in types support modules.

mod _int;
mod _uint;
mod _u8;
mod _vec;
mod _str;

// General IO and system-services modules.

mod io;
mod sys;
mod _task;

// Utility modules.

mod option;
mod util;

// Authorize various rule-bendings.

auth io = unsafe;
auth fs = unsafe;
auth os = unsafe;
auth os_fs = unsafe;
auth run = unsafe;
auth _str = unsafe;
auth _vec = unsafe;
auth _task = unsafe;


// FIXME: impure on these will infect caller in a way that is totally
// beyond reason, if the caller's mutated-argument doesn't escape;
// 'impure' needs work.
auth _str.unshift_byte = impure;
auth _str.shift_byte = impure;
auth _str.pop_byte = impure;
auth _str.unshift_char = impure;
auth _str.shift_char = impure;
auth _str.pop_char = impure;
auth _vec.shift = impure;
auth _vec.unshift = impure;
auth _vec.pop = impure;

auth dbg = unsafe;

auth _uint.next_power_of_two = unsafe;
auth map.mk_hashmap = unsafe;
auth rand.mk_rng = unsafe;

// Target-OS module.

alt (target_os) {
    case ("win32") {
        mod os = "win32_os.rs";
        mod os_fs = "win32_fs.rs";
    } case ("macos") {
        mod os = "macos_os.rs";
        mod os_fs = "posix_fs.rs";
    } else {
        mod os = "linux_os.rs";
        mod os_fs = "posix_fs.rs";
    }
}
mod run = "run_program.rs";
mod fs;

// FIXME: parametric
mod map;
mod deque;
mod list;
mod rand;
mod dbg;
mod bitv;
mod sort;
mod sha1;
mod ebml;

// Local Variables:
// mode: rust;
// fill-column: 78;
// indent-tabs-mode: nil
// c-basic-offset: 4
// buffer-file-coding-system: utf-8-unix
// compile-command: "make -k -C .. 2>&1 | sed -e 's/\\/x\\//x:\\//g'";
// End: