about summary refs log tree commit diff
path: root/tests/ui/consts/promote_fn_calls.rs
blob: 52a421ead70249ac3859a681e8ee66a92001420b (plain)
1
2
3
4
5
6
7
8
9
10
11
//@ build-pass (FIXME(62277): could be check-pass?)
//@ aux-build:promotable_const_fn_lib.rs

extern crate promotable_const_fn_lib;

use promotable_const_fn_lib::{foo, Foo};

fn main() {
    let x: &'static usize = &foo();
    let x: &'static usize = &Foo::foo();
}