Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
M
miniaudio
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
miniaudio
Commits
4ad67a66
Commit
4ad67a66
authored
Sep 18, 2019
by
David Reid
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix potential warnings when compiling with GCC.
parent
662246ce
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
6 deletions
+15
-6
miniaudio.h
miniaudio.h
+15
-6
No files found.
miniaudio.h
View file @
4ad67a66
...
@@ -570,13 +570,22 @@ typedef ma_uint16 wchar_t;
...
@@ -570,13 +570,22 @@ typedef ma_uint16 wchar_t;
#ifdef _MSC_VER
#ifdef _MSC_VER
#define MA_INLINE __forceinline
#define MA_INLINE __forceinline
#else
#elif defined(__GNUC__)
#ifdef __GNUC__
/*
#define MA_INLINE __inline__ __attribute__((always_inline))
I've had a bug report where GCC is emitting warnings about functions possibly not being inlineable. This warning happens when
the __attribute__((always_inline)) attribute is defined without an "inline" statement. I think therefore there must be some
case where "__inline__" is not always defined, thus the compiler emitting these warnings. When using -std=c89 or -ansi on the
command line, we cannot use the "inline" keyword and instead need to use "__inline__". In an attempt to work around this issue
I am using "__inline__" only when we're compiling in strict ANSI mode.
*/
#if defined(__STRICT_ANSI__)
#define MA_INLINE __inline__ __attribute__((always_inline))
#else
#define MA_INLINE inline __attribute__((always_inline))
#endif
#else
#else
#define MA_INLINE
#define MA_INLINE
#endif
#endif
#endif
#if defined(_MSC_VER)
#if defined(_MSC_VER)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment