Skip to content

Commit 18af3ca

Browse files
committed
---
yaml --- r: 93789 b: refs/heads/try c: 1de47cb h: refs/heads/master i: 93787: 81f060b v: v3
1 parent fe5352c commit 18af3ca

File tree

23 files changed

+58
-224
lines changed

23 files changed

+58
-224
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: 0da105a8b7b6b1e0568e8ff20f6ff4b13cc7ecc2
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: a6d3e57dca68fde4effdda3e4ae2887aa535fcd6
5-
refs/heads/try: 8464004c7692a79d2df375d3c249da27548dc370
5+
refs/heads/try: 1de47cb84286dd769b398da5d7dd1df2fd6f3406
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c

branches/try/configure

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -520,20 +520,14 @@ then
520520
fi
521521
fi
522522

523-
BIN_SUF=
524-
if [ $CFG_OSTYPE = "pc-mingw32" ]
525-
then
526-
BIN_SUF=.exe
527-
fi
528-
529523
if [ ! -z "$CFG_ENABLE_LOCAL_RUST" ]
530524
then
531-
if [ ! -f ${CFG_LOCAL_RUST_ROOT}/bin/rustc${BIN_SUF} ]
525+
if [ ! -f ${CFG_LOCAL_RUST_ROOT}/bin/rustc ]
532526
then
533527
err "no local rust to use"
534528
else
535-
LRV=`${CFG_LOCAL_RUST_ROOT}/bin/rustc${BIN_SUF} --version`
536-
step_msg "using rustc at: ${CFG_LOCAL_RUST_ROOT} with version: $LRV"
529+
LRV=`${CFG_LOCAL_RUST_ROOT}/bin/rustc --version`
530+
step_msg "using rustc at: ${CFG_LOCAL_RUST_ROOT} with version: " $LRV
537531
fi
538532
fi
539533

branches/try/doc/rust.md

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1131,9 +1131,8 @@ block.
11311131
let fptr: extern "C" fn() -> ~[int] = new_vec;
11321132
~~~~
11331133

1134-
Extern functions may be called from Rust code, but
1135-
caution must be taken with respect to the size of the stack
1136-
segment, just as when calling an extern function normally.
1134+
Extern functions may be called directly from Rust code as Rust uses large,
1135+
contiguous stack segments like C.
11371136

11381137
### Type definitions
11391138

@@ -3162,7 +3161,7 @@ Borrowed pointers (`&`)
31623161
Borrowed pointers arise by (automatic) conversion from owning pointers, managed pointers,
31633162
or by applying the borrowing operator `&` to some other value,
31643163
including [lvalues, rvalues or temporaries](#lvalues-rvalues-and-temporaries).
3165-
Borrowed pointers are written `&content`, or in some cases `&'f content` for some lifetime-variable `f`,
3164+
Borrowed pointers are written `&content`, or in some cases `&f/content` for some lifetime-variable `f`,
31663165
for example `&int` means a borrowed pointer to an integer.
31673166
Copying a borrowed pointer is a "shallow" operation:
31683167
it involves only copying the pointer itself.
@@ -3597,9 +3596,9 @@ and releases them back to its environment when they are no longer needed.
35973596
The default implementation of the service-provider interface
35983597
consists of the C runtime functions `malloc` and `free`.
35993598

3600-
The runtime memory-management system, in turn, supplies Rust tasks
3601-
with facilities for allocating, extending and releasing stacks,
3602-
as well as allocating and freeing heap data.
3599+
The runtime memory-management system, in turn, supplies Rust tasks with
3600+
facilities for allocating releasing stacks, as well as allocating and freeing
3601+
heap data.
36033602

36043603
### Built in types
36053604

@@ -3762,7 +3761,6 @@ have come and gone during the course of Rust's development:
37623761

37633762
Additional specific influences can be seen from the following languages:
37643763

3765-
* The stack-growth implementation of Go.
37663764
* The structural algebraic types and compilation manager of SML.
37673765
* The attribute and assembly systems of C#.
37683766
* The references and deterministic destructor system of C++.

branches/try/src/etc/local_stage0.sh

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
TARG_DIR=$1
44
PREFIX=$2
55

6-
LIB_DIR=lib
7-
LIB_PREFIX=lib
6+
BINDIR=bin
7+
LIBDIR=lib
88

99
OS=`uname -s`
1010
case $OS in
@@ -21,8 +21,7 @@ case $OS in
2121
(*)
2222
BIN_SUF=.exe
2323
LIB_SUF=.dll
24-
LIB_DIR=bin
25-
LIB_PREFIX=
24+
LIBDIR=bin
2625
break
2726
;;
2827
esac
@@ -32,7 +31,7 @@ if [ -z $PREFIX ]; then
3231
exit 1
3332
fi
3433

35-
if [ ! -e ${PREFIX}/bin/rustc${BIN_SUF} ]; then
34+
if [ ! -e ${PREFIX}/bin/rustc ]; then
3635
echo "No local rust installed at ${PREFIX}"
3736
exit 1
3837
fi
@@ -42,9 +41,9 @@ if [ -z $TARG_DIR ]; then
4241
exit 1
4342
fi
4443

45-
cp ${PREFIX}/bin/rustc${BIN_SUF} ${TARG_DIR}/stage0/bin/
46-
cp ${PREFIX}/${LIB_DIR}/rustc/${TARG_DIR}/${LIB_DIR}/* ${TARG_DIR}/stage0/${LIB_DIR}/
47-
cp ${PREFIX}/${LIB_DIR}/${LIB_PREFIX}extra*${LIB_SUF} ${TARG_DIR}/stage0/${LIB_DIR}/
48-
cp ${PREFIX}/${LIB_DIR}/${LIB_PREFIX}rust*${LIB_SUF} ${TARG_DIR}/stage0/${LIB_DIR}/
49-
cp ${PREFIX}/${LIB_DIR}/${LIB_PREFIX}std*${LIB_SUF} ${TARG_DIR}/stage0/${LIB_DIR}/
50-
cp ${PREFIX}/${LIB_DIR}/${LIB_PREFIX}syntax*${LIB_SUF} ${TARG_DIR}/stage0/${LIB_DIR}/
44+
cp ${PREFIX}/bin/rustc ${TARG_DIR}/stage0/bin/
45+
cp ${PREFIX}/lib/rustc/${TARG_DIR}/${LIBDIR}/* ${TARG_DIR}/stage0/${LIBDIR}/
46+
cp ${PREFIX}/lib/libextra*${LIB_SUF} ${TARG_DIR}/stage0/${LIBDIR}/
47+
cp ${PREFIX}/lib/librust*${LIB_SUF} ${TARG_DIR}/stage0/${LIBDIR}/
48+
cp ${PREFIX}/lib/libstd*${LIB_SUF} ${TARG_DIR}/stage0/${LIBDIR}/
49+
cp ${PREFIX}/lib/libsyntax*${LIB_SUF} ${TARG_DIR}/stage0/${LIBDIR}/

branches/try/src/libextra/sync.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -326,7 +326,7 @@ impl Sem<~[WaitQueue]> {
326326
// and rwlock_write_mode.
327327
pub fn access_cond<U>(&self, blk: |c: &Condvar| -> U) -> U {
328328
do self.access {
329-
blk(&Condvar { sem: self, order: Nothing, token: NonCopyable })
329+
blk(&Condvar { sem: self, order: Nothing, token: NonCopyable::new() })
330330
}
331331
}
332332
}
@@ -569,7 +569,7 @@ impl RWLock {
569569
do task::rekillable {
570570
let opt_lock = Just(&self.order_lock);
571571
blk(&Condvar { sem: cond.sem, order: opt_lock,
572-
token: NonCopyable })
572+
token: NonCopyable::new() })
573573
}
574574
}
575575
}
@@ -605,7 +605,7 @@ impl RWLock {
605605
(&self.order_lock).release();
606606
do (|| {
607607
do task::rekillable {
608-
blk(RWLockWriteMode { lock: self, token: NonCopyable })
608+
blk(RWLockWriteMode { lock: self, token: NonCopyable::new() })
609609
}
610610
}).finally {
611611
let writer_or_last_reader;
@@ -662,7 +662,7 @@ impl RWLock {
662662
}
663663
}
664664
}
665-
RWLockReadMode { lock: token.lock, token: NonCopyable }
665+
RWLockReadMode { lock: token.lock, token: NonCopyable::new() }
666666
}
667667
}
668668

@@ -682,7 +682,7 @@ impl<'self> RWLockWriteMode<'self> {
682682
// access lock. See comment in RWLock::write_cond for why.
683683
blk(&Condvar { sem: &self.lock.access_lock,
684684
order: Just(&self.lock.order_lock),
685-
token: NonCopyable })
685+
token: NonCopyable::new() })
686686
}
687687
}
688688

branches/try/src/librustc/lib/llvm.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ pub enum CallConv {
3333
ColdCallConv = 9,
3434
X86StdcallCallConv = 64,
3535
X86FastcallCallConv = 65,
36-
X86_64_Win64 = 79,
3736
}
3837

3938
pub enum Visibility {

branches/try/src/librustc/middle/resolve.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ use syntax::parse::token;
2929
use syntax::parse::token::{ident_interner, interner_get};
3030
use syntax::parse::token::special_idents;
3131
use syntax::print::pprust::path_to_str;
32-
use syntax::codemap::{Span, dummy_sp, Pos};
32+
use syntax::codemap::{Span, dummy_sp, BytePos};
3333
use syntax::opt_vec::OptVec;
3434
use syntax::visit;
3535
use syntax::visit::Visitor;
@@ -2624,7 +2624,7 @@ impl Resolver {
26242624
if "???" == module_name {
26252625
let span = Span {
26262626
lo: span.lo,
2627-
hi: span.lo + Pos::from_uint(segment_name.len()),
2627+
hi: span.lo + BytePos(segment_name.len()),
26282628
expn_info: span.expn_info,
26292629
};
26302630
self.resolve_error(span,

branches/try/src/librustc/middle/trans/foreign.rs

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ use syntax::{ast};
3333
use syntax::{attr, ast_map};
3434
use syntax::parse::token::special_idents;
3535
use syntax::abi::{RustIntrinsic, Rust, Stdcall, Fastcall, System,
36-
Cdecl, Aapcs, C, AbiSet, Win64};
36+
Cdecl, Aapcs, C, AbiSet};
3737
use util::ppaux::{Repr, UserString};
3838
use middle::trans::type_::Type;
3939

@@ -96,7 +96,6 @@ pub fn llvm_calling_convention(ccx: &mut CrateContext,
9696
Stdcall => lib::llvm::X86StdcallCallConv,
9797
Fastcall => lib::llvm::X86FastcallCallConv,
9898
C => lib::llvm::CCallConv,
99-
Win64 => lib::llvm::X86_64_Win64,
10099

101100
// NOTE These API constants ought to be more specific
102101
Cdecl => lib::llvm::CCallConv,
@@ -399,19 +398,11 @@ pub fn register_rust_fn_with_foreign_abi(ccx: @mut CrateContext,
399398

400399
let tys = foreign_types_for_id(ccx, node_id);
401400
let llfn_ty = lltype_for_fn_from_foreign_types(&tys);
402-
let t = ty::node_id_to_type(ccx.tcx, node_id);
403-
let cconv = match ty::get(t).sty {
404-
ty::ty_bare_fn(ref fn_ty) => {
405-
let c = llvm_calling_convention(ccx, fn_ty.abis);
406-
c.unwrap_or(lib::llvm::CCallConv)
407-
}
408-
_ => lib::llvm::CCallConv
409-
};
410401
let llfn = base::register_fn_llvmty(ccx,
411402
sp,
412403
sym,
413404
node_id,
414-
cconv,
405+
lib::llvm::CCallConv,
415406
llfn_ty);
416407
add_argument_attributes(&tys, llfn);
417408
debug!("register_rust_fn_with_foreign_abi(node_id={:?}, llfn_ty={}, llfn={})",

branches/try/src/librustc/middle/typeck/astconv.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -560,6 +560,10 @@ pub fn ast_ty_to_ty<AC:AstConv, RS:RegionScope>(
560560
ast_ty.span,
561561
"found `ty_infer` in unexpected place");
562562
}
563+
ast::ty_mac(_) => {
564+
tcx.sess.span_bug(ast_ty.span,
565+
"found `ty_mac` in unexpected place");
566+
}
563567
};
564568

565569
tcx.ast_ty_to_ty_cache.insert(ast_ty.id, ty::atttce_resolved(typ));

branches/try/src/libstd/gc.rs

Lines changed: 0 additions & 99 deletions
This file was deleted.

branches/try/src/libstd/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,6 @@ pub mod owned;
133133
pub mod managed;
134134
pub mod borrow;
135135
pub mod rc;
136-
pub mod gc;
137136

138137

139138
/* Core language traits */

branches/try/src/libstd/util.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,12 @@ pub fn replace<T>(dest: &mut T, mut src: T) -> T {
6262
#[unsafe_no_drop_flag]
6363
pub struct NonCopyable;
6464

65+
impl NonCopyable {
66+
// FIXME(#8233) should not be necessary
67+
/// Create a new noncopyable token.
68+
pub fn new() -> NonCopyable { NonCopyable }
69+
}
70+
6571
impl Drop for NonCopyable {
6672
fn drop(&mut self) { }
6773
}

branches/try/src/libsyntax/abi.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ pub enum Abi {
2323
Stdcall,
2424
Fastcall,
2525
Aapcs,
26-
Win64,
2726

2827
// Multiplatform ABIs second
2928
Rust,
@@ -74,8 +73,6 @@ static AbiDatas: &'static [AbiData] = &[
7473
AbiData {abi: Stdcall, name: "stdcall", abi_arch: Archs(IntelBits)},
7574
AbiData {abi: Fastcall, name:"fastcall", abi_arch: Archs(IntelBits)},
7675
AbiData {abi: Aapcs, name: "aapcs", abi_arch: Archs(ArmBits)},
77-
AbiData {abi: Win64, name: "win64",
78-
abi_arch: Archs(1 << (X86_64 as uint))},
7976

8077
// Cross-platform ABIs
8178
//

branches/try/src/libsyntax/ast.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -861,6 +861,7 @@ pub enum ty_ {
861861
ty_bare_fn(@TyBareFn),
862862
ty_tup(~[Ty]),
863863
ty_path(Path, Option<OptVec<TyParamBound>>, NodeId), // for #7264; see above
864+
ty_mac(mac),
864865
ty_typeof(@Expr),
865866
// ty_infer means the type should be inferred instead of it having been
866867
// specified. This should only appear at the "top level" of a type and not

0 commit comments

Comments
 (0)