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

Side by Side Diff: src/objects-inl.h

Issue 7889046: Add an optional source length field to the Extension constructor. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 9 years, 3 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/objects.h ('k') | src/serialize.cc » ('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 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 2358 matching lines...) Expand 10 before | Expand all | Expand 10 after
2369 return READ_FIELD(this, kSecondOffset); 2369 return READ_FIELD(this, kSecondOffset);
2370 } 2370 }
2371 2371
2372 2372
2373 void ConsString::set_second(String* value, WriteBarrierMode mode) { 2373 void ConsString::set_second(String* value, WriteBarrierMode mode) {
2374 WRITE_FIELD(this, kSecondOffset, value); 2374 WRITE_FIELD(this, kSecondOffset, value);
2375 CONDITIONAL_WRITE_BARRIER(GetHeap(), this, kSecondOffset, mode); 2375 CONDITIONAL_WRITE_BARRIER(GetHeap(), this, kSecondOffset, mode);
2376 } 2376 }
2377 2377
2378 2378
2379 ExternalAsciiString::Resource* ExternalAsciiString::resource() { 2379 const ExternalAsciiString::Resource* ExternalAsciiString::resource() {
2380 return *reinterpret_cast<Resource**>(FIELD_ADDR(this, kResourceOffset)); 2380 return *reinterpret_cast<Resource**>(FIELD_ADDR(this, kResourceOffset));
2381 } 2381 }
2382 2382
2383 2383
2384 void ExternalAsciiString::set_resource( 2384 void ExternalAsciiString::set_resource(
2385 ExternalAsciiString::Resource* resource) { 2385 const ExternalAsciiString::Resource* resource) {
2386 *reinterpret_cast<Resource**>(FIELD_ADDR(this, kResourceOffset)) = resource; 2386 *reinterpret_cast<const Resource**>(
2387 FIELD_ADDR(this, kResourceOffset)) = resource;
2387 } 2388 }
2388 2389
2389 2390
2390 ExternalTwoByteString::Resource* ExternalTwoByteString::resource() { 2391 const ExternalTwoByteString::Resource* ExternalTwoByteString::resource() {
2391 return *reinterpret_cast<Resource**>(FIELD_ADDR(this, kResourceOffset)); 2392 return *reinterpret_cast<Resource**>(FIELD_ADDR(this, kResourceOffset));
2392 } 2393 }
2393 2394
2394 2395
2395 void ExternalTwoByteString::set_resource( 2396 void ExternalTwoByteString::set_resource(
2396 ExternalTwoByteString::Resource* resource) { 2397 const ExternalTwoByteString::Resource* resource) {
2397 *reinterpret_cast<Resource**>(FIELD_ADDR(this, kResourceOffset)) = resource; 2398 *reinterpret_cast<const Resource**>(
2399 FIELD_ADDR(this, kResourceOffset)) = resource;
2398 } 2400 }
2399 2401
2400 2402
2401 void JSFunctionResultCache::MakeZeroSize() { 2403 void JSFunctionResultCache::MakeZeroSize() {
2402 set_finger_index(kEntriesIndex); 2404 set_finger_index(kEntriesIndex);
2403 set_size(kEntriesIndex); 2405 set_size(kEntriesIndex);
2404 } 2406 }
2405 2407
2406 2408
2407 void JSFunctionResultCache::Clear() { 2409 void JSFunctionResultCache::Clear() {
(...skipping 2235 matching lines...) Expand 10 before | Expand all | Expand 10 after
4643 #undef WRITE_INT_FIELD 4645 #undef WRITE_INT_FIELD
4644 #undef READ_SHORT_FIELD 4646 #undef READ_SHORT_FIELD
4645 #undef WRITE_SHORT_FIELD 4647 #undef WRITE_SHORT_FIELD
4646 #undef READ_BYTE_FIELD 4648 #undef READ_BYTE_FIELD
4647 #undef WRITE_BYTE_FIELD 4649 #undef WRITE_BYTE_FIELD
4648 4650
4649 4651
4650 } } // namespace v8::internal 4652 } } // namespace v8::internal
4651 4653
4652 #endif // V8_OBJECTS_INL_H_ 4654 #endif // V8_OBJECTS_INL_H_
OLDNEW
« no previous file with comments | « src/objects.h ('k') | src/serialize.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698