Skip to content

Commit

Permalink
rid-derive: renamed to rid-macro
Browse files Browse the repository at this point in the history
  • Loading branch information
thlorenz committed Mar 4, 2021
1 parent d99b87d commit c6e403a
Show file tree
Hide file tree
Showing 34 changed files with 13 additions and 15 deletions.
2 changes: 1 addition & 1 deletion rid-build/fixtures/foo-bar-baz/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ name = "foo_bar_baz"
path = "main.rs"

[dependencies]
rid_derive = { path = "../../../rid-derive" }
rid_macro = { path = "../../../rid-macro" }
2 changes: 1 addition & 1 deletion rid-build/fixtures/foo-bar-baz/main.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::ffi::CString;

use rid_derive::Rid;
use rid_macro::Rid;

#[derive(Rid)]
pub struct Foo {
Expand Down
2 changes: 1 addition & 1 deletion rid-build/src/dart_generator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ pub(crate) struct DartGenerator<'a> {
pub(crate) lib_name: &'a str,

/// Content of binding.h generated by cbindgen with functions and structs expanded via
/// rid-derive.
/// rid-macro.
pub(crate) binding: &'a str,

/// Rust library to load, Release or Debug.
Expand Down
2 changes: 0 additions & 2 deletions rid-build/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#![feature(str_split_once)]

use std::{fs, path::Path};

use anyhow::Result;
Expand Down
2 changes: 1 addition & 1 deletion rid-common/src/constants.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Constants used in code generated via rid-derive and bindgen as well as the higher level dart
// Constants used in code generated via rid-macro and bindgen as well as the higher level dart
// wrapper generated by rid-build.

/// Bindings generated by ffigen are imported into the build wrapper as this id.
Expand Down
6 changes: 3 additions & 3 deletions rid-derive-test/Cargo.toml → rid-macro-test/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
[package]
name = "rid_derive_test"
name = "rid_macro_test"
version = "0.0.0"
edition = "2018"
publish = false

[workspace]

[[bin]]
name = "rid_derive_test"
name = "rid_macro_test"
path = "main.rs"

[dependencies]
rid_derive = { path = "../rid-derive" }
rid_macro = { path = "../rid-macro" }
4 changes: 2 additions & 2 deletions rid-derive-test/Makefile → rid-macro-test/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
MAIN=./main.rs
RID_DERIVES=../rid-derive/src/*.rs
RID_MACROS=../rid-macro/src/*.rs

MAIN_EXPANDED=./main-expanded.rs

Expand All @@ -17,7 +17,7 @@ bindgen: $(BINDING_C)
$(BINDING_C): $(MAIN_EXPANDED)
cbindgen -c cbindgen.toml $< -o $(BINDING_C)

$(MAIN_EXPANDED): $(MAIN) $(RID_DERIVES)
$(MAIN_EXPANDED): $(MAIN) $(RID_MACROS)
cargo expand > $@

clean:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@ includes=["stdint.h"]
[parse]
parse_deps = false
# Why does this not expand??
# cbindgen -c cbindgen.toml --crate rid-derive-ws main.rs
expand = ["rid-derive-ws"]
# cbindgen -c cbindgen.toml --crate rid-macro-ws main.rs
expand = ["rid-macro-ws"]
2 changes: 1 addition & 1 deletion rid-derive-test/main.rs → rid-macro-test/main.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::ffi::CString;

use rid_derive::Rid;
use rid_macro::Rid;

#[derive(Rid)]
pub struct Foo {
Expand Down
2 changes: 1 addition & 1 deletion rid-derive/Cargo.toml → rid-macro/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "rid_derive"
name = "rid_macro"
version = "0.1.0"
authors = ["Thorsten Lorenz <[email protected]>"]
edition = "2018"
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit c6e403a

Please sign in to comment.