You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Entity::CombineIds should take Entity::Id's as arguments, not strings
Entity::SeparateIds should return an Entity::Id not a string
A comment should have a CommentId, which should provide operations to extract the BugId or OperationId. So that using CombeIds/SeparateIds is an implmentation detail.
RepoCacheBug::ResolveComment should return an Entity::Id not a combined Id, as the user of this function already has a reference to the bug, rendering the CombinedId useless. Unless the CombinedId is the real CommentId, but then this Id should provide functions for easier handling, as mentioned in previous point.
Just a quick note (sorry I really can't find the time to work on this at the moment :'-( ):
Entity::SeparateIds should return an Entity::Id not a string
You should not do that. Entity::Id should always be a complete Id. SeparateIds() is only able to output two prefixes and therefore can't be considered as Id. We could consider a special type for the prefixes but for now they are string everywhere.
If you have a prefix but need an Id, you should use one of the ResolveXXX functions. They will deal with the possible collisions as well.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Possible improvements: