Skip to content

Commit

Permalink
Use SPDX license format and update some formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
atouchet committed Dec 17, 2022
1 parent fb8a49a commit 9296584
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ name = "proc-macro-crate"
version = "1.2.1"
authors = ["Bastian Köcher <[email protected]>"]
edition = "2018"
categories = [ "development-tools::procedural-macro-helpers" ]
categories = ["development-tools::procedural-macro-helpers"]
documentation = "https://docs.rs/proc-macro-crate"
repository = "https://github.com/bkchr/proc-macro-crate"
keywords = [ "macro-rules", "crate", "macro", "proc-macro" ]
license = "Apache-2.0/MIT"
keywords = ["macro-rules", "crate", "macro", "proc-macro"]
license = "MIT OR Apache-2.0"
description = """
Replacement for crate (macro_rules keyword) in proc-macros
"""
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# proc-macro-crate


[![](https://docs.rs/proc-macro-crate/badge.svg)](https://docs.rs/proc-macro-crate/) [![](https://img.shields.io/crates/v/proc-macro-crate.svg)](https://crates.io/crates/proc-macro-crate) [![](https://img.shields.io/crates/d/proc-macro-crate.png)](https://crates.io/crates/proc-macro-crate) [![Build Status](https://travis-ci.org/bkchr/proc-macro-crate.png?branch=master)](https://travis-ci.org/bkchr/proc-macro-crate)
[![](https://docs.rs/proc-macro-crate/badge.svg)](https://docs.rs/proc-macro-crate) [![](https://img.shields.io/crates/v/proc-macro-crate.svg)](https://crates.io/crates/proc-macro-crate) [![](https://img.shields.io/crates/d/proc-macro-crate.svg)](https://crates.io/crates/proc-macro-crate) [![Build Status](https://travis-ci.org/bkchr/proc-macro-crate.svg?branch=master)](https://travis-ci.org/bkchr/proc-macro-crate)

Providing support for `$crate` in procedural macros.

Expand All @@ -13,7 +13,7 @@ Providing support for `$crate` in procedural macros.

In `macro_rules!` `$crate` is used to get the path of the crate where a macro is declared in. In
procedural macros there is currently no easy way to get this path. A common hack is to import the
desired crate with a know name and use this. However, with rust edition 2018 and dropping
desired crate with a know name and use this. However, with Rust edition 2018 and dropping
`extern crate` declarations from `lib.rs`, people start to rename crates in `Cargo.toml` directly.
However, this breaks importing the crate, as the proc-macro developer does not know the renamed
name of the crate that should be imported.
Expand Down Expand Up @@ -49,9 +49,9 @@ fn import_my_crate() {

Licensed under either of

* [Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0)
* [Apache License, Version 2.0](https://www.apache.org/licenses/LICENSE-2.0)

* [MIT license](http://opensource.org/licenses/MIT)
* [MIT license](https://opensource.org/licenses/MIT)

at your option.

Expand Down

0 comments on commit 9296584

Please sign in to comment.