OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 // | 4 // |
5 // Review notes: | 5 // Review notes: |
6 // | 6 // |
7 // - The use of macros in these inline functions may seem superfluous | 7 // - The use of macros in these inline functions may seem superfluous |
8 // but it is absolutely needed to make sure gcc generates optimal | 8 // but it is absolutely needed to make sure gcc generates optimal |
9 // code. gcc is not happy when attempting to inline too deep. | 9 // code. gcc is not happy when attempting to inline too deep. |
10 // | 10 // |
(...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
285 return Name::cast(second)->AsArrayIndex(&index) && index == expected; | 285 return Name::cast(second)->AsArrayIndex(&index) && index == expected; |
286 } | 286 } |
287 return Name::cast(first)->Equals(Name::cast(second)); | 287 return Name::cast(first)->Equals(Name::cast(second)); |
288 } | 288 } |
289 | 289 |
290 | 290 |
291 bool Object::FilterKey(PropertyFilter filter) { | 291 bool Object::FilterKey(PropertyFilter filter) { |
292 if (IsSymbol()) { | 292 if (IsSymbol()) { |
293 if (filter & SKIP_SYMBOLS) return true; | 293 if (filter & SKIP_SYMBOLS) return true; |
294 if (Symbol::cast(this)->is_private()) return true; | 294 if (Symbol::cast(this)->is_private()) return true; |
| 295 } else { |
| 296 if (filter & SKIP_STRINGS) return true; |
295 } | 297 } |
296 if ((filter & SKIP_STRINGS) && !IsSymbol()) return true; | |
297 | |
298 return false; | 298 return false; |
299 } | 299 } |
300 | 300 |
301 | 301 |
302 Handle<Object> Object::NewStorageFor(Isolate* isolate, | 302 Handle<Object> Object::NewStorageFor(Isolate* isolate, |
303 Handle<Object> object, | 303 Handle<Object> object, |
304 Representation representation) { | 304 Representation representation) { |
305 if (representation.IsSmi() && object->IsUninitialized()) { | 305 if (representation.IsSmi() && object->IsUninitialized()) { |
306 return handle(Smi::FromInt(0), isolate); | 306 return handle(Smi::FromInt(0), isolate); |
307 } | 307 } |
(...skipping 7555 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7863 #undef WRITE_INT64_FIELD | 7863 #undef WRITE_INT64_FIELD |
7864 #undef READ_BYTE_FIELD | 7864 #undef READ_BYTE_FIELD |
7865 #undef WRITE_BYTE_FIELD | 7865 #undef WRITE_BYTE_FIELD |
7866 #undef NOBARRIER_READ_BYTE_FIELD | 7866 #undef NOBARRIER_READ_BYTE_FIELD |
7867 #undef NOBARRIER_WRITE_BYTE_FIELD | 7867 #undef NOBARRIER_WRITE_BYTE_FIELD |
7868 | 7868 |
7869 } // namespace internal | 7869 } // namespace internal |
7870 } // namespace v8 | 7870 } // namespace v8 |
7871 | 7871 |
7872 #endif // V8_OBJECTS_INL_H_ | 7872 #endif // V8_OBJECTS_INL_H_ |
OLD | NEW |