mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-29 20:46:07 +03:00
Format paths
This commit is contained in:
@@ -9,3 +9,11 @@ fn weird_comment(/* /*/ double level */ comment */ x: Hello /*/*/* tripple, even
|
||||
) {
|
||||
simple(/* does this preserve comments now? */ 42, NoWay)
|
||||
}
|
||||
|
||||
fn generic<T>(arg: T) -> &SomeType
|
||||
where T: Fn(// First arg
|
||||
A,
|
||||
// Second argument
|
||||
B, C, D, /* pre comment */ E /* last comment */) -> &SomeType {
|
||||
arg(a, b, c, d, e)
|
||||
}
|
||||
|
||||
@@ -0,0 +1,22 @@
|
||||
|
||||
fn main() {
|
||||
// FIXME(#133): the list rewrite should fail and force a different format
|
||||
let constellation_chan = Constellation::<layout::layout_task::LayoutTask, script::script_task::ScriptTask> ::start(
|
||||
compositor_proxy,
|
||||
resource_task,
|
||||
image_cache_task,font_cache_task,
|
||||
time_profiler_chan,
|
||||
mem_profiler_chan,
|
||||
devtools_chan,
|
||||
storage_task,
|
||||
supports_clipboard
|
||||
);
|
||||
|
||||
Quux::<ParamOne, // Comment 1
|
||||
ParamTwo, // Comment 2
|
||||
>::some_func();
|
||||
|
||||
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA::BBBBBBBBBBBBBBBBBBBBBBBBBBBB::CCCCCCCCCCCCCCCCCCCCCC::quux();
|
||||
}
|
||||
|
||||
fn op(foo: Bar, key : &[u8], upd : Fn(Option<&memcache::Item> , Baz ) -> Result) -> MapResult {}
|
||||
@@ -48,3 +48,8 @@ fn matcher() {
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
fn issue177() {
|
||||
struct Foo<T> { memb: T }
|
||||
let foo = Foo::<i64> { memb: 10 };
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user