summary refs log tree commit diff
path: root/src/test/incremental/issue-49482.rs
blob: 65e86e868bbf97a36e714b7e8413f18b0028747b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
// Copyright 2018 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.

// aux-build:issue_49482_macro_def.rs
// aux-build:issue_49482_reexport.rs
// revisions: rpass1

extern crate issue_49482_reexport;

pub trait KvStorage
{
    fn get(&self);
}

impl<K> KvStorage for Box<K>
where
    K: KvStorage + ?Sized,
{
    fn get(&self) {
        (**self).get()
    }
}

impl KvStorage for u32 {
    fn get(&self) {}
}

fn main() {
    /* force issue_49482_reexport to be loaded */
    issue_49482_reexport::foo();

    Box::new(2).get();
}