projectmoon
  • Joined on 2020-11-05
projectmoon deleted branch keep-drop-refactoring from projectmoon/tenebrous-dicebot 2021-09-30 21:17:49 +00:00
projectmoon merged pull request projectmoon/tenebrous-dicebot#93 2021-09-30 21:16:04 +00:00
Refactor keep-drop parsing into function, better error handling.
projectmoon pushed to master at projectmoon/tenebrous-dicebot 2021-09-30 21:16:03 +00:00
ee3ec18e06 Refactor keep-drop parsing into function, better error handling. (#93)
projectmoon pushed to master at projectmoon/projectmoon-overlay 2021-09-28 07:18:09 +00:00
03c663ad59 Add new rust analzyer
0460670c66 Remove Linux Libre kernel.
Compare 2 commits »
projectmoon pushed to keep-drop-refactoring at projectmoon/tenebrous-dicebot 2021-09-26 23:19:55 +00:00
ef5b4cb69b Potentially valid, not always valid.
projectmoon created pull request projectmoon/tenebrous-dicebot#93 2021-09-26 23:10:04 +00:00
Refactor keep-drop parsing into function, better error handling.
projectmoon pushed to keep-drop-refactoring at projectmoon/tenebrous-dicebot 2021-09-26 23:09:31 +00:00
0cb48bea07 Refactor keep-drop parsing into function, better error handling.
projectmoon pushed to master at projectmoon/tenebrous-dicebot 2021-09-26 14:16:23 +00:00
126548d868 Do not panic on invalid dice/sides amount for keep/drop.
projectmoon merged pull request projectmoon/tenebrous-dicebot#92 2021-09-26 14:05:57 +00:00
Keep/Drop Function
projectmoon pushed to master at projectmoon/tenebrous-dicebot 2021-09-26 14:05:56 +00:00
7e7e9e534e Adding None enum to keep/drop, cleaning up matches
2d9853fbf0 Updating README for new drop command
3d6210b32d Adding enum for exclusive drop/keep
8b5973475f Forgot to fix tests, fixing keep/drop Err case
1992ef4e08 Updating roll doc
Compare 12 commits »
projectmoon approved projectmoon/tenebrous-dicebot#92 2021-09-26 14:05:39 +00:00
Keep/Drop Function

Merging as it is now, with some immediate refactorings to follow up.

projectmoon pushed to master at projectmoon/projectmoon-overlay 2021-09-22 22:55:55 +00:00
4e4d9bc80b gnu-sources 5.10.61
projectmoon commented on pull request projectmoon/tenebrous-dicebot#92 2021-09-22 19:55:13 +00:00
Keep/Drop Function

You can make this a bit more concise with yet another match expression:

projectmoon commented on pull request projectmoon/tenebrous-dicebot#92 2021-09-22 19:53:33 +00:00
Keep/Drop Function

Rust supports tuple destructuring in pattern matching, which may be useful here and the other match:

projectmoon commented on pull request projectmoon/tenebrous-dicebot#92 2021-09-22 19:51:54 +00:00
Keep/Drop Function

Since you have if-else clauses here, it might make more sense to have a third enum member in addition to Keep and Drop, which indicates that we do nothing special with the roll.

projectmoon commented on pull request projectmoon/tenebrous-dicebot#92 2021-09-17 07:05:08 +00:00
Keep/Drop Function

I think it is better to document what the keep expression actually is here, so tacking on "1dXkY" would be useful.

projectmoon commented on pull request projectmoon/tenebrous-dicebot#92 2021-09-17 07:05:08 +00:00
Keep/Drop Function

Instead of unwrap, you should make use of the features of the Result type. While you will see examples of Rust code around the internet littered with unwrap, you don't actually want to use it except under a few circumstances:

projectmoon commented on pull request projectmoon/tenebrous-dicebot#92 2021-09-17 07:05:08 +00:00
Keep/Drop Function

Add a third / to get the Rustdoc working. It may also be good to more thoroughly describe what keep and drop mean here, namely that they mean keeping the highest or dropping the highest rolls.

projectmoon commented on pull request projectmoon/tenebrous-dicebot#92 2021-09-17 07:05:08 +00:00
Keep/Drop Function

Thank you for your pull request! I have made some comments. The most important one at the moment is getting rid of the unwrap() calls so that errors are propagated up the chain instead of potentially causing a panic (though not sure how possible that actually is). The remainder are currently stylistic.

projectmoon pushed to master at projectmoon/tenebrous-dicebot 2021-09-06 23:58:36 +00:00
125f3d0cee Fix drone yml to produce docker images again.