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

chore: remove constructor from abi #247

Merged
merged 3 commits into from
Aug 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions contracts/src/access/control.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
//! Contract module that allows children to implement role-based access control
//! mechanisms. This is a lightweight version that doesn't allow enumerating
//! role members except through off-chain means by accessing the contract event
//! logs. Some applications may benefit from on-chain enumerability, for those
//! cases see [`AccessControlEnumberable`][enumerable ext].
Copy link
Member Author

Choose a reason for hiding this comment

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

We don't have it implemented. Hence remove it

//! logs.
//!
//! Roles are referred to by their `bytes32` identifier. These should be exposed
//! in the external API and be unique. The best way to achieve this is by using
Expand Down Expand Up @@ -41,8 +40,6 @@
//! accounts that have been granted it. We recommend using
//! `AccessControlDefaultAdminRules` to enforce additional security measures for
//! this role.
//!
//! [enumerable ext]: ./TODO
use alloy_primitives::{Address, B256};
use alloy_sol_types::sol;
use stylus_proc::SolidityError;
Expand Down Expand Up @@ -388,7 +385,7 @@ mod tests {

use super::{AccessControl, Error};

/// Shorthand for declaring variables converted from a hex literla to a
/// Shorthand for declaring variables converted from a hex literal to a
/// fixed 32-byte slice;
macro_rules! roles {
($($var:ident = $hex:literal);* $(;)?) => {
Expand Down
2 changes: 0 additions & 2 deletions examples/access-control/tests/abi/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ use alloy::sol;
sol!(
#[sol(rpc)]
contract AccessControl {
constructor();

function hasRole(bytes32 role, address account) public view virtual returns (bool hasRole);
function getRoleAdmin(bytes32 role) public view virtual returns (bytes32 role);
function grantRole(bytes32 role, address account) public virtual;
Expand Down
Loading