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

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

Issue 7830: Fix style issues. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 12 years, 2 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 | « src/top.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2007-2008 the V8 project authors. All rights reserved. 1 // Copyright 2007-2008 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 3255 matching lines...) Expand 10 before | Expand all | Expand 10 after
3266 CHECK(get_prop->IsFunction()); 3266 CHECK(get_prop->IsFunction());
3267 v8::TryCatch try_catch; 3267 v8::TryCatch try_catch;
3268 Local<Value> r = Function::Cast(*get_prop)->Call(global1, 0, NULL); 3268 Local<Value> r = Function::Cast(*get_prop)->Call(global1, 0, NULL);
3269 CHECK(!try_catch.HasCaught()); 3269 CHECK(!try_catch.HasCaught());
3270 CHECK_EQ(1, r->Int32Value()); 3270 CHECK_EQ(1, r->Int32Value());
3271 } 3271 }
3272 3272
3273 // Check that env3 is not accessible from env1 3273 // Check that env3 is not accessible from env1
3274 { 3274 {
3275 Local<Value> r = global3->Get(v8_str("prop2")); 3275 Local<Value> r = global3->Get(v8_str("prop2"));
3276 CHECK(r->IsUndefined()); 3276 CHECK(r->IsUndefined());
3277 } 3277 }
3278 3278
3279 env2.Dispose(); 3279 env2.Dispose();
3280 env3.Dispose(); 3280 env3.Dispose();
3281 } 3281 }
3282 3282
3283 3283
3284 static bool NamedAccessBlocker(Local<v8::Object> global, 3284 static bool NamedAccessBlocker(Local<v8::Object> global,
3285 Local<Value> name, 3285 Local<Value> name,
3286 v8::AccessType type, 3286 v8::AccessType type,
(...skipping 1730 matching lines...) Expand 10 before | Expand all | Expand 10 after
5017 v8::HandleScope scope; 5017 v8::HandleScope scope;
5018 LocalContext context; 5018 LocalContext context;
5019 Local<ObjectTemplate> t = ObjectTemplate::New(); 5019 Local<ObjectTemplate> t = ObjectTemplate::New();
5020 t->Set(v8_str("asdf"), v8::FunctionTemplate::New(FunctionNameCallback)); 5020 t->Set(v8_str("asdf"), v8::FunctionTemplate::New(FunctionNameCallback));
5021 context->Global()->Set(v8_str("obj"), t->NewInstance()); 5021 context->Global()->Set(v8_str("obj"), t->NewInstance());
5022 v8::Handle<v8::Value> value = CompileRun("obj.asdf.name"); 5022 v8::Handle<v8::Value> value = CompileRun("obj.asdf.name");
5023 CHECK(value->IsString()); 5023 CHECK(value->IsString());
5024 v8::String::AsciiValue name(value); 5024 v8::String::AsciiValue name(value);
5025 CHECK_EQ("asdf", *name); 5025 CHECK_EQ("asdf", *name);
5026 } 5026 }
OLDNEW
« no previous file with comments | « src/top.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698