We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug The feel expression remove([1,2,3], 0) returns [1,2,3,1,2,3].
remove([1,2,3], 0)
[1,2,3,1,2,3]
This bug is due to the below code
private def removeFunction = builtinFunction( params = List("list", "position"), invoke = { case List(ValList(list), ValNumber(position)) => ValList( list.take(listIndex(list, position.intValue)) ++ list.drop(listIndex(list, position.intValue + 1) ) ) } )
The goal of this code is to
list.take(listIndex(list, position.intValue))
list.drop(listIndex(list, position.intValue + 1)
The problem is
listIndex(list, position.intValue)
listIndex(list, position.intValue + 1)
where ``````
To Reproduce Execute the feel expression remove([1,2,3], 0)
Expected behavior Returns the same list given as input.
Environment
The text was updated successfully, but these errors were encountered:
@mdouaihy thank you for reporting. 👍
I can confirm the bug in the version 1.19.0. ✅
1.19.0
Sorry, something went wrong.
No branches or pull requests
Describe the bug
The feel expression
remove([1,2,3], 0)
returns[1,2,3,1,2,3]
.This bug is due to the below code
The goal of this code is to
list.take(listIndex(list, position.intValue))
list.drop(listIndex(list, position.intValue + 1)
The problem is
listIndex(list, position.intValue)
returns 3 andlistIndex(list, position.intValue + 1)
is returning 0.where ``````
To Reproduce
Execute the feel expression
remove([1,2,3], 0)
Expected behavior
Returns the same list given as input.
Environment
The text was updated successfully, but these errors were encountered: