Chris Wong
35d5204cab
Update to rustc 1.30.0-nightly (9395f0af7 2018-09-02)
2018-09-03 20:01:39 +12:00
Chris Wong
f17e21423e
Remove #![feature(use_extern_macros)]
2018-08-18 16:25:15 -07:00
Chris Wong
de6f654614
Release 0.18.1
2018-07-18 20:03:44 +12:00
Chris Wong
8dbcdab2bf
Update to rustc 1.29.0-nightly (1ecf6929d 2018-07-16)
...
Closes #139
2018-07-18 19:41:47 +12:00
Chris Wong
aadc749715
Release 0.18.0
2018-07-15 21:46:16 +12:00
Chris Wong
12282093eb
Use diagnostic API everywhere
2018-06-22 21:28:35 +12:00
Chris Wong
67b6fb05e9
Release 0.17.5
2018-05-26 11:57:51 +12:00
Chris Wong
2455de589c
Update to rustc 1.27.0-nightly (2f2a11dfc 2018-05-16)
2018-05-17 20:55:29 +12:00
Chris Wong
9d90e94c87
Change macro internals to use an explicit AST ( #127 )
2018-05-17 20:38:44 +12:00
Chris Wong
7c63fc138a
Release 0.17.4
2018-05-02 20:49:17 +12:00
Chris Stadler
e606e64ef2
Enable proc_macro_non_items feature flag
2018-04-28 12:59:24 +12:00
Chris Wong
41f7744fe1
Release 0.17.3
2018-04-21 17:20:42 +12:00
Chris Wong
dd9d892b8d
Fix up some minor issues
2018-04-16 20:29:32 +12:00
Coleman McFarland
f75da83a60
Pre-allocate sufficient size for our output String
2018-04-16 01:06:19 -07:00
Coleman McFarland
0f453a5568
Refactor to keep up with changes to proc_macro
...
Instead of a `kind` field containting a `TokenNode` variant, a
TokenTree is now an enum with variants of different types (Literal, Op,
Term, etc). Note that a TokenTree could be a sequence of TokenTrees if it is a
Group variant.
Other notes:
I'm unsure about the set_span call in Builder::emit_if, but I did not want to
throw away the passed in Span.
Parsing relies on destructuring references to the values associated with
TokenTree enum variants
It doesn't seem as easy to compose/chain TokenStreams as it is to
collect a Vec<TokenTree> into a TokenStream. There is probably some
iterator API I could use instead. See `match_arms` and build.rs
Refs #121
2018-04-12 14:19:26 -07:00
Chris Wong
62298aec55
Release 0.17.2
2017-11-19 20:12:38 +13:00
Chris Wong
cc833dd624
Update to rustc 1.23.0-nightly (6160040d8 2017-11-18)
2017-11-19 19:55:11 +13:00
Chris Wong
5cd51481c9
Rename Renderer to Builder
2017-08-12 17:41:54 +12:00
Chris Wong
9487dbc3a7
Move some code around
2017-08-12 16:21:13 +12:00
Chris Wong
080b461f1b
Release 0.17.1
2017-08-11 21:15:20 +12:00
Chris Wong
752c4805e4
Release 0.17.0
2017-08-04 22:22:38 +12:00
Chris Wong
3de5f7f3e9
Move lints into their own maud_lints crate
2017-07-30 22:18:26 +12:00
Chris Wong
2213c0dc32
Move escaping routines into a shared maud_htmlescape crate
2017-07-29 20:03:00 +12:00
Chris Wong
fd7e000cda
TokenTreeIter values can be cloned now
2017-07-29 13:24:40 +12:00
Chris Wong
e0c7fcf055
Initial stab at porting to new proc macro interface
2017-07-23 13:58:42 +12:00
Chris Wong
04eb61e870
Use docs.rs for hosting API documentation
2017-06-19 21:25:19 +12:00
Chris Wong
348712f3f4
Add #![doc(html_root_url = "...")] attribute
2017-05-13 14:16:41 +12:00
Chris Wong
dde603757d
Rename PResult
to ParseResult
2017-04-22 17:29:56 +12:00
Chris Wong
dfe721c6b7
Update to rustc 1.18.0-nightly (1785bca51 2017-04-21)
...
Closes #80
2017-04-22 17:29:56 +12:00
Chris Wong
fe08789e3f
Make PResult
type private
...
Not sure why it was public in the first place
2017-02-11 17:19:12 +13:00
Chris Wong
c849d9efdf
Use if_chain from crates.io
2016-12-29 12:20:08 +13:00
Chris Wong
f991ebaa78
Lint against PreEscaped("<!DOCTYPE html>")
...
See #66
2016-12-27 21:27:54 +13:00
Chris Wong
7f7deb7af5
Remove #![feature(question_mark)]
...
Apparently that feature is stable now
2016-10-17 21:41:33 +13:00
Chris Wong
f12efe4299
Rewrite everything to use Strings instead of writers
...
After fiddling around with zero-allocation solutions, I concluded that
all non-allocating approaches are too annoying to work with in realistic
code. Using closures leads to yak-shaving with lifetimes; and because
Iron needs to take ownership of the response body we often end up
cloning the input data anyway.
Removing this constraint has let me simplify the entire system, removing
a net 300 lines from the library. The `html!` macro no longer takes a
writer, and instead returns a `PreEscaped<String>`. This means that the
result of an `html!` can be spliced directly into another `html!`,
removing the need for the `impl Template` rigmarole.
To rub it in, benchmarks show the new code is in fact *faster* than it
was before. How lovely.
2016-09-23 19:22:22 +12:00
Chris Wong
aded75f01f
Add some juicy impl Trait
niceness
2016-08-15 20:32:39 +12:00
Chris Wong
166296db30
Update Rust
2016-07-03 16:55:45 +12:00
Chris Wong
00ec443326
Update Rust
...
rust-lang/rust#33041
2016-04-27 12:10:37 +12:00
Chris Wong
8492259638
Use the new ?
syntax (so purty)
2016-03-22 23:31:23 +13:00
Chris Wong
8d0ad20f74
Update Rust
2016-01-01 11:43:59 +13:00
Chris Wong
7cb4d61d5b
Update Rust
2015-11-28 21:15:13 +11:00
Chris Wong
05b5d099fb
Update Rust
2015-11-08 18:59:11 +13:00
Chris Wong
059b82e091
DON'T PANIC
...
Closes #22
2015-09-15 13:38:32 +12:00
Chris Wong
6030eed9f7
Rename write_html!
to html_utf8!
...
The new name makes it clear what the macro is doing: encoding the output
to UTF-8.
2015-09-12 14:21:01 +12:00
Chris Wong
ebbd5d2e54
Add a write_html!
macro
...
This handles the common case of wrapping the stream in a `Utf8Writer`.
2015-09-07 19:46:06 +12:00
Chris Wong
28b1624f4c
Rename write_html!
to html!
...
It's more concise
2015-09-03 11:06:05 +12:00
Chris Wong
1badbd9df2
De-closureify the API
...
Closes #18
2015-09-01 18:26:50 +12:00
Chris Wong
4653b2e2d8
Add html_debug! macro; remove print-expansion feature
2015-04-13 20:41:12 +12:00
Chris Wong
e5711929e3
print-expansion for all your expansion printing needs
2015-04-11 10:19:28 +12:00
Chris Wong
180becbee4
Coalesce the contents of blocks as well
2015-04-10 19:02:36 +12:00
Chris Wong
2aa687fc0f
Update Rust
2015-03-29 19:37:26 +13:00