| 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 | #![cfg(any(not(feature = "miri-test-libstd"), test, doctest))]
|
| 65 | #![allow(unused_attributes)]
|
| 66 | #![stable(feature = "alloc", since = "1.36.0")]
|
| 67 | #![doc(
|
| 68 | html_playground_url = "https://play.rust-lang.org/",
|
| 69 | issue_tracker_base_url = "https://github.com/rust-lang/rust/issues/",
|
| 70 | test(no_crate_inject, attr(allow(unused_variables), deny(warnings)))
|
| 71 | )]
|
| 72 | #![doc(cfg_hide(
|
| 73 | not(test),
|
| 74 | not(any(test, bootstrap)),
|
| 75 | any(not(feature = "miri-test-libstd"), test, doctest),
|
| 76 | no_global_oom_handling,
|
| 77 | not(no_global_oom_handling),
|
| 78 | target_has_atomic = "ptr"
|
| 79 | ))]
|
| 80 | #![no_std]
|
| 81 | #![needs_allocator]
|
| 82 | |
| 83 | |
| 84 | #![deny(unsafe_op_in_unsafe_fn)]
|
| 85 | #![warn(deprecated_in_future)]
|
| 86 | #![warn(missing_debug_implementations)]
|
| 87 | #![warn(missing_docs)]
|
| 88 | #![allow(explicit_outlives_requirements)]
|
| 89 | |
| 90 | |
| 91 | #![cfg_attr(not(no_global_oom_handling), feature(alloc_c_string))]
|
| 92 | #![feature(alloc_layout_extra)]
|
| 93 | #![feature(allocator_api)]
|
| 94 | #![feature(array_chunks)]
|
| 95 | #![feature(array_methods)]
|
| 96 | #![feature(array_windows)]
|
| 97 | #![feature(assert_matches)]
|
| 98 | #![feature(async_iterator)]
|
| 99 | #![feature(coerce_unsized)]
|
| 100 | #![cfg_attr(not(no_global_oom_handling), feature(const_alloc_error))]
|
| 101 | #![feature(const_box)]
|
| 102 | #![cfg_attr(not(no_global_oom_handling), feature(const_btree_new))]
|
| 103 | #![cfg_attr(not(no_borrow), feature(const_cow_is_borrowed))]
|
| 104 | #![feature(const_convert)]
|
| 105 | #![feature(const_size_of_val)]
|
| 106 | #![feature(const_align_of_val)]
|
| 107 | #![feature(const_ptr_read)]
|
| 108 | #![feature(const_maybe_uninit_write)]
|
| 109 | #![feature(const_maybe_uninit_as_mut_ptr)]
|
| 110 | #![feature(const_refs_to_cell)]
|
| 111 | #![feature(core_c_str)]
|
| 112 | #![feature(core_intrinsics)]
|
| 113 | #![feature(core_ffi_c)]
|
| 114 | #![feature(const_eval_select)]
|
| 115 | #![feature(const_pin)]
|
| 116 | #![feature(cstr_from_bytes_until_nul)]
|
| 117 | #![feature(dispatch_from_dyn)]
|
| 118 | #![feature(exact_size_is_empty)]
|
| 119 | #![feature(extend_one)]
|
| 120 | #![feature(fmt_internals)]
|
| 121 | #![feature(fn_traits)]
|
| 122 | #![feature(hasher_prefixfree_extras)]
|
| 123 | #![feature(inplace_iteration)]
|
| 124 | #![feature(iter_advance_by)]
|
| 125 | #![feature(layout_for_ptr)]
|
| 126 | #![feature(maybe_uninit_slice)]
|
| 127 | #![cfg_attr(test, feature(new_uninit))]
|
| 128 | #![feature(nonnull_slice_from_raw_parts)]
|
| 129 | #![feature(pattern)]
|
| 130 | #![feature(ptr_internals)]
|
| 131 | #![feature(ptr_metadata)]
|
| 132 | #![feature(ptr_sub_ptr)]
|
| 133 | #![feature(receiver_trait)]
|
| 134 | #![feature(set_ptr_value)]
|
| 135 | #![feature(slice_group_by)]
|
| 136 | #![feature(slice_ptr_get)]
|
| 137 | #![feature(slice_ptr_len)]
|
| 138 | #![feature(slice_range)]
|
| 139 | #![feature(str_internals)]
|
| 140 | #![feature(strict_provenance)]
|
| 141 | #![feature(trusted_len)]
|
| 142 | #![feature(trusted_random_access)]
|
| 143 | #![feature(try_trait_v2)]
|
| 144 | #![feature(unchecked_math)]
|
| 145 | #![feature(unicode_internals)]
|
| 146 | #![feature(unsize)]
|
| 147 | |
| 148 | |
| 149 | #![feature(allocator_internals)]
|
| 150 | #![feature(allow_internal_unstable)]
|
| 151 | #![feature(associated_type_bounds)]
|
| 152 | #![feature(box_syntax)]
|
| 153 | #![feature(cfg_sanitize)]
|
| 154 | #![feature(const_deref)]
|
| 155 | #![feature(const_mut_refs)]
|
| 156 | #![feature(const_ptr_write)]
|
| 157 | #![feature(const_precise_live_drops)]
|
| 158 | #![feature(const_trait_impl)]
|
| 159 | #![feature(const_try)]
|
| 160 | #![feature(dropck_eyepatch)]
|
| 161 | #![feature(exclusive_range_pattern)]
|
| 162 | #![feature(fundamental)]
|
| 163 | #![cfg_attr(not(test), feature(generator_trait))]
|
| 164 | #![feature(hashmap_internals)]
|
| 165 | #![feature(lang_items)]
|
| 166 | #![feature(let_else)]
|
| 167 | #![feature(min_specialization)]
|
| 168 | #![feature(negative_impls)]
|
| 169 | #![feature(never_type)]
|
| 170 | #![feature(nll)] |
| 171 | #![feature(rustc_allow_const_fn_unstable)]
|
| 172 | #![feature(rustc_attrs)]
|
| 173 | #![feature(slice_internals)]
|
| 174 | #![feature(staged_api)]
|
| 175 | #![cfg_attr(test, feature(test))]
|
| 176 | #![feature(unboxed_closures)]
|
| 177 | #![feature(unsized_fn_params)]
|
| 178 | #![feature(c_unwind)]
|
| 179 | |
| 180 | |
| 181 | #![feature(doc_cfg)]
|
| 182 | #![feature(doc_cfg_hide)]
|
| 183 | |
| 184 | |
| 185 | |
| 186 | |
| 187 | #![feature(intra_doc_pointers)]
|
| 188 |
|
| 189 | |
| 190 | #[cfg(test)]
|
| 191 | #[macro_use]
|
| 192 | extern crate std;
|
| 193 | #[cfg(test)]
|
| 194 | extern crate test;
|
| 195 |
|
| 196 | |
| 197 | #[cfg(not(no_macros))]
|
| 198 | #[macro_use]
|
| 199 | mod macros;
|
| 200 |
|
| 201 | mod raw_vec;
|
| 202 |
|
| 203 | |
| 204 |
|
| 205 | pub mod alloc;
|
| 206 |
|
| 207 | |
| 208 |
|
| 209 | |
| 210 | |
| 211 | |
| 212 | #[cfg(not(test))]
|
| 213 | pub mod boxed;
|
| 214 | #[cfg(test)]
|
| 215 | mod boxed {
|
| 216 | pub use std::boxed::Box;
|
| 217 | }
|
| 218 | #[cfg(not(no_borrow))]
|
| 219 | pub mod borrow;
|
| 220 | pub mod collections;
|
| 221 | #[cfg(not(no_global_oom_handling))]
|
| 222 | pub mod ffi;
|
| 223 | #[cfg(not(no_fmt))]
|
| 224 | pub mod fmt;
|
| 225 | #[cfg(not(no_rc))]
|
| 226 | pub mod rc;
|
| 227 | pub mod slice;
|
| 228 | #[cfg(not(no_str))]
|
| 229 | pub mod str;
|
| 230 | #[cfg(not(no_string))]
|
| 231 | pub mod string;
|
| 232 | #[cfg(not(no_sync))]
|
| 233 | #[cfg(target_has_atomic = "ptr")]
|
| 234 | pub mod sync;
|
| 235 | #[cfg(all(not(no_global_oom_handling), target_has_atomic = "ptr"))]
|
| 236 | pub mod task;
|
| 237 | #[cfg(test)]
|
| 238 | mod tests;
|
| 239 | pub mod vec;
|
| 240 |
|
| 241 | #[doc(hidden)]
|
| 242 | #[unstable(feature = "liballoc_internals", issue = "none", reason = "implementation detail")]
|
| 243 | pub mod __export {
|
| 244 | pub use core::format_args;
|
| 245 | }
|