Skip to content

Commit

Permalink
[GR-53902] Fix DynamicObjectLibrary.setPropertyFlags.
Browse files Browse the repository at this point in the history
  • Loading branch information
woess committed May 6, 2024
1 parent 0c7497f commit 097092b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -654,13 +654,13 @@ public Property getProperty(DynamicObject object, Shape cachedShape, Object key)
@TruffleBoundary
@Override
public boolean setPropertyFlags(DynamicObject object, Shape cachedShape, Object key, int propertyFlags) {
updateShapeImpl(object);
ShapeImpl oldShape = (ShapeImpl) ACCESS.getShape(object);
Property existingProperty = oldShape.getProperty(key);
if (existingProperty == null) {
return false;
}
if (existingProperty.getFlags() != propertyFlags) {
updateShapeImpl(object);
Shape newShape = changePropertyFlags(oldShape, (PropertyImpl) existingProperty, propertyFlags);
if (newShape != oldShape) {
ACCESS.setShape(object, newShape);
Expand Down

0 comments on commit 097092b

Please sign in to comment.