Put noinline macro in header

This commit is contained in:
Jeremy 2023-11-15 15:22:59 -05:00
parent 520962162c
commit 61d536bc02
No known key found for this signature in database
GPG Key ID: BE03111EB7ED6E2E
2 changed files with 6 additions and 6 deletions

View File

@ -21,6 +21,12 @@
#endif
#endif
#ifdef _MSC_VER
#define CPPTRACE_FORCE_NO_INLINE __declspec(noinline)
#else
#define CPPTRACE_FORCE_NO_INLINE __attribute__((noinline))
#endif
namespace cpptrace {
struct object_trace;
struct stacktrace;

View File

@ -1,12 +1,6 @@
#ifndef COMMON_HPP
#define COMMON_HPP
#ifdef _MSC_VER
#define CPPTRACE_FORCE_NO_INLINE __declspec(noinline)
#else
#define CPPTRACE_FORCE_NO_INLINE __attribute__((noinline))
#endif
#define IS_WINDOWS 0
#define IS_LINUX 0
#define IS_APPLE 0