Skip to content

Commit

Permalink
fix: make MANUAL_INLINE a bit more portable
Browse files Browse the repository at this point in the history
  • Loading branch information
TheSlowGrowth committed Sep 4, 2024
1 parent 65f13f4 commit a8e19ff
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 3 deletions.
6 changes: 5 additions & 1 deletion dsp/src/dsp/DspHelpers.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@
#pragma once

#ifndef MANUAL_INLINE
# define MANUAL_INLINE inline __attribute__((always_inline))
# ifdef _MSC_VER
# define MANUAL_INLINE __forceinline
# else
# define MANUAL_INLINE inline __attribute__((always_inline))
# endif
#endif

#include <gcem.hpp>
Expand Down
6 changes: 5 additions & 1 deletion dsp/src/dsp/Player.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,11 @@
#include "AudioBuffer.h"

#ifndef MANUAL_INLINE
# define MANUAL_INLINE inline __attribute__((always_inline))
# ifdef _MSC_VER
# define MANUAL_INLINE __forceinline
# else
# define MANUAL_INLINE inline __attribute__((always_inline))
# endif
#endif

enum class Direction
Expand Down
6 changes: 5 additions & 1 deletion dsp/src/dsp/TapeProcessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,11 @@
#include "TapeSaturator.h"

#ifndef MANUAL_INLINE
# define MANUAL_INLINE inline __attribute__((always_inline))
# ifdef _MSC_VER
# define MANUAL_INLINE __forceinline
# else
# define MANUAL_INLINE inline __attribute__((always_inline))
# endif
#endif

struct TapeProcessorParameters
Expand Down

0 comments on commit a8e19ff

Please sign in to comment.