Skip to content

Commit 83adcf5

Browse files
committed
color: Make cssparser::RGBA #[repr(C)].
This will be useful for my efforts of avoiding intermediate representations in the style system.
1 parent 6666620 commit 83adcf5

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "cssparser"
3-
version = "0.25.2"
3+
version = "0.25.3"
44
authors = [ "Simon Sapin <simon.sapin@exyr.org>" ]
55

66
description = "Rust implementation of CSS Syntax Level 3"

src/color.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ use serde::{Deserialize, Deserializer, Serialize, Serializer};
1212

1313
/// A color with red, green, blue, and alpha components, in a byte each.
1414
#[derive(Clone, Copy, PartialEq, Debug)]
15+
#[repr(C)]
1516
pub struct RGBA {
1617
/// The red component.
1718
pub red: u8,

0 commit comments

Comments
 (0)