Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(978)

Side by Side Diff: ppapi/c/pp_bool.h

Issue 5674004: Add compile assertions to enforce the sizes of all structs and enums in the C... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef PPAPI_C_PP_BOOL_H_ 5 #ifndef PPAPI_C_PP_BOOL_H_
6 #define PPAPI_C_PP_BOOL_H_ 6 #define PPAPI_C_PP_BOOL_H_
7 7
8 #include "ppapi/c/pp_macros.h" 8 #include "ppapi/c/pp_macros.h"
9 9
10 /** 10 /**
11 * @file 11 * @file
12 * Defines the API ... 12 * Defines the API ...
13 * 13 *
14 * @addtogroup PP 14 * @addtogroup PP
15 * @{ 15 * @{
16 */ 16 */
17 17
18 /** 18 /**
19 * A boolean value for use in PPAPI C headers. The standard bool type is not 19 * A boolean value for use in PPAPI C headers. The standard bool type is not
20 * available to pre-C99 compilers, and is not guaranteed to be compatible 20 * available to pre-C99 compilers, and is not guaranteed to be compatible
21 * between C and C++, whereas the PPAPI C headers can be included from C or C++ 21 * between C and C++, whereas the PPAPI C headers can be included from C or C++
22 * code. 22 * code.
23 */ 23 */
24 typedef enum { 24 typedef enum {
25 PP_FALSE = 0, 25 PP_FALSE = 0,
26 PP_TRUE = 1 26 PP_TRUE = 1
27 } PP_Bool; 27 } PP_Bool;
28
29 PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_Bool, 4); 28 PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_Bool, 4);
30 29
31 /** 30 /**
32 * @} 31 * @}
33 * End addtogroup PP 32 * End addtogroup PP
34 */ 33 */
35 34
36 #endif // PPAPI_C_PP_BOOL_H_ 35 #endif // PPAPI_C_PP_BOOL_H_
37 36
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698