aboutsummaryrefslogtreecommitdiff
path: root/clang/test/CodeGen/Mips/musttail-forward-declaration.c
blob: b25baa76f451fe6ea176f4a29cfa144d252f5cbc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// RUN: %clang_cc1 %s -triple mipsel-unknown-linux-gnu -o /dev/null -emit-llvm -verify

// Test that a forward declaration that is later defined in the same TU
// is allowed for musttail calls.

int func(int i);

int caller(int i) {
  // expected-no-diagnostics
  [[clang::musttail]] return func(i);
}

int func(int i) {
  return i + 1;
}