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

Side by Side Diff: src/objects.cc

Issue 183103003: Fix for Clusterfuzz issue 343928. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 9 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/contexts.h ('k') | test/mjsunit/regress/regress-343928.js » ('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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 5425 matching lines...) Expand 10 before | Expand all | Expand 10 after
5436 return true; 5436 return true;
5437 } 5437 }
5438 } else if (ctxobj == obj) { 5438 } else if (ctxobj == obj) {
5439 return true; 5439 return true;
5440 } 5440 }
5441 } 5441 }
5442 } 5442 }
5443 5443
5444 // Check the context extension (if any) if it can have references. 5444 // Check the context extension (if any) if it can have references.
5445 if (context->has_extension() && !context->IsCatchContext()) { 5445 if (context->has_extension() && !context->IsCatchContext()) {
5446 // With harmony scoping, a JSFunction may have a global context.
5447 // TODO(mvstanton): walk into the ScopeInfo.
5448 if (FLAG_harmony_scoping && context->IsGlobalContext()) {
5449 return false;
5450 }
5451
5446 return JSObject::cast(context->extension())->ReferencesObject(obj); 5452 return JSObject::cast(context->extension())->ReferencesObject(obj);
5447 } 5453 }
5448 } 5454 }
5449 5455
5450 // No references to object. 5456 // No references to object.
5451 return false; 5457 return false;
5452 } 5458 }
5453 5459
5454 5460
5455 Handle<Object> JSObject::PreventExtensions(Handle<JSObject> object) { 5461 Handle<Object> JSObject::PreventExtensions(Handle<JSObject> object) {
(...skipping 11025 matching lines...) Expand 10 before | Expand all | Expand 10 after
16481 #define ERROR_MESSAGES_TEXTS(C, T) T, 16487 #define ERROR_MESSAGES_TEXTS(C, T) T,
16482 static const char* error_messages_[] = { 16488 static const char* error_messages_[] = {
16483 ERROR_MESSAGES_LIST(ERROR_MESSAGES_TEXTS) 16489 ERROR_MESSAGES_LIST(ERROR_MESSAGES_TEXTS)
16484 }; 16490 };
16485 #undef ERROR_MESSAGES_TEXTS 16491 #undef ERROR_MESSAGES_TEXTS
16486 return error_messages_[reason]; 16492 return error_messages_[reason];
16487 } 16493 }
16488 16494
16489 16495
16490 } } // namespace v8::internal 16496 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/contexts.h ('k') | test/mjsunit/regress/regress-343928.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698