-
Notifications
You must be signed in to change notification settings - Fork 677
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixing ecma_op_from_property_descriptor semantics (type check for inp…
…ut property descriptor was implemented incorrectly). Related issue: #70 JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan [email protected]
- Loading branch information
1 parent
5841491
commit 5c76b3f
Showing
1 changed file
with
4 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -449,8 +449,8 @@ ecma_op_from_property_descriptor (const ecma_property_descriptor_t* src_prop_des | |
} | ||
|
||
// 3. | ||
if (prop_desc.is_value_defined | ||
|| prop_desc.is_writable_defined) | ||
if (src_prop_desc_p->is_value_defined | ||
|| src_prop_desc_p->is_writable_defined) | ||
{ | ||
JERRY_ASSERT (prop_desc.is_value_defined && prop_desc.is_writable_defined); | ||
This comment has been minimized.
Sorry, something went wrong. |
||
|
||
|
@@ -481,7 +481,8 @@ ecma_op_from_property_descriptor (const ecma_property_descriptor_t* src_prop_des | |
else | ||
{ | ||
// 4. | ||
JERRY_ASSERT (prop_desc.is_get_defined && prop_desc.is_set_defined); | ||
JERRY_ASSERT (src_prop_desc_p->is_get_defined | ||
&& src_prop_desc_p->is_set_defined); | ||
This comment has been minimized.
Sorry, something went wrong.
kkristof
Contributor
|
||
|
||
// a. | ||
if (src_prop_desc_p->get_p == NULL) | ||
|
1 comment
on commit 5c76b3f
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please take a look.
cc: @ruben-ayrapetyan @egavrin
Hi, this assert should have been changed also. However what happens if someone define property as below.
In this case I think the property descriptor
is_writable_defined
will be false which causes assert.