diff options
| author | Graydon Hoare <graydon@mozilla.com> | 2013-06-18 14:45:18 -0700 |
|---|---|---|
| committer | Graydon Hoare <graydon@mozilla.com> | 2013-06-18 14:48:48 -0700 |
| commit | d904c72af830bd4bec773ce35897703dff2ee3b1 (patch) | |
| tree | c9253d1282f12af3aac7e854cd1115cd2eede863 /src/libsyntax | |
| parent | 303d7bfc87ca370354ac4264cc23a80cbcd8a792 (diff) | |
| download | rust-d904c72af830bd4bec773ce35897703dff2ee3b1.tar.gz rust-d904c72af830bd4bec773ce35897703dff2ee3b1.zip | |
replace #[inline(always)] with #[inline]. r=burningtree.
Diffstat (limited to 'src/libsyntax')
| -rw-r--r-- | src/libsyntax/ast.rs | 2 | ||||
| -rw-r--r-- | src/libsyntax/ast_util.rs | 2 | ||||
| -rw-r--r-- | src/libsyntax/attr.rs | 2 | ||||
| -rw-r--r-- | src/libsyntax/ext/deriving/generic.rs | 10 | ||||
| -rw-r--r-- | src/libsyntax/opt_vec.rs | 26 | ||||
| -rw-r--r-- | src/libsyntax/parse/obsolete.rs | 2 |
6 files changed, 22 insertions, 22 deletions
diff --git a/src/libsyntax/ast.rs b/src/libsyntax/ast.rs index e3182916723..1758433aa73 100644 --- a/src/libsyntax/ast.rs +++ b/src/libsyntax/ast.rs @@ -95,7 +95,7 @@ impl<D:Decoder> Decodable<D> for ident { } impl to_bytes::IterBytes for ident { - #[inline(always)] + #[inline] fn iter_bytes(&self, lsb0: bool, f: to_bytes::Cb) -> bool { self.name.iter_bytes(lsb0, f) } diff --git a/src/libsyntax/ast_util.rs b/src/libsyntax/ast_util.rs index 07913946578..a4ded8fea8c 100644 --- a/src/libsyntax/ast_util.rs +++ b/src/libsyntax/ast_util.rs @@ -198,7 +198,7 @@ pub fn is_call_expr(e: @expr) -> bool { // This makes def_id hashable impl to_bytes::IterBytes for def_id { - #[inline(always)] + #[inline] fn iter_bytes(&self, lsb0: bool, f: to_bytes::Cb) -> bool { self.crate.iter_bytes(lsb0, f) && self.node.iter_bytes(lsb0, f) } diff --git a/src/libsyntax/attr.rs b/src/libsyntax/attr.rs index a184d959390..e096711262f 100644 --- a/src/libsyntax/attr.rs +++ b/src/libsyntax/attr.rs @@ -312,7 +312,7 @@ pub enum inline_attr { /// True if something like #[inline] is found in the list of attrs. pub fn find_inline_attr(attrs: &[ast::attribute]) -> inline_attr { - // FIXME (#2809)---validate the usage of #[inline] and #[inline(always)] + // FIXME (#2809)---validate the usage of #[inline] and #[inline] do attrs.iter().fold(ia_none) |ia,attr| { match attr.node.value.node { ast::meta_word(s) if "inline" == s => ia_hint, diff --git a/src/libsyntax/ext/deriving/generic.rs b/src/libsyntax/ext/deriving/generic.rs index 49b3d3ec861..22ce305b857 100644 --- a/src/libsyntax/ext/deriving/generic.rs +++ b/src/libsyntax/ext/deriving/generic.rs @@ -1052,7 +1052,7 @@ f(cx, span, ~[self_1.method(__arg_1_1, __arg_2_1), self_2.method(__arg_1_2, __arg_2_2)]) ~~~ */ -#[inline(always)] +#[inline] pub fn cs_same_method(f: &fn(@ExtCtxt, span, ~[@expr]) -> @expr, enum_nonmatch_f: EnumNonMatchFunc, cx: @ExtCtxt, span: span, @@ -1083,7 +1083,7 @@ Fold together the results of calling the derived method on all the fields. `use_foldl` controls whether this is done left-to-right (`true`) or right-to-left (`false`). */ -#[inline(always)] +#[inline] pub fn cs_same_method_fold(use_foldl: bool, f: &fn(@ExtCtxt, span, @expr, @expr) -> @expr, base: @expr, @@ -1111,7 +1111,7 @@ pub fn cs_same_method_fold(use_foldl: bool, Use a given binop to combine the result of calling the derived method on all the fields. */ -#[inline(always)] +#[inline] pub fn cs_binop(binop: ast::binop, base: @expr, enum_nonmatch_f: EnumNonMatchFunc, cx: @ExtCtxt, span: span, @@ -1130,7 +1130,7 @@ pub fn cs_binop(binop: ast::binop, base: @expr, } /// cs_binop with binop == or -#[inline(always)] +#[inline] pub fn cs_or(enum_nonmatch_f: EnumNonMatchFunc, cx: @ExtCtxt, span: span, substructure: &Substructure) -> @expr { @@ -1139,7 +1139,7 @@ pub fn cs_or(enum_nonmatch_f: EnumNonMatchFunc, cx, span, substructure) } /// cs_binop with binop == and -#[inline(always)] +#[inline] pub fn cs_and(enum_nonmatch_f: EnumNonMatchFunc, cx: @ExtCtxt, span: span, substructure: &Substructure) -> @expr { diff --git a/src/libsyntax/opt_vec.rs b/src/libsyntax/opt_vec.rs index 67e712f0596..81f540fd69f 100644 --- a/src/libsyntax/opt_vec.rs +++ b/src/libsyntax/opt_vec.rs @@ -103,7 +103,7 @@ impl<T:Copy> OptVec<T> { } } - #[inline(always)] + #[inline] fn mapi_to_vec<B>(&self, op: &fn(uint, &T) -> B) -> ~[B] { let mut index = 0; old_iter::map_to_vec(self, |a| { @@ -145,31 +145,31 @@ impl<A> BaseIter<A> for OptVec<A> { } impl<A> old_iter::ExtendedIter<A> for OptVec<A> { - #[inline(always)] + #[inline] fn eachi(&self, blk: &fn(v: uint, v: &A) -> bool) -> bool { old_iter::eachi(self, blk) } - #[inline(always)] + #[inline] fn all(&self, blk: &fn(&A) -> bool) -> bool { old_iter::all(self, blk) } - #[inline(always)] + #[inline] fn any(&self, blk: &fn(&A) -> bool) -> bool { old_iter::any(self, blk) } - #[inline(always)] + #[inline] fn foldl<B>(&self, b0: B, blk: &fn(&B, &A) -> B) -> B { old_iter::foldl(self, b0, blk) } - #[inline(always)] + #[inline] fn position(&self, f: &fn(&A) -> bool) -> Option<uint> { old_iter::position(self, f) } - #[inline(always)] + #[inline] fn map_to_vec<B>(&self, op: &fn(&A) -> B) -> ~[B] { old_iter::map_to_vec(self, op) } - #[inline(always)] + #[inline] fn flat_map_to_vec<B,IB:BaseIter<B>>(&self, op: &fn(&A) -> IB) -> ~[B] { old_iter::flat_map_to_vec(self, op) @@ -178,20 +178,20 @@ impl<A> old_iter::ExtendedIter<A> for OptVec<A> { } impl<A: Eq> old_iter::EqIter<A> for OptVec<A> { - #[inline(always)] + #[inline] fn contains(&self, x: &A) -> bool { old_iter::contains(self, x) } - #[inline(always)] + #[inline] fn count(&self, x: &A) -> uint { old_iter::count(self, x) } } impl<A: Copy> old_iter::CopyableIter<A> for OptVec<A> { - #[inline(always)] + #[inline] fn filter_to_vec(&self, pred: &fn(&A) -> bool) -> ~[A] { old_iter::filter_to_vec(self, pred) } - #[inline(always)] + #[inline] fn to_vec(&self) -> ~[A] { old_iter::to_vec(self) } - #[inline(always)] + #[inline] fn find(&self, f: &fn(&A) -> bool) -> Option<A> { old_iter::find(self, f) } diff --git a/src/libsyntax/parse/obsolete.rs b/src/libsyntax/parse/obsolete.rs index cc7b7fab07e..bb315bf2933 100644 --- a/src/libsyntax/parse/obsolete.rs +++ b/src/libsyntax/parse/obsolete.rs @@ -68,7 +68,7 @@ pub enum ObsoleteSyntax { } impl to_bytes::IterBytes for ObsoleteSyntax { - #[inline(always)] + #[inline] fn iter_bytes(&self, lsb0: bool, f: to_bytes::Cb) -> bool { (*self as uint).iter_bytes(lsb0, f) } |
