Skip to content

Commit

Permalink
breaking: drop deprecated APIs
Browse files Browse the repository at this point in the history
  • Loading branch information
paolobarbolini committed Mar 28, 2024
1 parent fc1b629 commit 33ee23e
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 14 deletions.
2 changes: 1 addition & 1 deletion src/headers/hex_encoding.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::fmt::{self, Write};

use super::{hex, utils, EmailWriter};
use super::{hex, utils, writer::EmailWriter};

pub(super) fn percent_encode_char(w: &mut EmailWriter<'_>, to_append: char) -> fmt::Result {
encode_char(w, '%', to_append)
Expand Down
3 changes: 0 additions & 3 deletions src/headers/mod.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
//! Email header encoding algorithms.
#[deprecated(note = "Import it through the writer module", since = "0.1.1")]
pub use self::writer::EmailWriter;

mod hex;
mod hex_encoding;
pub mod quoted_string;
Expand Down
2 changes: 1 addition & 1 deletion src/headers/quoted_string.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
use std::fmt::{self, Write};

use super::{rfc2047, utils, EmailWriter};
use super::{rfc2047, utils, writer::EmailWriter};

/// Encode a string that may need to be quoted.
///
Expand Down
2 changes: 1 addition & 1 deletion src/headers/rfc2047.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
use std::fmt::{self, Write};

use super::{utils, EmailWriter, MAX_LINE_LEN};
use super::{utils, writer::EmailWriter, MAX_LINE_LEN};

const ENCODING_START_PREFIX: &str = "=?utf-8?b?";
const ENCODING_END_SUFFIX: &str = "?=";
Expand Down
2 changes: 1 addition & 1 deletion src/headers/rfc2231.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
use std::fmt::{self, Write};

use super::{hex_encoding, utils, EmailWriter, MAX_LINE_LEN};
use super::{hex_encoding, utils, writer::EmailWriter, MAX_LINE_LEN};

/// Encode a string via RFC 2231.
///
Expand Down
7 changes: 0 additions & 7 deletions src/headers/writer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,6 @@ impl<'a> EmailWriter<'a> {
Ok(())
}

#[cfg(not(tarpaulin_include))]
#[doc(hidden)]
#[deprecated(note = "Renamed to `new_line`", since = "0.1.2")]
pub fn new_line_no_initial_space(&mut self) -> fmt::Result {
self.new_line()
}

/// Write a space which _might_ get wrapped to a new line on the next write.
pub fn space(&mut self) {
self.spaces += 1;
Expand Down

0 comments on commit 33ee23e

Please sign in to comment.