Skip to content
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 & syntax for ev_rx #1072

Merged
merged 4 commits into from
May 4, 2023
Merged

Add & syntax for ev_rx #1072

merged 4 commits into from
May 4, 2023

Conversation

kylebaron
Copy link
Collaborator

@kylebaron kylebaron commented Apr 7, 2023

Summary

  • Use & to indicate that multiple events should be done at the same time
  • perl = TRUE not required; I just like perl

@kylebaron kylebaron requested a review from kyleam May 2, 2023 23:51
Copy link
Contributor

@kyleam kyleam left a 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.


a <- ev_rx("100 in 1 & 200 in 2 then 300 in 3 after 10")
b <- c(ev(amt = 100, cmt = 1), ev(amt = 200, cmt = 2),
ev(amt = 300, cmt = 3, time = 10))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor suggestion: I think making b completely reflect the expected output would be a bit nicer. If you added addl = 0, ii = 0 to all of these ev calls, you could just use expect_identical(a, b), right?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea; done.

@kylebaron kylebaron merged commit 0a58c2c into main May 4, 2023
@kylebaron kylebaron deleted the evrx/and branch May 4, 2023 04:15
@kylebaron kylebaron restored the evrx/and branch May 8, 2023 13:31
@kylebaron kylebaron self-assigned this Jul 15, 2023
@kylebaron kylebaron added this to the v1.1.0 milestone Jul 15, 2023
@kylebaron kylebaron added this to Done in Development Jul 15, 2023
@kylebaron kylebaron mentioned this pull request Aug 14, 2023
@kylebaron kylebaron deleted the evrx/and branch December 14, 2023 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development
  
Done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants