Skip to content

Commit 7f5cea2

Browse files
committed
---
yaml --- r: 15623 b: refs/heads/try c: 1c39fda h: refs/heads/master i: 15621: c64f84c 15619: 688f49b 15615: d916bbd v: v3
1 parent ec08dca commit 7f5cea2

File tree

6 files changed

+7
-7
lines changed

6 files changed

+7
-7
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
refs/heads/master: 61b1875c16de39c166b0f4d54bba19f9c6777d1a
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 4a81779abd786ff22d71434c6d9a5917ea4cdfff
5-
refs/heads/try: 9280d0c090ab62a1800c0e423b1da95b1e7db7ec
5+
refs/heads/try: 1c39fda0eaeb2f0e7bf37f0cac3541fb0cbc285f
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105

branches/try/src/libcore/option.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ pure fn is_some<T>(opt: option<T>) -> bool {
5252
!is_none(opt)
5353
}
5454

55-
pure fn get_or_default<T: copy>(opt: option<T>, def: T) -> T {
55+
pure fn get_default<T: copy>(opt: option<T>, def: T) -> T {
5656
#[doc = "Returns the contained value or a default"];
5757

5858
alt opt { some(x) { x } none { def } }
@@ -94,7 +94,7 @@ impl extensions<T:copy> for option<T> {
9494
"]
9595
fn chain<U>(f: fn(T) -> option<U>) -> option<U> { chain(self, f) }
9696
#[doc = "Returns the contained value or a default"]
97-
fn get_or_default(def: T) -> T { get_or_default(self, def) }
97+
fn get_default(def: T) -> T { get_default(self, def) }
9898
#[doc = "Applies a function to the contained value or returns a default"]
9999
fn map_default<U: copy>(def: U, f: fn(T) -> U) -> U
100100
{ map_default(self, def, f) }

branches/try/src/librustsyntax/parse/eval.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ fn eval_crate_directives_to_mod(cx: ctx, cdirs: [@ast::crate_directive],
2222
-> (ast::_mod, [ast::attribute]) {
2323
#debug("eval crate prefix: %s", prefix);
2424
#debug("eval crate suffix: %s",
25-
option::get_or_default(suffix, "none"));
25+
option::get_default(suffix, "none"));
2626
let (cview_items, citems, cattrs)
2727
= parse_companion_mod(cx, prefix, suffix);
2828
let mut view_items: [@ast::view_item] = [];

branches/try/src/rustc/middle/trans/base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2017,7 +2017,7 @@ fn monomorphic_fn(ccx: @crate_ctxt, fn_id: ast::def_id, real_substs: [ty::t],
20172017
// ctors don't have attrs, at least not right now
20182018
let tp_tys: [ty::t] = ty::ty_params_to_tys(ccx.tcx, tps);
20192019
trans_class_ctor(ccx, pt, ctor.node.dec, ctor.node.body, lldecl,
2020-
option::get_or_default(psubsts,
2020+
option::get_default(psubsts,
20212021
{tys:tp_tys, vtables: none, bounds: @[]}),
20222022
fn_id.node, parent_id, ctor.span);
20232023
}

branches/try/src/rustdoc/attr_pass.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ fn fold_crate(
5050
{
5151
topmod: {
5252
item: {
53-
name: option::get_or_default(attrs.name, doc.topmod.name())
53+
name: option::get_default(attrs.name, doc.topmod.name())
5454
with doc.topmod.item
5555
}
5656
with doc.topmod

branches/try/src/rustdoc/config.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ fn config_from_opts(
125125
let result = result::chain(result) {|config|
126126
let output_dir = getopts::opt_maybe_str(match, opt_output_dir());
127127
result::ok({
128-
output_dir: option::get_or_default(output_dir, config.output_dir)
128+
output_dir: option::get_default(output_dir, config.output_dir)
129129
with config
130130
})
131131
};

0 commit comments

Comments
 (0)