7f9362f7b3dc815c24e0de6749478650b8e51fc3 — Jonas Platte 3 months ago 73c03c4
proc-macro-parsing: First content
1 files changed, 15 insertions(+), 1 deletions(-)

M content/2021-07-01-proc-macro-parsing.md
M content/2021-07-01-proc-macro-parsing.md => content/2021-07-01-proc-macro-parsing.md +15 -1
@@ 3,7 3,21 @@ title = "Procedural Macros: Parsing custom syntax"
draft = true

*syn parse Cargo feature*
This is the fourth article in my series about procedural macros. The examples
here are based on the ones from [the previous article][prev].

In this article, I will explain how you can use `syn` to parse things that are
not Rust code. This is required for a variety of use cases for proc-macros:

* Attributes, either standalone or as part of a derive macro: `syn` only allows
  a limited syntax for attributes if you don't use custom parsing.
* Function-like macros: ________

[prev]: /proc-macro-error-handling/

## ___First heading___

*syn parsing feature enabled by default, full feature sometimes needed*

*update example from last article to use custom parsing for attributes*