Skip to content

Conversation

@xdoardo
Copy link
Collaborator

@xdoardo xdoardo commented Jun 6, 2025

In particular, this PR fixes the mangling scheme of permissions ("" -> "-" when permission not present) and, when checking for volatile qualifiers, checks the pointee if the type is a pointer.

@xdoardo xdoardo force-pushed the cheriot branch 2 times, most recently from 79343f6 to ad850de Compare June 9, 2025 12:39
(HasWrite ? std::string(WritePermissionSymbol) : "") +
(HasCap ? std::string(CapPermissionSymbol) : "") +
(HasMut ? std::string(MutPermissionSymbol) : "");
Permissions = (HasRead ? std::string(ReadPermissionSymbol) : "-") +
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think this would be a good place to use Twine(...) over std::string(...)

See https://llvm.org/docs/ProgrammersManual.html#the-twine-class and https://llvm.org/docs/ProgrammersManual.html#dss-twine

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

8718b52 changes this snippet to use twines.

In particular, fix the mangling scheme of permissions ("" -> "-" when
permission not present) and, when checking for volatile qualifiers,
reach to pointee if type is pointer
@xdoardo xdoardo merged commit 6053c45 into CHERIoT-Platform:cheriot Jun 10, 2025
7 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.

2 participants