Skip to content

Commit edcf877

Browse files
committed
feat: add more derive for options
1 parent 47bff39 commit edcf877

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
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 = "sass-embedded"
3-
version = "0.6.0"
3+
version = "0.6.1"
44
authors = ["ahabhgk <ahabhgk@gmail.com>"]
55
edition = "2021"
66
resolver = "2"

src/api.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -501,7 +501,7 @@ impl From<CompileSuccess> for CompileResult {
501501

502502
/// More information: [Sass documentation](https://sass-lang.com/documentation/js-api/modules#OutputStyle)
503503
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
504-
#[derive(Debug)]
504+
#[derive(Debug, Clone, Copy)]
505505
pub enum OutputStyle {
506506
/// Writes each selector and declaration on its own line.
507507
Expanded,
@@ -526,7 +526,7 @@ impl From<OutputStyle> for protocol::OutputStyle {
526526

527527
/// More information: [Sass documentation](https://sass-lang.com/documentation/js-api/modules#Syntax)
528528
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
529-
#[derive(Debug)]
529+
#[derive(Debug, Clone, Copy)]
530530
pub enum Syntax {
531531
/// the [scss syntax](https://sass-lang.com/documentation/syntax#scss)
532532
Scss,
@@ -554,7 +554,7 @@ impl From<Syntax> for protocol::Syntax {
554554

555555
/// More information: [Sass documentation](https://sass-lang.com/documentation/js-api/interfaces/SourceSpan)
556556
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
557-
#[derive(Debug)]
557+
#[derive(Debug, Clone)]
558558
pub struct SourceSpan {
559559
/// More information: [Sass documentation](https://sass-lang.com/documentation/js-api/interfaces/SourceSpan#context)
560560
pub context: Option<String>,
@@ -590,7 +590,7 @@ impl From<protocol::SourceSpan> for SourceSpan {
590590
}
591591

592592
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
593-
#[derive(Debug)]
593+
#[derive(Debug, Clone)]
594594
pub struct SourceLocation {
595595
pub offset: usize,
596596
pub line: usize,

src/legacy/api.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ pub const PATH_DELIMITER: &str = ":";
2828

2929
/// More information: [Sass documentation](https://sass-lang.com/documentation/js-api/interfaces/LegacyFileOptions#indentType)
3030
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
31-
#[derive(Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
31+
#[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
3232
pub enum IndentType {
3333
/// Space IndentType.
3434
Space,
@@ -44,7 +44,7 @@ impl Default for IndentType {
4444

4545
/// More information: [Sass documentation](https://sass-lang.com/documentation/js-api/interfaces/LegacyFileOptions#linefeed)
4646
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
47-
#[derive(Debug, Clone, PartialEq, Eq, Hash)]
47+
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
4848
pub enum LineFeed {
4949
/// 'cr' uses U+000D CARRIAGE RETURN.
5050
CR,

0 commit comments

Comments
 (0)