[email protected] | 25651387 | 2012-01-05 15:41:52 | [diff] [blame] | 1 | /* Copyright (c) 2012 The Chromium Authors. All rights reserved. |
[email protected] | 745b0d4 | 2011-07-16 23:53:22 | [diff] [blame] | 2 | * Use of this source code is governed by a BSD-style license that can be |
| 3 | * found in the LICENSE file. |
| 4 | */ |
| 5 | |
| 6 | /** |
| 7 | * This file provides a definition of C99 sized types |
| 8 | * for Microsoft compilers. These definitions only apply |
| 9 | * for trusted modules. |
| 10 | */ |
| 11 | |
[email protected] | bf5bdff | 2011-07-19 23:25:48 | [diff] [blame] | 12 | label Chrome { |
[email protected] | 5e19e6b | 2011-08-25 23:19:02 | [diff] [blame] | 13 | M13 = 0.0 |
[email protected] | bf5bdff | 2011-07-19 23:25:48 | [diff] [blame] | 14 | }; |
| 15 | |
| 16 | [version=0.0] |
| 17 | describe { |
| 18 | /** Standard Ints. */ |
| 19 | int8_t; |
| 20 | int16_t; |
| 21 | int32_t; |
| 22 | int64_t; |
| 23 | uint8_t; |
| 24 | uint16_t; |
| 25 | uint32_t; |
| 26 | uint64_t; |
| 27 | /** Small and large floats. */ |
| 28 | double_t; |
| 29 | float_t; |
| 30 | |
| 31 | /** Native file handle (int). */ |
| 32 | handle_t; |
| 33 | |
| 34 | /** Interface object (void *). */ |
| 35 | interface_t; |
| 36 | |
| 37 | /** Used for padding, should be (u)int8_t */ |
| 38 | char; |
| 39 | |
| 40 | /** Pointer to memory (void *). */ |
| 41 | mem_t; |
| 42 | |
| 43 | /** Pointer to null terminated string (char *). */ |
| 44 | str_t; |
| 45 | |
[email protected] | 4f932f7 | 2012-06-18 05:17:54 | [diff] [blame] | 46 | /** Pointer to constant null terminated string (const char *). */ |
| 47 | cstr_t; |
| 48 | |
[email protected] | bf5bdff | 2011-07-19 23:25:48 | [diff] [blame] | 49 | /** No return value. */ |
| 50 | void; |
| 51 | }; |
| 52 | |
| 53 | #inline c |
[email protected] | 745b0d4 | 2011-07-16 23:53:22 | [diff] [blame] | 54 | |
| 55 | /** |
| 56 | * |
| 57 | * @addtogroup Typedefs |
| 58 | * @{ |
| 59 | */ |
| 60 | #if defined(_MSC_VER) |
| 61 | |
| 62 | /** This value represents a guaranteed unsigned 8 bit integer. */ |
| 63 | typedef unsigned char uint8_t; |
| 64 | |
| 65 | /** This value represents a guaranteed signed 8 bit integer. */ |
| 66 | typedef signed char int8_t; |
| 67 | |
| 68 | /** This value represents a guaranteed unsigned 16 bit short. */ |
| 69 | typedef unsigned short uint16_t; |
| 70 | |
| 71 | /** This value represents a guaranteed signed 16 bit short. */ |
| 72 | typedef short int16_t; |
| 73 | |
| 74 | /** This value represents a guaranteed unsigned 32 bit integer. */ |
| 75 | typedef unsigned int uint32_t; |
| 76 | |
| 77 | /** This value represents a guaranteed signed 32 bit integer. */ |
| 78 | typedef int int32_t; |
| 79 | |
| 80 | /** This value represents a guaranteed signed 64 bit integer. */ |
| 81 | typedef __int64 int64_t; |
| 82 | |
| 83 | /** This value represents a guaranteed unsigned 64 bit integer. */ |
| 84 | typedef unsigned __int64 uint64_t; |
| 85 | |
| 86 | #else |
| 87 | #include <stdint.h> |
| 88 | #endif |
| 89 | /** |
| 90 | * @} |
| 91 | */ |
| 92 | |
| 93 | #endinl |
| 94 | |