| OLD | NEW |
| 1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 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 437 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 448 return value; | 448 return value; |
| 449 } | 449 } |
| 450 // Preserve enumeration index. | 450 // Preserve enumeration index. |
| 451 details = PropertyDetails(details.attributes(), | 451 details = PropertyDetails(details.attributes(), |
| 452 details.type(), | 452 details.type(), |
| 453 property_dictionary()->DetailsAt(entry).index()); | 453 property_dictionary()->DetailsAt(entry).index()); |
| 454 if (IsJSGlobalObject()) { | 454 if (IsJSGlobalObject()) { |
| 455 JSGlobalPropertyCell* cell = | 455 JSGlobalPropertyCell* cell = |
| 456 JSGlobalPropertyCell::cast(property_dictionary()->ValueAt(entry)); | 456 JSGlobalPropertyCell::cast(property_dictionary()->ValueAt(entry)); |
| 457 cell->set_value(value); | 457 cell->set_value(value); |
| 458 // No need to update the property dictionary. | 458 // Please note we have to update the property details. |
| 459 property_dictionary()->SetStringEntry(entry, name, cell, details); |
| 459 } else { | 460 } else { |
| 460 property_dictionary()->SetStringEntry(entry, name, value, details); | 461 property_dictionary()->SetStringEntry(entry, name, value, details); |
| 461 } | 462 } |
| 462 return value; | 463 return value; |
| 463 } | 464 } |
| 464 | 465 |
| 465 | 466 |
| 466 Object* Object::GetProperty(Object* receiver, | 467 Object* Object::GetProperty(Object* receiver, |
| 467 LookupResult* result, | 468 LookupResult* result, |
| 468 String* name, | 469 String* name, |
| (...skipping 6869 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7338 // No break point. | 7339 // No break point. |
| 7339 if (break_point_objects()->IsUndefined()) return 0; | 7340 if (break_point_objects()->IsUndefined()) return 0; |
| 7340 // Single beak point. | 7341 // Single beak point. |
| 7341 if (!break_point_objects()->IsFixedArray()) return 1; | 7342 if (!break_point_objects()->IsFixedArray()) return 1; |
| 7342 // Multiple break points. | 7343 // Multiple break points. |
| 7343 return FixedArray::cast(break_point_objects())->length(); | 7344 return FixedArray::cast(break_point_objects())->length(); |
| 7344 } | 7345 } |
| 7345 | 7346 |
| 7346 | 7347 |
| 7347 } } // namespace v8::internal | 7348 } } // namespace v8::internal |
| OLD | NEW |