fn viewing_roles(
overwrites: &[PermissionOverwrite],
role_perms: &HashMap<RoleId, Permissions>,
everyone_role_id: RoleId,
) -> HashSet<RoleId>Expand description
Computes the set of roles that can effectively VIEW_CHANNEL a channel.
@everyone (role id == guild id) is treated as a normal role and included in
the result when applicable. For each role the effective permission is
@everyone perms | role perms; a role with ADMINISTRATOR always views the
channel. Otherwise the channel’s @everyone overwrite is applied first, then
the role’s own overwrite, each as deny-then-allow.