Skip to content

Commit 7cd5d11

Browse files
committed
style: allow target_arch #[cfg()] statements
1 parent 2d807ee commit 7cd5d11

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ci/style.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,8 @@ fn check_style(file: &str, path: &Path, err: &mut Errors) {
128128
err.error(path, i, "use `extern` instead of `extern \"C\"");
129129
}
130130
if line.contains("#[cfg(") && !line.contains(" if ")
131-
&& !line.contains("target_endian")
131+
&& !(line.contains("target_endian") ||
132+
line.contains("target_arch"))
132133
{
133134
if state != State::Structs {
134135
err.error(path, i, "use cfg_if! and submodules \

0 commit comments

Comments
 (0)