History

Use 'inline' instead of 'inline_t' in the processing lib

Just use the standard inline keyword with sufficient backwards compatibility defines, similar to how it is done in the main decoder and encoder libraries.

Martin Storsjö committed 12 years ago

Commit 98dd2d91 parent cbe650a3 files · +7 −9Browse files

Showing the changes to codec/processing (3 of 3 files). Show all

Unified · Split

3 files
  1. codec/processing/src/common/memory.h +3 −3
  2. codec/processing/src/common/typedef.h +3 −5
  3. codec/processing/src/common/util.h +1 −1
codec/processing/src/common/memory.h+3−3
@@ -47,15 +47,15 @@ · 46 unmodified lines
4747
4848 WELSVP_NAMESPACE_BEGIN
4949
50−inline_t void* WelsMemset (void* pPointer, int32_t iValue, uint32_t uiSize) {
50+inline void* WelsMemset (void* pPointer, int32_t iValue, uint32_t uiSize) {
5151 return ::memset (pPointer, iValue, uiSize);
5252 }
5353
54−inline_t void* WelsMemcpy (void* pDst, const void* kpSrc, uint32_t uiSize) {
54+inline void* WelsMemcpy (void* pDst, const void* kpSrc, uint32_t uiSize) {
5555 return ::memcpy (pDst, kpSrc, uiSize);
5656 }
5757
58−inline_t int32_t WelsMemcmp (const void* kpBuf1, const void* kpBuf2, uint32_t uiSize) {
58+inline int32_t WelsMemcmp (const void* kpBuf1, const void* kpBuf2, uint32_t uiSize) {
5959 return ::memcmp (kpBuf1, kpBuf2, uiSize);
6060 }
6161
codec/processing/src/common/typedef.h+3−5
@@ -68,11 +68,9 @@ typedef int int32_t ; · 67 unmodified lines
6868 typedef unsigned int uint32_t ;
6969 typedef __int64 int64_t ;
7070 typedef unsigned __int64 uint64_t ;
71−#define inline_t _inline
72−
73−#else // GCC
74−
75−#define inline_t inline
71+#if _MSC_VER < 1700
72+#define inline __inline
73+#endif
7674
7775 #endif
7876
codec/processing/src/common/util.h+1−1
@@ -84,7 +84,7 @@ WELSVP_NAMESPACE_BEGIN · 83 unmodified lines
8484 #define GET_METHOD(x) ((x) & 0xff) // mask method as the lowest 8bits
8585 #define GET_SPECIAL(x) (((x) >> 8) & 0xff) // mask special flag as 8bits
8686
87−inline_t EMethods WelsVpGetValidMethod (int32_t a) {
87+inline EMethods WelsVpGetValidMethod (int32_t a) {
8888 int32_t iMethod = GET_METHOD (a);
8989 return WelsStaticCast (EMethods, WELS_CLAMP (iMethod, METHOD_NULL + 1, METHOD_MASK - 1));
9090 }

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t