mirror of
https://github.com/Samsung/escargot.git
synced 2026-06-29 10:02:14 +00:00
1. fix bug in Object::nextIndex*
2. implement ::generateCodeBlockTreeFromASTWalkerPostProcess Signed-off-by: seonghyun kim <sh8281.kim@samsung.com>
This commit is contained in:
parent
2057250e48
commit
c970d99552
7 changed files with 21 additions and 15 deletions
|
|
@ -713,7 +713,7 @@ double Object::nextIndexForward(ExecutionState& state, Object* obj, const double
|
|||
}
|
||||
if (index > cur) {
|
||||
if (ret > index) {
|
||||
ret = index;
|
||||
ret = std::min(static_cast<double>(index), ret);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -737,9 +737,7 @@ double Object::nextIndexBackward(ExecutionState& state, Object* obj, const doubl
|
|||
return true;
|
||||
}
|
||||
if (index < cur) {
|
||||
if (ret < index) {
|
||||
ret = index;
|
||||
}
|
||||
ret = std::max(static_cast<double>(index), ret);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue