Skip to content

Commit ce5ec54

Browse files
committed
Add simple test
1 parent 6782bb4 commit ce5ec54

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
include ../tools.mk
2+
3+
PROFILE_DIR=$(TMPDIR)/profiles
4+
5+
all: check_inline check_filter
6+
7+
check_inline:
8+
$(RUSTC) -O main.rs -Cremark=all -Zremark-dir=$(PROFILE_DIR)
9+
cat $(PROFILE_DIR)/*.opt.yaml | $(CGREP) -e "inline"
10+
check_filter:
11+
$(RUSTC) -O main.rs -Cremark=foo -Zremark-dir=$(PROFILE_DIR)
12+
cat $(PROFILE_DIR)/*.opt.yaml | $(CGREP) -e -v "inline"
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#[inline(never)]
2+
fn foo() {}
3+
4+
fn main() {
5+
foo();
6+
}

0 commit comments

Comments
 (0)