Copy first batch of material from libstd to libcore.

This commit is contained in:
Graydon Hoare 2011-12-13 16:25:51 -08:00
parent 32087f5c2a
commit fa9ad984fb
325 changed files with 5579 additions and 720 deletions

View file

@ -1,7 +1,7 @@
import std::{str, option};
import core::{str, option};
import std::math::{max, min};
import std::map::hashmap;
import std::option::{some};
import option::{some};
import syntax::ast;
import ast::{ty, pat};
import syntax::codemap::{span};
@ -82,7 +82,7 @@ fn local_rhs_span(l: @ast::local, def: span) -> span {
}
fn is_main_name(path: [ast::ident]) -> bool {
str::eq(option::get(std::vec::last(path)), "main")
str::eq(option::get(vec::last(path)), "main")
}

View file

@ -2,9 +2,9 @@
// FIXME: I'm not happy how this module turned out. Should probably
// just be folded into cstore.
import std::option;
import core::option;
import std::fs;
import std::vec;
import vec;
import std::os;
export filesearch;

View file

@ -1,5 +1,5 @@
import std::{vec, str, int, option};
import std::option::{none, some};
import core::{vec, str, int, option};
import option::{none, some};
import middle::ty;
import middle::ty::*;
import metadata::encoder;