| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 CC_BASE_CONTIGUOUS_CONTAINER_H_ | 5 #ifndef CC_BASE_CONTIGUOUS_CONTAINER_H_ |
| 6 #define CC_BASE_CONTIGUOUS_CONTAINER_H_ | 6 #define CC_BASE_CONTIGUOUS_CONTAINER_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| 11 #include "base/compiler_specific.h" |
| 11 #include "base/logging.h" | 12 #include "base/logging.h" |
| 12 #include "base/macros.h" | 13 #include "base/macros.h" |
| 13 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
| 14 #include "base/stl_util.h" | 15 #include "base/stl_util.h" |
| 15 #include "cc/base/cc_export.h" | 16 #include "cc/base/cc_export.h" |
| 16 | 17 |
| 17 namespace cc { | 18 namespace cc { |
| 18 | 19 |
| 19 // ContiguousContainer is a container which stores a list of heterogeneous | 20 // ContiguousContainer is a container which stores a list of heterogeneous |
| 20 // objects (in particular, of varying sizes), packed next to one another in | 21 // objects (in particular, of varying sizes), packed next to one another in |
| (...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 208 DCHECK_EQ(aligned_size % alignment, 0u); | 209 DCHECK_EQ(aligned_size % alignment, 0u); |
| 209 DCHECK_GE(aligned_size, size); | 210 DCHECK_GE(aligned_size, size); |
| 210 DCHECK_LT(aligned_size, size + alignment); | 211 DCHECK_LT(aligned_size, size + alignment); |
| 211 return aligned_size; | 212 return aligned_size; |
| 212 } | 213 } |
| 213 }; | 214 }; |
| 214 | 215 |
| 215 } // namespace cc | 216 } // namespace cc |
| 216 | 217 |
| 217 #endif // CC_BASE_CONTIGUOUS_CONTAINER_H_ | 218 #endif // CC_BASE_CONTIGUOUS_CONTAINER_H_ |
| OLD | NEW |