| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2011 The Android Open Source Project | 2 * Copyright 2011 The Android Open Source Project |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
| 5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
| 6 */ | 6 */ |
| 7 | 7 |
| 8 #ifndef SkFontMgr_android_parser_DEFINED | 8 #ifndef SkFontMgr_android_parser_DEFINED |
| 9 #define SkFontMgr_android_parser_DEFINED | 9 #define SkFontMgr_android_parser_DEFINED |
| 10 | 10 |
| (...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 204 // Check for overflow | 204 // Check for overflow |
| 205 if (n > nMax || (n == nMax && d > dMax)) { | 205 if (n > nMax || (n == nMax && d > dMax)) { |
| 206 return false; | 206 return false; |
| 207 } | 207 } |
| 208 n = (n * 10) + d; | 208 n = (n * 10) + d; |
| 209 } | 209 } |
| 210 if (negate) { | 210 if (negate) { |
| 211 n = -n; | 211 n = -n; |
| 212 frac = -frac; | 212 frac = -frac; |
| 213 } | 213 } |
| 214 *value = (n << N) + frac; | 214 *value = SkLeftShift(n, N) + frac; |
| 215 return true; | 215 return true; |
| 216 } | 216 } |
| 217 | 217 |
| 218 #endif /* SkFontMgr_android_parser_DEFINED */ | 218 #endif /* SkFontMgr_android_parser_DEFINED */ |
| OLD | NEW |