22 lines · cpp
1//===-- Implementation of strsignal2//----------------------------------------===//3//4// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.5// See https://llvm.org/LICENSE.txt for license information.6// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception7//8//===----------------------------------------------------------------------===//9 10#include "src/string/strsignal.h"11#include "src/__support/StringUtil/signal_to_string.h"12#include "src/__support/common.h"13#include "src/__support/macros/config.h"14 15namespace LIBC_NAMESPACE_DECL {16 17LLVM_LIBC_FUNCTION(char *, strsignal, (int sig_num)) {18 return const_cast<char *>(get_signal_string(sig_num).data());19}20 21} // namespace LIBC_NAMESPACE_DECL22