google / google/zerocopy

`#![feature(never_type)]` triggers `clippy::empty_enums`

Open
#3,414 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
2.6k
Forks
179
Avg merge
1d 19h
Merged PRs (30d)
29

Description

The following code:

```rust
#![feature(never_type)]
#![warn(clippy::empty_enums)]

#[derive(zerocopy::FromBytes)] pub struct Foo(());
```

triggers the `clippy::empty_enums` lint, which is part of the `clippy::pedantic` group. With the never type now nearing stabilization (https://github.com/rust-lang/rust/pull/155499), it would be nice to have this sorted out reasonably soon.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.