1. 25 7月, 2014 20 次提交
    • A
      rustdoc: Bind keydown instead of keypress for nav · 80efb220
      Alex Crichton 提交于
      Apparently keypress doesn't quite work in all browsers due to some not invoking
      the handler and jquery not setting the right `which` field in all circumstances.
      According to http://stackoverflow.com/questions/2166771 switching over to
      `keydown` works and it appears to do the trick. Tested in Safari, Firefox, and
      Chrome.
      
      Closes #15011
      80efb220
    • A
      rustdoc: Hide impls for #[doc(hidden)] traits · 724bcec0
      Alex Crichton 提交于
      Closes #14585
      724bcec0
    • A
      rustdoc: Add a --target flag · 51355478
      Alex Crichton 提交于
      Closes #13893
      51355478
    • B
      auto merge of #15970 : Zoxc/rust/noalias-ref, r=cmr · 44019c79
      bors 提交于
      This add the LLVM noalias attribute to parameters of a
      shared reference type (&) which have a safe interior.
      44019c79
    • B
      auto merge of #15957 : pcwalton/rust/builtin-bound-impl-checking, r=huonw,pnkfelix · 470dbef2
      bors 提交于
      method calls are involved.
      
      This breaks code like:
      
          impl<T:Copy> Foo for T { ... }
      
          fn take_param<T:Foo>(foo: &T) { ... }
      
          fn main() {
              let x = box 3i; // note no `Copy` bound
              take_param(&x);
          }
      
      Change this code to not contain a type error. For example:
      
          impl<T:Copy> Foo for T { ... }
      
          fn take_param<T:Foo>(foo: &T) { ... }
      
          fn main() {
              let x = 3i; // satisfies `Copy` bound
              take_param(&x);
          }
      
      Closes #15860.
      
      [breaking-change]
      
      r? @alexcrichton
      470dbef2
    • P
      librustc: Check built-in trait bounds on implementations when direct · f1520ea0
      Patrick Walton 提交于
      method calls are involved.
      
      This breaks code like:
      
          impl<T:Copy> Foo for T { ... }
      
          fn take_param<T:Foo>(foo: &T) { ... }
      
          fn main() {
              let x = box 3i; // note no `Copy` bound
              take_param(&x);
          }
      
      Change this code to not contain a type error. For example:
      
          impl<T:Copy> Foo for T { ... }
      
          fn take_param<T:Foo>(foo: &T) { ... }
      
          fn main() {
              let x = 3i; // satisfies `Copy` bound
              take_param(&x);
          }
      
      Closes #15860.
      
      [breaking-change]
      f1520ea0
    • B
      auto merge of #15961 : pcwalton/rust/fn-pointer-in-iterator, r=huonw · e5984640
      bors 提交于
      This breaks code like:
      
          struct A<'a> {
              func: &'a fn() -> Option<int>
          }
      
          fn foo() -> Option<int> { ... }
      
          fn create() -> A<'static> {
              A {
                  func: &foo
              }
          }
      
      Change this code to not take functions by reference. For example:
      
          struct A {
              func: extern "Rust" fn() -> Option<int>
          }
      
          fn foo() -> Option<int> { ... }
      
          fn create() -> A {
              A {
                  func: foo
              }
          }
      
      Closes #13595.
      
      [breaking-change]
      
      r? @huonw
      e5984640
    • B
      auto merge of #15959 : omasanori/rust/cleanup-ja, r=alexcrichton · 4e388859
      bors 提交于
      The translation is based on an early version of tutorial.md, thus most
      of entries have been marked as fuzzy and actually they are incorrect.
      Now tutorial.md is planed to be replaced with guide.md, so I'd suggest
      removing translation files for a while.
      
      /cc @gifnksm
      4e388859
    • J
      Add noalias to safe shared reference parameters · 4c2d4cd3
      John Kåre Alsaker 提交于
      This add the LLVM noalias attribute to parameters of a
      shared reference type (&) which have a safe interior.
      4c2d4cd3
    • B
      auto merge of #15809 : pcwalton/rust/dedesugar-for, r=pnkfelix · b9035c26
      bors 提交于
      librustc: Stop desugaring `for` expressions and translate them directly.
      
      This makes edge cases in which the `Iterator` trait was not in scope
      and/or `Option` or its variants were not in scope work properly.
      
      This breaks code that looks like:
      
          struct MyStruct { ... }
      
          impl MyStruct {
              fn next(&mut self) -> Option<int> { ... }
          }
      
          for x in MyStruct { ... } { ... }
      
      Change ad-hoc `next` methods like the above to implementations of the
      `Iterator` trait. For example:
      
          impl Iterator<int> for MyStruct {
              fn next(&mut self) -> Option<int> { ... }
          }
      
      Closes #15392.
      
      [breaking-change]
      b9035c26
    • P
      librustc: Stop desugaring `for` expressions and translate them directly. · caa564be
      Patrick Walton 提交于
      This makes edge cases in which the `Iterator` trait was not in scope
      and/or `Option` or its variants were not in scope work properly.
      
      This breaks code that looks like:
      
          struct MyStruct { ... }
      
          impl MyStruct {
              fn next(&mut self) -> Option<int> { ... }
          }
      
          for x in MyStruct { ... } { ... }
      
      Change ad-hoc `next` methods like the above to implementations of the
      `Iterator` trait. For example:
      
          impl Iterator<int> for MyStruct {
              fn next(&mut self) -> Option<int> { ... }
          }
      
      Closes #15392.
      
      [breaking-change]
      caa564be
    • B
      auto merge of #15951 : edwardw/rust/issue-15896, r=alexcrichton · a4553453
      bors 提交于
      Fix ICE when there's an incorrect enum variant constructor in match arm.
      
      Closes #15896.
      a4553453
    • B
      auto merge of #15945 : treeman/rust/doc-smallint-update, r=alexcrichton · 7f2e63ec
      bors 提交于
      Forgot two methods, but @alexcrichton was a bit too quick to accept  #15943, so I made a new PR.
      7f2e63ec
    • P
      librustc: Make references to functions not have static lifetime. · d1dcd19d
      Patrick Walton 提交于
      This breaks code like:
      
          struct A<'a> {
              func: &'a fn() -> Option<int>
          }
      
          fn foo() -> Option<int> { ... }
      
          fn create() -> A<'static> {
              A {
                  func: &foo
              }
          }
      
      Change this code to not take functions by reference. For example:
      
          struct A {
              func: extern "Rust" fn() -> Option<int>
          }
      
          fn foo() -> Option<int> { ... }
      
          fn create() -> A {
              A {
                  func: foo
              }
          }
      
      Closes #13595.
      
      [breaking-change]
      d1dcd19d
    • O
      Remove obsolete Japanese translation for a while. · 1e2456b9
      OGINO Masanori 提交于
      The translation is based on an early version of tutorial.md, thus most
      of entries have been marked as fuzzy and actually they are incorrect.
      Now tutorial.md is planed to be replaced with guide.md, so I'd suggest
      removing translation files for a while.
      Signed-off-by: NOGINO Masanori <masanori.ogino@gmail.com>
      1e2456b9
    • B
      auto merge of #15779 : alexcrichton/rust/no-nul-terminator, r=pcwalton · d3f66bd5
      bors 提交于
      Apparently the default getFile implementation for a memory buffer in LLVM ends
      up requiring a null terminator at the end of the file. This isn't true a good
      bit of the time apparently on OSX. There have been a number of failed
      nightly/snapshot builds recently with this strange assertion.
      
      This modifies the calls to MemoryBuffer::getFile to explicitly not ask for a
      null terminator.
      d3f66bd5
    • A
      rustllvm: Don't require null terminators in files · b29d106b
      Alex Crichton 提交于
      Apparently the default getFile implementation for a memory buffer in LLVM ends
      up requiring a null terminator at the end of the file. This isn't true a good
      bit of the time apparently on OSX. There have been a number of failed
      nightly/snapshot builds recently with this strange assertion.
      
      This modifies the calls to MemoryBuffer::getFile to explicitly not ask for a
      null terminator.
      b29d106b
    • B
      auto merge of #15424 : TeXitoi/rust/relicense-shootout-threadring, r=brson · c05bb4ec
      bors 提交于
      Everyone agreed.
      
      Related to #14248, close #15328
      
      @brson OK?
      c05bb4ec
    • E
      Fix #15896 · c3f4c6d4
      Edward Wang 提交于
      Fix ICE when there's an incorrect enum variant constructor in match arm.
      
      Closes #15896.
      c3f4c6d4
    • B
      4461f03a
  2. 24 7月, 2014 20 次提交