Merge crate collections into alloc
This commit is contained in:
parent
e40ef964fe
commit
eadda7665e
97 changed files with 2348 additions and 2517 deletions
|
|
@ -8,18 +8,18 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
#![feature(alloc)]
|
||||
|
||||
extern crate collections;
|
||||
//~^ NOTE previous import of `collections` here
|
||||
extern crate alloc;
|
||||
//~^ NOTE previous import of `alloc` here
|
||||
|
||||
mod foo {
|
||||
pub trait collections {
|
||||
pub trait alloc {
|
||||
fn do_something();
|
||||
}
|
||||
}
|
||||
|
||||
use foo::collections;
|
||||
use foo::alloc;
|
||||
//~^ ERROR E0254
|
||||
//~| NOTE already imported
|
||||
|
||||
|
|
|
|||
|
|
@ -8,13 +8,13 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections, libc)]
|
||||
#![feature(alloc, libc)]
|
||||
|
||||
extern crate collections;
|
||||
//~^ NOTE previous import of `collections` here
|
||||
extern crate alloc;
|
||||
//~^ NOTE previous import of `alloc` here
|
||||
|
||||
extern crate libc as collections;
|
||||
extern crate libc as alloc;
|
||||
//~^ ERROR E0259
|
||||
//~| NOTE `collections` already imported
|
||||
//~| NOTE `alloc` already imported
|
||||
|
||||
fn main() {}
|
||||
|
|
|
|||
|
|
@ -8,14 +8,14 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
#![feature(alloc)]
|
||||
|
||||
extern crate collections;
|
||||
//~^ NOTE previous import of `collections` here
|
||||
extern crate alloc;
|
||||
//~^ NOTE previous import of `alloc` here
|
||||
|
||||
mod collections {
|
||||
//~^ ERROR `collections` has already been imported in this module [E0260]
|
||||
//~| NOTE `collections` already imported
|
||||
mod alloc {
|
||||
//~^ ERROR `alloc` has already been imported in this module [E0260]
|
||||
//~| NOTE `alloc` already imported
|
||||
pub trait MyTrait {
|
||||
fn do_something();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -13,13 +13,13 @@
|
|||
#![deny(unused_extern_crates)]
|
||||
#![allow(unused_variables)]
|
||||
#![allow(deprecated)]
|
||||
#![feature(alloc)]
|
||||
#![feature(libc)]
|
||||
#![feature(collections)]
|
||||
#![feature(rand)]
|
||||
|
||||
extern crate libc; //~ ERROR: unused extern crate
|
||||
|
||||
extern crate collections as collecs; // no error, it is used
|
||||
extern crate alloc as collecs; // no error, it is used
|
||||
|
||||
extern crate rand; // no error, the use marks it as used
|
||||
// even if imported objects aren't used
|
||||
|
|
|
|||
|
|
@ -8,25 +8,25 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
#![feature(alloc)]
|
||||
|
||||
mod a {
|
||||
extern crate collections;
|
||||
use collections::HashMap;
|
||||
//~^ ERROR unresolved import `collections::HashMap` [E0432]
|
||||
//~| Did you mean `self::collections`?
|
||||
extern crate alloc;
|
||||
use alloc::HashMap;
|
||||
//~^ ERROR unresolved import `alloc::HashMap` [E0432]
|
||||
//~| Did you mean `self::alloc`?
|
||||
mod b {
|
||||
use collections::HashMap;
|
||||
//~^ ERROR unresolved import `collections::HashMap` [E0432]
|
||||
//~| Did you mean `a::collections`?
|
||||
use alloc::HashMap;
|
||||
//~^ ERROR unresolved import `alloc::HashMap` [E0432]
|
||||
//~| Did you mean `a::alloc`?
|
||||
mod c {
|
||||
use collections::HashMap;
|
||||
//~^ ERROR unresolved import `collections::HashMap` [E0432]
|
||||
//~| Did you mean `a::collections`?
|
||||
use alloc::HashMap;
|
||||
//~^ ERROR unresolved import `alloc::HashMap` [E0432]
|
||||
//~| Did you mean `a::alloc`?
|
||||
mod d {
|
||||
use collections::HashMap;
|
||||
//~^ ERROR unresolved import `collections::HashMap` [E0432]
|
||||
//~| Did you mean `a::collections`?
|
||||
use alloc::HashMap;
|
||||
//~^ ERROR unresolved import `alloc::HashMap` [E0432]
|
||||
//~| Did you mean `a::alloc`?
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,10 +8,8 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
#![feature(rustc_private)]
|
||||
|
||||
extern crate collections;
|
||||
extern crate serialize;
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
|
|
|||
|
|
@ -15,10 +15,9 @@
|
|||
// - Multiple lifetime parameters
|
||||
// - Arenas
|
||||
|
||||
#![feature(rustc_private, libc, collections)]
|
||||
#![feature(rustc_private, libc)]
|
||||
|
||||
extern crate arena;
|
||||
extern crate collections;
|
||||
extern crate libc;
|
||||
|
||||
use TypeStructure::{TypeInt, TypeFunction};
|
||||
|
|
|
|||
|
|
@ -9,8 +9,6 @@
|
|||
// except according to those terms.
|
||||
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
fn main() {
|
||||
let args = vec!["foobie", "asdf::asdf"];
|
||||
let arr: Vec<&str> = args[1].split("::").collect();
|
||||
|
|
|
|||
|
|
@ -8,12 +8,12 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(lang_items, start, collections)]
|
||||
#![feature(lang_items, start, alloc)]
|
||||
#![no_std]
|
||||
|
||||
extern crate std as other;
|
||||
|
||||
#[macro_use] extern crate collections;
|
||||
#[macro_use] extern crate alloc;
|
||||
|
||||
#[start]
|
||||
fn start(_argc: isize, _argv: *const *const u8) -> isize {
|
||||
|
|
|
|||
|
|
@ -9,10 +9,6 @@
|
|||
// except according to those terms.
|
||||
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
extern crate collections;
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
||||
// This is a fancy one: it uses an external iterator established
|
||||
|
|
|
|||
|
|
@ -9,10 +9,6 @@
|
|||
// except according to those terms.
|
||||
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
extern crate collections;
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
||||
pub fn main() {
|
||||
|
|
|
|||
|
|
@ -10,14 +10,14 @@
|
|||
|
||||
// ignore-emscripten missing rust_begin_unwind
|
||||
|
||||
#![feature(lang_items, start, collections)]
|
||||
#![feature(lang_items, start, alloc)]
|
||||
#![no_std]
|
||||
|
||||
extern crate std as other;
|
||||
|
||||
#[macro_use] extern crate collections;
|
||||
#[macro_use] extern crate alloc;
|
||||
|
||||
use collections::string::ToString;
|
||||
use alloc::string::ToString;
|
||||
|
||||
#[start]
|
||||
fn start(_argc: isize, _argv: *const *const u8) -> isize {
|
||||
|
|
|
|||
|
|
@ -8,10 +8,6 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
extern crate collections;
|
||||
|
||||
use std::collections::HashSet;
|
||||
|
||||
#[derive(Copy, Clone, PartialEq, Eq, Hash)]
|
||||
|
|
|
|||
|
|
@ -8,10 +8,6 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
extern crate collections;
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
||||
pub fn main() {
|
||||
|
|
|
|||
|
|
@ -9,8 +9,6 @@
|
|||
// except according to those terms.
|
||||
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
fn main() {
|
||||
let mut escaped = String::from("");
|
||||
for c in '\u{10401}'.escape_unicode() {
|
||||
|
|
|
|||
|
|
@ -10,9 +10,6 @@
|
|||
|
||||
// pretty-expanded FIXME #23616
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
extern crate collections;
|
||||
use std::collections::VecDeque;
|
||||
|
||||
pub fn main() {
|
||||
|
|
|
|||
|
|
@ -11,10 +11,6 @@
|
|||
// Minimized version of issue-2804.rs. Both check that callee IDs don't
|
||||
// clobber the previous node ID in a macro expr
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
extern crate collections;
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
||||
fn add_interfaces(managed_ip: String, device: HashMap<String, isize>) {
|
||||
|
|
|
|||
|
|
@ -10,10 +10,7 @@
|
|||
|
||||
// pretty-expanded FIXME #23616
|
||||
|
||||
#![allow(unknown_features)]
|
||||
#![feature(box_syntax, collections)]
|
||||
|
||||
extern crate collections;
|
||||
#![feature(box_syntax)]
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
||||
|
|
|
|||
|
|
@ -8,10 +8,6 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
extern crate collections;
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
||||
fn check_strs(actual: &str, expected: &str) -> bool {
|
||||
|
|
|
|||
|
|
@ -9,10 +9,7 @@
|
|||
// except according to those terms.
|
||||
|
||||
|
||||
#![allow(unknown_features)]
|
||||
#![feature(box_syntax, collections)]
|
||||
|
||||
extern crate collections;
|
||||
#![feature(box_syntax)]
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
||||
|
|
|
|||
|
|
@ -13,10 +13,6 @@
|
|||
|
||||
// pretty-expanded FIXME #23616
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
extern crate collections;
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
||||
struct A(isize, isize);
|
||||
|
|
|
|||
|
|
@ -8,8 +8,6 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
use std::string::String;
|
||||
|
||||
fn test_stack_assign() {
|
||||
|
|
|
|||
|
|
@ -9,8 +9,6 @@
|
|||
// except according to those terms.
|
||||
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
pub fn main() {
|
||||
let s = "\u{2603}";
|
||||
assert_eq!(s, "☃");
|
||||
|
|
|
|||
|
|
@ -8,8 +8,6 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
pub fn main() {
|
||||
let thing = "{{ f }}";
|
||||
let f = thing.find("{{");
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
// except according to those terms.
|
||||
|
||||
#![allow(unknown_features)]
|
||||
#![feature(box_syntax, collections, core)]
|
||||
#![feature(box_syntax, core)]
|
||||
|
||||
use std::cell::RefCell;
|
||||
use std::rc::Rc;
|
||||
|
|
|
|||
|
|
@ -8,8 +8,6 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
use std::cell::RefCell;
|
||||
use std::rc::Rc;
|
||||
use std::string::String;
|
||||
|
|
|
|||
|
|
@ -9,21 +9,16 @@
|
|||
// except according to those terms.
|
||||
|
||||
#![allow(warnings)]
|
||||
#![feature(collections)]
|
||||
#![feature(drain, collections_bound, btree_range, vecmap)]
|
||||
|
||||
extern crate collections;
|
||||
|
||||
use collections::BinaryHeap;
|
||||
use collections::{BTreeMap, BTreeSet};
|
||||
use collections::LinkedList;
|
||||
use collections::String;
|
||||
use collections::Vec;
|
||||
use collections::VecDeque;
|
||||
use std::collections::BinaryHeap;
|
||||
use std::collections::{BTreeMap, BTreeSet};
|
||||
use std::collections::LinkedList;
|
||||
use std::collections::VecDeque;
|
||||
use std::collections::HashMap;
|
||||
use std::collections::HashSet;
|
||||
|
||||
use collections::Bound::Included;
|
||||
use std::collections::Bound::Included;
|
||||
use std::mem;
|
||||
|
||||
fn is_sync<T>(_: T) where T: Sync {}
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
// except according to those terms.
|
||||
//
|
||||
|
||||
#![feature(collections, core, str_char)]
|
||||
#![feature(core, str_char)]
|
||||
|
||||
use std::str;
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(lang_items, start, libc, collections)]
|
||||
#![feature(lang_items, start, libc, alloc)]
|
||||
#![no_std]
|
||||
|
||||
extern crate std as other;
|
||||
|
|
@ -16,9 +16,9 @@ extern crate std as other;
|
|||
extern crate libc;
|
||||
|
||||
#[macro_use]
|
||||
extern crate collections;
|
||||
extern crate alloc;
|
||||
|
||||
use collections::vec::Vec;
|
||||
use alloc::vec::Vec;
|
||||
|
||||
// Issue #16806
|
||||
|
||||
|
|
|
|||
|
|
@ -8,8 +8,6 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(collections)]
|
||||
|
||||
use std::string::String;
|
||||
|
||||
#[derive(PartialEq)]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue