| OLD | NEW |
| 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 1845 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1856 | 1856 |
| 1857 | 1857 |
| 1858 void JSObject::LookupCallbackSetterInPrototypes(String* name, | 1858 void JSObject::LookupCallbackSetterInPrototypes(String* name, |
| 1859 LookupResult* result) { | 1859 LookupResult* result) { |
| 1860 Heap* heap = GetHeap(); | 1860 Heap* heap = GetHeap(); |
| 1861 for (Object* pt = GetPrototype(); | 1861 for (Object* pt = GetPrototype(); |
| 1862 pt != heap->null_value(); | 1862 pt != heap->null_value(); |
| 1863 pt = pt->GetPrototype()) { | 1863 pt = pt->GetPrototype()) { |
| 1864 JSObject::cast(pt)->LocalLookupRealNamedProperty(name, result); | 1864 JSObject::cast(pt)->LocalLookupRealNamedProperty(name, result); |
| 1865 if (result->IsProperty()) { | 1865 if (result->IsProperty()) { |
| 1866 if (result->IsReadOnly()) { | 1866 if (result->type() == CALLBACKS && !result->IsReadOnly()) return; |
| 1867 result->NotFound(); | 1867 // Found non-callback or read-only callback, stop looking. |
| 1868 return; | 1868 break; |
| 1869 } | |
| 1870 if (result->type() == CALLBACKS) { | |
| 1871 return; | |
| 1872 } | |
| 1873 } | 1869 } |
| 1874 } | 1870 } |
| 1875 result->NotFound(); | 1871 result->NotFound(); |
| 1876 } | 1872 } |
| 1877 | 1873 |
| 1878 | 1874 |
| 1879 MaybeObject* JSObject::SetElementWithCallbackSetterInPrototypes(uint32_t index, | 1875 MaybeObject* JSObject::SetElementWithCallbackSetterInPrototypes(uint32_t index, |
| 1880 Object* value, | 1876 Object* value, |
| 1881 bool* found) { | 1877 bool* found) { |
| 1882 Heap* heap = GetHeap(); | 1878 Heap* heap = GetHeap(); |
| (...skipping 8724 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 10607 if (break_point_objects()->IsUndefined()) return 0; | 10603 if (break_point_objects()->IsUndefined()) return 0; |
| 10608 // Single beak point. | 10604 // Single beak point. |
| 10609 if (!break_point_objects()->IsFixedArray()) return 1; | 10605 if (!break_point_objects()->IsFixedArray()) return 1; |
| 10610 // Multiple break points. | 10606 // Multiple break points. |
| 10611 return FixedArray::cast(break_point_objects())->length(); | 10607 return FixedArray::cast(break_point_objects())->length(); |
| 10612 } | 10608 } |
| 10613 #endif | 10609 #endif |
| 10614 | 10610 |
| 10615 | 10611 |
| 10616 } } // namespace v8::internal | 10612 } } // namespace v8::internal |
| OLD | NEW |