-
Notifications
You must be signed in to change notification settings - Fork 317
New issue
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
Add replace_text
method to In-Memory Table
#3793
Conversation
f896f0a
to
0bd225f
Compare
d65cca0
to
a01d73d
Compare
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.
Looks good to me, I really like the tests 😁
Ideally, I think we should have the replace
operation also implemented as a vectorized operation on StringStorage
(see for example how Column.like
is implemented) - it would likely be quite a bit faster because Column.map
is slow due to constant switches between Java and Enso. But I'm not sure if that is in the scope of this task - so I think this is free to go and we can think about the optimizations in the future too.
d023028
to
1e76cd2
Compare
1e76cd2
to
69b40a0
Compare
result.stack.head != Elem.Formatter(typ) && result.stack.nonEmpty | ||
result.stack.nonEmpty && result.stack.head != Elem.Formatter(typ) |
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.
This check was originally in wrong order - if result.stack
was empty the latter would be false, but before it's checked we'd call result.stack.head
which would throw an exception (due to an empty stack).
For some reason the changes in this PR have started triggering this. It is a bit curious why, but I think we should just have it changed to correctly finish the loop if the stack is empty.
Pull Request Description
Implements https://www.pivotaltracker.com/n/projects/2539304/stories/183415329
Important Notes
Checklist
Scala,
Java,
and
Rust
style guides.
./run ide build
and./run ide watch
.