Skip to content

Commit 00cb074

Browse files
fix: Macro crate does not depend on primary crate. (#17)
1 parent d8f71c9 commit 00cb074

File tree

2 files changed

+0
-19
lines changed

2 files changed

+0
-19
lines changed

macros/Cargo.toml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,3 @@ exclude = [
1818

1919
[lib]
2020
proc-macro = true
21-
22-
[dev-dependencies]
23-
unix-ts = { path = "..", version = "1" }

macros/src/lib.rs

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,6 @@
44
use proc_macro::TokenStream;
55

66
/// Create a timestamp from the given Unix timestamp.
7-
///
8-
/// # Examples
9-
///
10-
/// ```
11-
/// use unix_ts_macros::ts;
12-
///
13-
/// let t = ts!(1335020400);
14-
/// assert_eq!(t.seconds(), 1335020400);
15-
///
16-
/// let t = ts!(1335020400.25);
17-
/// assert_eq!(t.seconds(), 1335020400);
18-
/// assert_eq!(t.subsec(3), 250);
19-
///
20-
/// let t = ts!(-86400);
21-
/// assert_eq!(t.seconds(), -86400);
22-
/// ```
237
#[proc_macro]
248
pub fn ts(input: TokenStream) -> TokenStream {
259
let mut src = input.to_string().trim_start().trim_end().to_owned();

0 commit comments

Comments
 (0)