Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 55 #error Define either WEBRTC_ARCH_LITTLE_ENDIAN or WEBRTC_ARCH_BIG_ENDIAN | 55 #error Define either WEBRTC_ARCH_LITTLE_ENDIAN or WEBRTC_ARCH_BIG_ENDIAN |
| 56 #endif | 56 #endif |
| 57 | 57 |
| 58 // TODO(zhongwei.yao): WEBRTC_CPU_DETECTION is only used in one place; we should | 58 // TODO(zhongwei.yao): WEBRTC_CPU_DETECTION is only used in one place; we should |
| 59 // probably just remove it. | 59 // probably just remove it. |
| 60 #if (defined(WEBRTC_ARCH_X86_FAMILY) && !defined(__SSE2__)) || \ | 60 #if (defined(WEBRTC_ARCH_X86_FAMILY) && !defined(__SSE2__)) || \ |
| 61 defined(WEBRTC_DETECT_NEON) | 61 defined(WEBRTC_DETECT_NEON) |
| 62 #define WEBRTC_CPU_DETECTION | 62 #define WEBRTC_CPU_DETECTION |
| 63 #endif | 63 #endif |
| 64 | 64 |
| 65 #if !defined(_MSC_VER) | 65 // TODO(pbos): Use stdint.h directly from headers requiring _t int types. |
|
Henrik Grunell WebRTC
2015/09/22 10:35:54
Actually, I think it's fine including it implicitl
pbos-webrtc
2015/09/22 12:17:42
Updated TODO.
| |
| 66 #include <stdint.h> | 66 #include <stdint.h> |
| 67 #else | |
| 68 // Define C99 equivalent types, since pre-2010 MSVC doesn't provide stdint.h. | |
| 69 typedef signed char int8_t; | |
| 70 typedef signed short int16_t; | |
| 71 typedef signed int int32_t; | |
| 72 typedef __int64 int64_t; | |
| 73 typedef unsigned char uint8_t; | |
| 74 typedef unsigned short uint16_t; | |
| 75 typedef unsigned int uint32_t; | |
| 76 typedef unsigned __int64 uint64_t; | |
| 77 #endif | |
| 78 | 67 |
| 79 // Annotate a function indicating the caller must examine the return value. | 68 // Annotate a function indicating the caller must examine the return value. |
| 80 // Use like: | 69 // Use like: |
| 81 // int foo() WARN_UNUSED_RESULT; | 70 // int foo() WARN_UNUSED_RESULT; |
| 82 // TODO(ajm): Hack to avoid multiple definitions until the base/ of webrtc and | 71 // TODO(ajm): Hack to avoid multiple definitions until the base/ of webrtc and |
| 83 // libjingle are merged. | 72 // libjingle are merged. |
| 84 #if !defined(WARN_UNUSED_RESULT) | 73 #if !defined(WARN_UNUSED_RESULT) |
| 85 #if defined(__GNUC__) | 74 #if defined(__GNUC__) |
| 86 #define WARN_UNUSED_RESULT __attribute__((warn_unused_result)) | 75 #define WARN_UNUSED_RESULT __attribute__((warn_unused_result)) |
| 87 #else | 76 #else |
| (...skipping 25 matching lines...) Expand all Loading... | |
| 113 // Annotate a function that will not return control flow to the caller. | 102 // Annotate a function that will not return control flow to the caller. |
| 114 #if defined(_MSC_VER) | 103 #if defined(_MSC_VER) |
| 115 #define NO_RETURN __declspec(noreturn) | 104 #define NO_RETURN __declspec(noreturn) |
| 116 #elif defined(__GNUC__) | 105 #elif defined(__GNUC__) |
| 117 #define NO_RETURN __attribute__((noreturn)) | 106 #define NO_RETURN __attribute__((noreturn)) |
| 118 #else | 107 #else |
| 119 #define NO_RETURN | 108 #define NO_RETURN |
| 120 #endif | 109 #endif |
| 121 | 110 |
| 122 #endif // WEBRTC_TYPEDEFS_H_ | 111 #endif // WEBRTC_TYPEDEFS_H_ |
| OLD | NEW |