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

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

Issue 11293246: Reverting r12937. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 1 month 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/x64/code-stubs-x64.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 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 315 matching lines...) Expand 10 before | Expand all | Expand 10 after
326 case kTwoByteStringTag: 326 case kTwoByteStringTag:
327 return true; 327 return true;
328 default: // Cons or sliced string. Need to go deeper. 328 default: // Cons or sliced string. Need to go deeper.
329 return GetUnderlying()->IsTwoByteRepresentation(); 329 return GetUnderlying()->IsTwoByteRepresentation();
330 } 330 }
331 } 331 }
332 332
333 333
334 bool String::HasOnlyAsciiChars() { 334 bool String::HasOnlyAsciiChars() {
335 uint32_t type = map()->instance_type(); 335 uint32_t type = map()->instance_type();
336 return (type & kAsciiDataHintMask) == kAsciiDataHintTag; 336 return (type & kStringEncodingMask) == kOneByteStringTag ||
337 (type & kAsciiDataHintMask) == kAsciiDataHintTag;
337 } 338 }
338 339
339 340
340 bool StringShape::IsCons() { 341 bool StringShape::IsCons() {
341 return (type_ & kStringRepresentationMask) == kConsStringTag; 342 return (type_ & kStringRepresentationMask) == kConsStringTag;
342 } 343 }
343 344
344 345
345 bool StringShape::IsSliced() { 346 bool StringShape::IsSliced() {
346 return (type_ & kStringRepresentationMask) == kSlicedStringTag; 347 return (type_ & kStringRepresentationMask) == kSlicedStringTag;
(...skipping 5201 matching lines...) Expand 10 before | Expand all | Expand 10 after
5548 #undef WRITE_UINT32_FIELD 5549 #undef WRITE_UINT32_FIELD
5549 #undef READ_SHORT_FIELD 5550 #undef READ_SHORT_FIELD
5550 #undef WRITE_SHORT_FIELD 5551 #undef WRITE_SHORT_FIELD
5551 #undef READ_BYTE_FIELD 5552 #undef READ_BYTE_FIELD
5552 #undef WRITE_BYTE_FIELD 5553 #undef WRITE_BYTE_FIELD
5553 5554
5554 5555
5555 } } // namespace v8::internal 5556 } } // namespace v8::internal
5556 5557
5557 #endif // V8_OBJECTS_INL_H_ 5558 #endif // V8_OBJECTS_INL_H_
OLDNEW
« no previous file with comments | « src/objects.h ('k') | src/x64/code-stubs-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698