mirror of
https://github.com/rust-lang/rust.git
synced 2025-01-31 17:12:53 +00:00
Update tests
This commit is contained in:
parent
38c30a3e06
commit
4d11faff4b
@ -112,3 +112,17 @@ impl<
|
||||
> {
|
||||
fn foo() {}
|
||||
}
|
||||
|
||||
// #1689
|
||||
impl<M, S, F, X> SubSelectDirect<M, S, F, X>
|
||||
where
|
||||
M: select::Selector,
|
||||
S: event::Stream,
|
||||
F: for<'t> FnMut(transform::Api<
|
||||
't,
|
||||
Stream<ContentStream<S>>,
|
||||
>)
|
||||
-> transform::Api<'t, X>,
|
||||
X: event::Stream,
|
||||
{
|
||||
}
|
||||
|
@ -28,3 +28,7 @@ pub type Exactly100CharstoEqualWhereTest<T, U, PARAMET> where T: Clone + Ord + E
|
||||
pub type Exactly101CharstoEqualWhereTest<T, U, PARAMETE> where T: Clone + Ord + Eq + SomeOtherTrait = Option<T>;
|
||||
|
||||
type RegisterPlugin = unsafe fn(pt: *const c_char, plugin: *mut c_void, data: *mut CallbackData);
|
||||
|
||||
// #1683
|
||||
pub type Between<Lhs, Rhs> = super::operators::Between<Lhs, super::operators::And<AsExpr<Rhs, Lhs>, AsExpr<Rhs, Lhs>>>;
|
||||
pub type NotBetween<Lhs, Rhs> = super::operators::NotBetween<Lhs, super::operators::And<AsExpr<Rhs, Lhs>, AsExpr<Rhs, Lhs>>>;
|
||||
|
@ -75,3 +75,14 @@ impl<
|
||||
> {
|
||||
fn foo() {}
|
||||
}
|
||||
|
||||
// #1689
|
||||
impl<M, S, F, X> SubSelectDirect<M, S, F, X>
|
||||
where
|
||||
M: select::Selector,
|
||||
S: event::Stream,
|
||||
F: for<'t> FnMut(transform::Api<'t, Stream<ContentStream<S>>>)
|
||||
-> transform::Api<'t, X>,
|
||||
X: event::Stream,
|
||||
{
|
||||
}
|
||||
|
@ -6,10 +6,13 @@ extern {
|
||||
|
||||
extern fn sup() {}
|
||||
|
||||
type funky_func = extern fn(unsafe extern "rust-call" fn(*const JSJitInfo,
|
||||
*mut JSContext,
|
||||
HandleObject,
|
||||
*mut libc::c_void,
|
||||
u32,
|
||||
*mut JSVal)
|
||||
-> u8);
|
||||
type funky_func = extern fn(
|
||||
unsafe extern "rust-call" fn(
|
||||
*const JSJitInfo,
|
||||
*mut JSContext,
|
||||
HandleObject,
|
||||
*mut libc::c_void,
|
||||
u32,
|
||||
*mut JSVal,
|
||||
) -> u8,
|
||||
);
|
||||
|
@ -10,7 +10,7 @@ fn simple(
|
||||
key: &[u8],
|
||||
upd: Box<
|
||||
Fn(Option<&memcache::Item>)
|
||||
-> (memcache::Status, Result<memcache::Item, Option<String>>),
|
||||
-> (memcache::Status, Result<memcache::Item, Option<String>>),
|
||||
>,
|
||||
) -> MapResult {
|
||||
}
|
||||
@ -34,15 +34,16 @@ fn weird_comment(
|
||||
|
||||
fn generic<T>(arg: T) -> &SomeType
|
||||
where
|
||||
T: Fn(// First arg
|
||||
A,
|
||||
// Second argument
|
||||
B,
|
||||
C,
|
||||
D,
|
||||
// pre comment
|
||||
E /* last comment */)
|
||||
-> &SomeType,
|
||||
T: Fn(
|
||||
// First arg
|
||||
A,
|
||||
// Second argument
|
||||
B,
|
||||
C,
|
||||
D,
|
||||
// pre comment
|
||||
E, /* last comment */
|
||||
) -> &SomeType,
|
||||
{
|
||||
arg(a, b, c, d, e)
|
||||
}
|
||||
@ -68,13 +69,14 @@ unsafe fn generic_call(
|
||||
argc: libc::c_uint,
|
||||
vp: *mut JSVal,
|
||||
is_lenient: bool,
|
||||
call: unsafe extern "C" fn(*const JSJitInfo,
|
||||
*mut JSContext,
|
||||
HandleObject,
|
||||
*mut libc::c_void,
|
||||
u32,
|
||||
*mut JSVal)
|
||||
-> u8,
|
||||
call: unsafe extern "C" fn(
|
||||
*const JSJitInfo,
|
||||
*mut JSContext,
|
||||
HandleObject,
|
||||
*mut libc::c_void,
|
||||
u32,
|
||||
*mut JSVal,
|
||||
) -> u8,
|
||||
) {
|
||||
let f: fn(_, _) -> _ = panic!();
|
||||
}
|
||||
|
@ -102,8 +102,7 @@ fn foo(a: i32) -> i32 {
|
||||
fn ______________________baz(
|
||||
a: i32,
|
||||
) -> *mut ::std::option::Option<
|
||||
extern "C" fn(arg1: i32, _____________________a: i32, arg3: i32)
|
||||
-> (),
|
||||
extern "C" fn(arg1: i32, _____________________a: i32, arg3: i32) -> (),
|
||||
> {
|
||||
}
|
||||
|
||||
|
@ -59,15 +59,16 @@ fn main() {
|
||||
|
||||
fn generic<T>(arg: T) -> &SomeType
|
||||
where
|
||||
T: Fn(// First arg
|
||||
A,
|
||||
// Second argument
|
||||
B,
|
||||
C,
|
||||
D,
|
||||
// pre comment
|
||||
E /* last comment */)
|
||||
-> &SomeType,
|
||||
T: Fn(
|
||||
// First arg
|
||||
A,
|
||||
// Second argument
|
||||
B,
|
||||
C,
|
||||
D,
|
||||
// pre comment
|
||||
E, /* last comment */
|
||||
) -> &SomeType,
|
||||
{
|
||||
arg(a, b, c, d, e)
|
||||
}
|
||||
|
@ -13,16 +13,20 @@ fn types() {
|
||||
|
||||
struct F {
|
||||
f: extern "C" fn(x: u8, ... /* comment */),
|
||||
g: extern "C" fn(x: u8,
|
||||
// comment
|
||||
...),
|
||||
g: extern "C" fn(
|
||||
x: u8,
|
||||
// comment
|
||||
...
|
||||
),
|
||||
h: extern "C" fn(x: u8, ...),
|
||||
i: extern "C" fn(x: u8,
|
||||
// comment 4
|
||||
y: String, // comment 3
|
||||
z: Foo,
|
||||
// comment
|
||||
... /* comment 2 */),
|
||||
i: extern "C" fn(
|
||||
x: u8,
|
||||
// comment 4
|
||||
y: String, // comment 3
|
||||
z: Foo,
|
||||
// comment
|
||||
... /* comment 2 */
|
||||
),
|
||||
}
|
||||
|
||||
fn issue_1006(def_id_to_string: for<'a, 'b> unsafe fn(TyCtxt<'b, 'tcx, 'tcx>, DefId) -> String) {}
|
||||
|
@ -26,8 +26,9 @@ pub type LongGenericListTest<
|
||||
|
||||
pub type Exactly100CharsTest<'a, 'b, 'c, 'd, LONGPARAMETERNAME, LONGPARAMETERNAME, A, B> = Vec<i32>;
|
||||
|
||||
pub type Exactly101CharsTest<'a, 'b, 'c, 'd, LONGPARAMETERNAME, LONGPARAMETERNAME, A, B> =
|
||||
Vec<Test>;
|
||||
pub type Exactly101CharsTest<'a, 'b, 'c, 'd, LONGPARAMETERNAME, LONGPARAMETERNAME, A, B> = Vec<
|
||||
Test,
|
||||
>;
|
||||
|
||||
pub type Exactly100CharsToEqualTest<'a, 'b, 'c, 'd, LONGPARAMETERNAME, LONGPARAMETERNAME, A, B, C> =
|
||||
Vec<i32>;
|
||||
@ -61,6 +62,14 @@ pub type Exactly100CharstoEqualWhereTest<T, U, PARAMET> where
|
||||
pub type Exactly101CharstoEqualWhereTest<T, U, PARAMETE> where
|
||||
T: Clone + Ord + Eq + SomeOtherTrait = Option<T>;
|
||||
|
||||
type RegisterPlugin = unsafe fn(pt: *const c_char,
|
||||
plugin: *mut c_void,
|
||||
data: *mut CallbackData);
|
||||
type RegisterPlugin = unsafe fn(pt: *const c_char, plugin: *mut c_void, data: *mut CallbackData);
|
||||
|
||||
// #1683
|
||||
pub type Between<Lhs, Rhs> = super::operators::Between<
|
||||
Lhs,
|
||||
super::operators::And<AsExpr<Rhs, Lhs>, AsExpr<Rhs, Lhs>>,
|
||||
>;
|
||||
pub type NotBetween<Lhs, Rhs> = super::operators::NotBetween<
|
||||
Lhs,
|
||||
super::operators::And<AsExpr<Rhs, Lhs>, AsExpr<Rhs, Lhs>>,
|
||||
>;
|
||||
|
Loading…
Reference in New Issue
Block a user