Skip to content

Commit d207bc3

Browse files
nikomatsakisbrson
authored andcommitted
it is also legal to call unsafe functions from other unsafe functions
1 parent 046ca82 commit d207bc3

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
// -*- rust -*-
2+
//
3+
// See also: compile-fail/unsafe-fn-called-from-safe.rs
4+
5+
unsafe fn f() { ret; }
6+
7+
unsafe fn g() {
8+
f();
9+
}
10+

0 commit comments

Comments
 (0)