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

Reject redefinition of Object operations #3329

Merged
merged 4 commits into from
Jan 10, 2025

Conversation

bernardnormier
Copy link
Member

Fixes #3318.

cpp/src/Slice/Parser.cpp Outdated Show resolved Hide resolved
@@ -723,6 +723,9 @@ namespace Slice
private:
friend class Container;

// Returns true if name does not collide with any base name; otherwise, false.
bool checkBaseOperationNames(const std::string& name, const std::vector<std::string>& baseNames);

Choose a reason for hiding this comment

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

I know that we're using this to check for collisions with base names, but the implementation itself isn't specific to base names.

I think a name like checkForNameCollision would be more apt for this function.
Along with changing baseNames to otherNames or something.

Copy link
Member Author

Choose a reason for hiding this comment

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

The implementation is specific to base operation names: please read the error messages.

Choose a reason for hiding this comment

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

Yes, you're right. It should be left as-is.

@bernardnormier bernardnormier merged commit 8eaab6b into zeroc-ice:main Jan 10, 2025
21 of 22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

We Should Blacklist ice_id, ice_ids, ice_ping, ice_isa as Allowable Operation Names
3 participants