OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 the V8 project 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 // TODO(mythria): Remove this define after this flag is turned on globally | 5 // TODO(mythria): Remove this define after this flag is turned on globally |
6 #define V8_IMMINENT_DEPRECATION_WARNINGS | 6 #define V8_IMMINENT_DEPRECATION_WARNINGS |
7 | 7 |
8 #include <stdlib.h> | 8 #include <stdlib.h> |
9 | 9 |
10 #include "src/v8.h" | 10 #include "src/v8.h" |
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
215 } | 215 } |
216 } | 216 } |
217 // return { geometricMean: geometricMean }; | 217 // return { geometricMean: geometricMean }; |
218 CHECK_EXPR(ObjectLiteral, expected_type) { | 218 CHECK_EXPR(ObjectLiteral, expected_type) { |
219 CHECK_VAR(geometricMean, expected_type); | 219 CHECK_VAR(geometricMean, expected_type); |
220 } | 220 } |
221 } | 221 } |
222 } | 222 } |
223 CHECK_TYPES_END | 223 CHECK_TYPES_END |
224 } | 224 } |
225 } | 225 |
| 226 } // namespace |
226 | 227 |
227 | 228 |
228 TEST(ResetTypingInfo) { | 229 TEST(ResetTypingInfo) { |
229 const char test_function[] = | 230 const char test_function[] = |
230 "function GeometricMean(stdlib, foreign, buffer) {\n" | 231 "function GeometricMean(stdlib, foreign, buffer) {\n" |
231 " \"use asm\";\n" | 232 " \"use asm\";\n" |
232 "\n" | 233 "\n" |
233 " var exp = stdlib.Math.exp;\n" | 234 " var exp = stdlib.Math.exp;\n" |
234 " var log = stdlib.Math.log;\n" | 235 " var log = stdlib.Math.log;\n" |
235 " var values = new stdlib.Float64Array(buffer);\n" | 236 " var values = new stdlib.Float64Array(buffer);\n" |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
292 TypeSetter(isolate, handles.main_zone(), root).Run(); | 293 TypeSetter(isolate, handles.main_zone(), root).Run(); |
293 | 294 |
294 ExpressionTypeCollector(isolate, handles.main_zone(), root, &types).Run(); | 295 ExpressionTypeCollector(isolate, handles.main_zone(), root, &types).Run(); |
295 CheckAllSame(types, INT32_TYPE); | 296 CheckAllSame(types, INT32_TYPE); |
296 | 297 |
297 TypingReseter(isolate, handles.main_zone(), root).Run(); | 298 TypingReseter(isolate, handles.main_zone(), root).Run(); |
298 | 299 |
299 ExpressionTypeCollector(isolate, handles.main_zone(), root, &types).Run(); | 300 ExpressionTypeCollector(isolate, handles.main_zone(), root, &types).Run(); |
300 CheckAllSame(types, Bounds::Unbounded()); | 301 CheckAllSame(types, Bounds::Unbounded()); |
301 } | 302 } |
OLD | NEW |