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

Side by Side Diff: runtime/vm/utils.h

Issue 9189003: Move assert.h/assert.cc from runtime/vm to runtime/platform (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Check for correct rebase Created 8 years, 11 months 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
« no previous file with comments | « runtime/vm/token.h ('k') | runtime/vm/utils_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_UTILS_H_ 5 #ifndef VM_UTILS_H_
6 #define VM_UTILS_H_ 6 #define VM_UTILS_H_
7 7
8 #include "vm/assert.h" 8 #include "platform/assert.h"
9 #include "vm/globals.h"
9 10
10 namespace dart { 11 namespace dart {
11 12
12 class Utils { 13 class Utils {
13 public: 14 public:
14 template<typename T> 15 template<typename T>
15 static inline T Minimum(T x, T y) { 16 static inline T Minimum(T x, T y) {
16 return x < y ? x : y; 17 return x < y ? x : y;
17 } 18 }
18 19
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 static char IntToHexDigit(int i) { 146 static char IntToHexDigit(int i) {
146 ASSERT(0 <= i && i < 16); 147 ASSERT(0 <= i && i < 16);
147 if (i < 10) return static_cast<char>('0' + i); 148 if (i < 10) return static_cast<char>('0' + i);
148 return static_cast<char>('A' + (i - 10)); 149 return static_cast<char>('A' + (i - 10));
149 } 150 }
150 }; 151 };
151 152
152 } // namespace dart 153 } // namespace dart
153 154
154 #endif // VM_UTILS_H_ 155 #endif // VM_UTILS_H_
OLDNEW
« no previous file with comments | « runtime/vm/token.h ('k') | runtime/vm/utils_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698