Skip to content

Commit c41ff72

Browse files
committed
builtin: fix v -skip-unused -cc tcc examples/hello_world.v on *BSD
1 parent 3009373 commit c41ff72

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

vlib/builtin/backtraces_nix.c.v

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ pub fn print_backtrace_skipping_top_frames(xskipframes int) bool {
1919

2020
// the functions below are not called outside this file,
2121
// so there is no need to have their twins in builtin_windows.v
22+
@[direct_array_access]
2223
fn print_backtrace_skipping_top_frames_bsd(skipframes int) bool {
2324
$if no_backtrace ? {
2425
return false
@@ -37,6 +38,7 @@ fn print_backtrace_skipping_top_frames_bsd(skipframes int) bool {
3738
}
3839

3940
fn C.tcc_backtrace(fmt &char) int
41+
@[direct_array_access]
4042
fn print_backtrace_skipping_top_frames_linux(skipframes int) bool {
4143
$if android {
4244
eprintln('On Android no backtrace is available.')

0 commit comments

Comments
 (0)