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

Side by Side Diff: test/cctest/test-api.cc

Issue 2175233003: Replace SmartPointer<T> with unique_ptr<T> (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@smart-array
Patch Set: Created 4 years, 4 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
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 23 matching lines...) Expand all
34 #include "test/cctest/test-api.h" 34 #include "test/cctest/test-api.h"
35 35
36 #if V8_OS_POSIX 36 #if V8_OS_POSIX
37 #include <unistd.h> // NOLINT 37 #include <unistd.h> // NOLINT
38 #endif 38 #endif
39 39
40 #include "include/v8-util.h" 40 #include "include/v8-util.h"
41 #include "src/api.h" 41 #include "src/api.h"
42 #include "src/arguments.h" 42 #include "src/arguments.h"
43 #include "src/base/platform/platform.h" 43 #include "src/base/platform/platform.h"
44 #include "src/base/smart-pointers.h"
45 #include "src/code-stubs.h" 44 #include "src/code-stubs.h"
46 #include "src/compilation-cache.h" 45 #include "src/compilation-cache.h"
47 #include "src/debug/debug.h" 46 #include "src/debug/debug.h"
48 #include "src/execution.h" 47 #include "src/execution.h"
49 #include "src/futex-emulation.h" 48 #include "src/futex-emulation.h"
50 #include "src/objects.h" 49 #include "src/objects.h"
51 #include "src/parsing/parser.h" 50 #include "src/parsing/parser.h"
52 #include "src/profiler/cpu-profiler.h" 51 #include "src/profiler/cpu-profiler.h"
53 #include "src/unicode-inl.h" 52 #include "src/unicode-inl.h"
54 #include "src/utils.h" 53 #include "src/utils.h"
(...skipping 25399 matching lines...) Expand 10 before | Expand all | Expand 10 after
25454 25453
25455 // Put the function into context1 and call it. Since the access check 25454 // Put the function into context1 and call it. Since the access check
25456 // callback always returns true, the call succeeds even though the tokens 25455 // callback always returns true, the call succeeds even though the tokens
25457 // are different. 25456 // are different.
25458 context1->Enter(); 25457 context1->Enter();
25459 context1->Global()->Set(context1, v8_str("fun"), fun).FromJust(); 25458 context1->Global()->Set(context1, v8_str("fun"), fun).FromJust();
25460 v8::Local<v8::Value> x_value = CompileRun("fun('x')"); 25459 v8::Local<v8::Value> x_value = CompileRun("fun('x')");
25461 CHECK_EQ(42, x_value->Int32Value(context1).FromJust()); 25460 CHECK_EQ(42, x_value->Int32Value(context1).FromJust());
25462 context1->Exit(); 25461 context1->Exit();
25463 } 25462 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698