Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 2b8f102

Browse filesBrowse files
committed
xtask: fix check-raw
check-raw is very strict. Relaxing it gives uefi-raw more freedom, which is especially needed for the more high-level IpAddress type changes.
1 parent 62d5a47 commit 2b8f102
Copy full SHA for 2b8f102

File tree

Expand file treeCollapse file tree

1 file changed

+8
-3
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+8
-3
lines changed

‎xtask/src/check_raw.rs

Copy file name to clipboardExpand all lines: xtask/src/check_raw.rs
+8-3Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,12 @@ fn check_fields(fields: &Punctuated<Field, Comma>, src: &Path) -> Result<(), Err
280280
}
281281

282282
/// List with allowed combinations of representations (see [`Repr`]).
283-
const ALLOWED_REPRS: &[&[Repr]] = &[&[Repr::C], &[Repr::C, Repr::Packed], &[Repr::Transparent]];
283+
const ALLOWED_REPRS: &[&[Repr]] = &[
284+
&[Repr::C],
285+
&[Repr::C, Repr::Packed],
286+
&[Repr::Transparent],
287+
&[Repr::Align(4), Repr::C],
288+
];
284289

285290
fn check_type_attrs(attrs: &[Attribute], spanned: &dyn Spanned, src: &Path) -> Result<(), Error> {
286291
let attrs = parse_attrs(attrs, src)?;
@@ -482,7 +487,7 @@ mod tests {
482487
}
483488
}
484489
},
485-
ErrorKind::ForbiddenRepr,
490+
ErrorKind::ForbiddenRepr(vec![Repr::C]),
486491
);
487492
}
488493

@@ -614,7 +619,7 @@ mod tests {
614619
pub f: u32,
615620
}
616621
},
617-
ErrorKind::ForbiddenRepr,
622+
ErrorKind::ForbiddenRepr(vec![Repr::Rust]),
618623
);
619624

620625
// Forbidden attr.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.