- 29 12月, 2013 1 次提交
-
-
由 Steven Fackler 提交于
-
- 12 12月, 2013 1 次提交
-
-
由 Erik Price 提交于
Also remove all instances of 'self within the codebase. This fixes #10889.
-
- 08 12月, 2013 1 次提交
-
-
由 Kiet Tran 提交于
-
- 29 11月, 2013 1 次提交
-
-
由 Alex Crichton 提交于
-
- 27 11月, 2013 1 次提交
-
-
由 Steven Fackler 提交于
Closes #4375
-
- 26 11月, 2013 1 次提交
-
-
由 klutzy 提交于
This also moves `#[auto_{en,de}code]` checker from syntax to lint.
-
- 20 11月, 2013 1 次提交
-
-
由 Patrick Walton 提交于
-
- 01 11月, 2013 1 次提交
-
-
由 Alex Crichton 提交于
This extension can be used to concatenate string literals at compile time. C has this useful ability when placing string literals lexically next to one another, but this needs to be handled at the syntax extension level to recursively expand macros. The major use case for this is something like: macro_rules! mylog( ($fmt:expr $($arg:tt)*) => { error2!(concat!(file!(), ":", line!(), " - ", $fmt) $($arg)*); }) Where the mylog macro will automatically prepend the filename/line number to the beginning of every log message.
-
- 22 10月, 2013 1 次提交
-
-
由 Alex Crichton 提交于
Who doesn't like a massive renaming?
-
- 19 10月, 2013 1 次提交
-
-
由 Alex Crichton 提交于
It lived a good life, but its time has come. The groundwork is set for the official transition after the next snapshot (removal of XXX2 macros)
-
- 09 10月, 2013 1 次提交
-
-
由 Daniel Micay 提交于
-
- 08 10月, 2013 2 次提交
-
-
由 Benjamin Herr 提交于
For the benefit of the pretty printer we want to keep track of how string literals in the ast were originally represented in the source code. This commit changes parser functions so they don't extract strings from the token stream without at least also returning what style of string literal it was. This is stored in the resulting ast node for string literals, obviously, for the package id in `extern mod = r"package id"` view items, for the inline asm in `asm!()` invocations. For `asm!()`'s other arguments or for `extern "Rust" fn()` items, I just the style of string, because it seemed disproportionally cumbersome to thread that information through the string processing that happens with those string literals, given the limited advantage raw string literals would provide in these positions. The other syntax extensions don't seem to store passed string literals in the ast, so they also discard the style of strings they parse.
-
由 Benjamin Herr 提交于
Treat it as a synonym for LIT_STR for now.
-
- 01 10月, 2013 2 次提交
-
-
由 Alex Crichton 提交于
-
由 Alex Crichton 提交于
We're not outright removing fmt! just yet, but this prevents it from leaking into the compiler further (it's still turned on by default for all other code).
-
- 24 9月, 2013 2 次提交
-
-
由 Patrick Walton 提交于
-
由 Patrick Walton 提交于
-
- 15 9月, 2013 1 次提交
-
-
由 Alex Crichton 提交于
This renames the syntax-extension file to format from ifmt, and it also reduces the amount of complexity inside by defining all other macros in terms of format_args!
-
- 12 9月, 2013 1 次提交
-
-
由 Alex Crichton 提交于
The purpose of this macro is to further reduce the number of allocations which occur when dealing with formatting strings. This macro will perform all of the static analysis necessary to validate that a format string is safe, and then it will wrap up the "format string" into an opaque struct which can then be passed around. Two safe functions are added (write/format) which take this opaque argument structure, unwrap it, and then call the unsafe version of write/format (in an unsafe block). Other than these two functions, it is not intended for anyone to ever look inside this opaque struct. The macro looks a bit odd, but mostly because of rvalue lifetimes this is the only way for it to be safe that I know of. Example use-cases of this are: * third-party libraries can use the default formatting syntax without any forced allocations * the fail!() macro can avoid allocating the format string * the logging macros can avoid allocation any strings
-
- 10 9月, 2013 1 次提交
-
-
由 Niko Matsakis 提交于
has a unique id. Fixes numerous bugs in macro expansion and deriving. Add two representative tests. Fixes #7971 Fixes #6304 Fixes #8367 Fixes #8754 Fixes #8852 Fixes #2543 Fixes #7654
-
- 07 9月, 2013 6 次提交
-
-
由 John Clements 提交于
This is actually almost a problem, because those were my poster-child macros for "here's how to implement a capturing macro." Following this change, there will be no macros that use capturing; this will probably make life unpleasant for the first person that wants to implement a capturing macro. I should probably create a dummy_capturing macro, just to show how it works.
-
由 John Clements 提交于
-
由 John Clements 提交于
-
由 John Clements 提交于
-
由 John Clements 提交于
-
由 John Clements 提交于
-
- 03 9月, 2013 1 次提交
-
-
由 Marvin Löbel 提交于
-
- 02 9月, 2013 1 次提交
-
-
由 Marvin Löbel 提交于
-
- 01 9月, 2013 1 次提交
-
-
由 Marvin Löbel 提交于
-
- 28 8月, 2013 1 次提交
-
-
由 Patrick Walton 提交于
For example, `foo::<T>::bar::<U>`. This doesn't enforce that the type parameters are in the right positions, however.
-
- 25 8月, 2013 2 次提交
-
-
由 Alex Crichton 提交于
-
由 Alex Crichton 提交于
-
- 09 8月, 2013 1 次提交
-
-
由 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
-
- 08 8月, 2013 1 次提交
-
-
由 Alex Crichton 提交于
The new macro is available under the name ifmt! (only an intermediate name)
-
- 07 8月, 2013 2 次提交
-
-
由 Erick Tryzelaar 提交于
-
由 Michael Woerister 提交于
-
- 06 8月, 2013 1 次提交
-
-
由 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
-
- 02 8月, 2013 1 次提交
-
-
由 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.
-
- 01 8月, 2013 1 次提交
-
-
由 Huon Wilson 提交于
Example: if cfg!(test) { calculation_to_run_only_when_testing(); }
-
- 29 7月, 2013 1 次提交
-
-
由 Michael Woerister 提交于
New naming convention for ast::{node_id, local_crate, crate_node_id, blk_check_mode, ty_field, ty_method}
-