1. 25 8月, 2013 1 次提交
  2. 09 8月, 2013 1 次提交
    • S
      env! syntax extension changes · c3825c83
      Steven Fackler 提交于
      env! aborts compilation of the specified environment variable is not
      defined and takes an optional second argument containing a custom
      error message. option_env! creates an Option<&'static str> containing
      the value of the environment variable.
      
      There are no run-pass tests that check the behavior when the environment
      variable is defined since the test framework doesn't support setting
      environment variables at compile time as opposed to runtime. However,
      both env! and option_env! are used inside of rustc itself, which should
      act as a sufficient test.
      
      Close #2248
      c3825c83
  3. 08 8月, 2013 1 次提交
  4. 07 8月, 2013 2 次提交
  5. 06 8月, 2013 1 次提交
    • M
      Updated std::Option, std::Either and std::Result · 0ac7a219
      Marvin Löbel 提交于
      - Made naming schemes consistent between Option, Result and Either
      - Changed Options Add implementation to work like the maybe monad (return None if any of the inputs is None)
      - Removed duplicate Option::get and renamed all related functions to use the term `unwrap` instead
      0ac7a219
  6. 02 8月, 2013 1 次提交
    • B
      Remove the pipes compiler · 4b3e766a
      Brian Anderson 提交于
      The pipes compiler produced data types that encoded efficient and safe
      bounded message passing protocols between two endpoints. It was also
      capable of producing unbounded protocols.
      
      It was useful research but was arguably done before its proper time.
      
      I am removing it for the following reasons:
      
      * In practice we used it only for producing the `oneshot` and `stream`
        unbounded protocols and all communication in Rust use those.
      * The interface between the proto! macro and the standard library
        has a large surface area and was difficult to maintain through
        language and library changes.
      * It is now written in an old dialect of Rust and generates code
        which would likely be considered non-idiomatic.
      * Both the compiler and the runtime are difficult to understand,
        and likewise the relationship between the generated code and
        the library is hard to understand. Debugging is difficult.
      * The new scheduler implements `stream` and `oneshot` by hand
        in a way that will be significantly easier to maintain.
      
      This shouldn't be taken as an indication that 'channel protocols'
      for Rust are not worth pursuing again in the future.
      4b3e766a
  7. 01 8月, 2013 1 次提交
  8. 29 7月, 2013 1 次提交
  9. 24 7月, 2013 1 次提交
  10. 22 7月, 2013 1 次提交
  11. 19 7月, 2013 2 次提交
    • H
      syntax: modernise attribute handling in syntax::attr. · cc760a64
      Huon Wilson 提交于
      This does a number of things, but especially dramatically reduce the
      number of allocations performed for operations involving attributes/
      meta items:
      
      - Converts ast::meta_item & ast::attribute and other associated enums
        to CamelCase.
      - Converts several standalone functions in syntax::attr into methods,
        defined on two traits AttrMetaMethods & AttributeMethods. The former
        is common to both MetaItem and Attribute since the latter is a thin
        wrapper around the former.
      - Deletes functions that are unnecessary due to iterators.
      - Converts other standalone functions to use iterators and the generic
        AttrMetaMethods rather than allocating a lot of new vectors (e.g. the
        old code would have to allocate a new vector to use functions that
        operated on &[meta_item] on &[attribute].)
      - Moves the core algorithm of the #[cfg] matching to syntax::attr,
        similar to find_inline_attr and find_linkage_metas.
      
      This doesn't have much of an effect on the speed of #[cfg] stripping,
      despite hugely reducing the number of allocations performed; presumably
      most of the time is spent in the ast folder rather than doing attribute
      checks.
      
      Also fixes the Eq instance of MetaItem_ to correctly ignore spaces, so
      that `rustc --cfg 'foo(bar)'` now works.
      cc760a64
    • P
      librustc: Forbid `&` pointers (other than `&'static`) inside `@` boxes. · 9089cf2e
      Patrick Walton 提交于
      This makes custom borrowing implementations for custom smart pointers
      sound.
      9089cf2e
  12. 18 7月, 2013 3 次提交
  13. 13 7月, 2013 1 次提交
  14. 07 7月, 2013 1 次提交
  15. 05 7月, 2013 1 次提交
  16. 29 6月, 2013 1 次提交
  17. 26 6月, 2013 1 次提交
  18. 14 6月, 2013 1 次提交
  19. 13 6月, 2013 1 次提交
    • H
      Use @str instead of @~str in libsyntax and librustc. Fixes #5048. · 096f6f56
      Huon Wilson 提交于
      This almost removes the StringRef wrapper, since all strings are
      Equiv-alent now. Removes a lot of `/* bad */ copy *`'s, and converts
      several things to be &'static str (the lint table and the intrinsics
      table).
      
      There are many instances of .to_managed(), unfortunately.
      096f6f56
  20. 12 6月, 2013 2 次提交
  21. 06 6月, 2013 6 次提交
  22. 02 6月, 2013 1 次提交
  23. 30 5月, 2013 1 次提交
  24. 23 5月, 2013 1 次提交
  25. 21 5月, 2013 3 次提交
  26. 16 5月, 2013 1 次提交
  27. 15 5月, 2013 2 次提交