Skip to content

Commit

Permalink
Add descriptions to samples mod_interface*
Browse files Browse the repository at this point in the history
  • Loading branch information
dmvict committed Aug 1, 2022
1 parent a821618 commit 1e490a8
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 3 deletions.
4 changes: 2 additions & 2 deletions rust/impl/meta/mod_interface/meta/impls.rs
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,7 @@ pub mod prelude
};
}

// qqq : for Dima : rewrite sample for the module
// qqq : for Dima : write description for the module, it should have
// qqq : for Dima : rewrite sample for the module /* aaa : Dmytro : added new samples */
// qqq : for Dima : write description for the module, it should have /* aaa : Dmytro : added */
// - example based on simpified version of test::layer_have_layer with single sublayer
// - example with attribute `#![ debug ]`
6 changes: 6 additions & 0 deletions sample/rust/mod_interface_trivial_sample/Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,9 @@
[![discord](https://img.shields.io/discord/872391416519737405?color=eee&logo=discord&logoColor=eee&label=ask)](https://discord.gg/m3YfbXpUUY)
[![Open in Gitpod](https://raster.shields.io/static/v1?label=try&message=online&color=eee&logo=gitpod&logoColor=eee)](https://gitpod.io/#RUN_PATH=sample%2Frust%2Fmod_interface_trivial_sample,SAMPLE_FILE=.%2Fsrc%2Fmain.rs/https://github.com/Wandalen/wTools)
[![docs.rs](https://raster.shields.io/static/v1?label=docs&message=online&color=eee&logo=docsdotrs&logoColor=eee)](https://docs.rs/mod_interface)

A sample demonstrates basic usage of macro `mod_interface`.

In file `inner.rs` demonstrated how to generate module interface from namespace `private` and its public routine.

In file `main.rs` demonstrated how to generate module interface from layer ( file with full module interface ).
10 changes: 9 additions & 1 deletion sample/rust/mod_interface_with_debug_sample/Readme.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Sample

[![discord](https://img.shields.io/discord/872391416519737405?color=eee&logo=discord&logoColor=eee&label=ask)](https://discord.gg/m3YfbXpUUY)
[![Open in Gitpod](https://raster.shields.io/static/v1?label=try&message=online&color=eee&logo=gitpod&logoColor=eee)](https://gitpod.io/#RUN_PATH=sample%2Frust%2Fmod_interface_trivial_sample,SAMPLE_FILE=.%2Fsrc%2Fmain.rs/https://github.com/Wandalen/wTools)
[![Open in Gitpod](https://raster.shields.io/static/v1?label=try&message=online&color=eee&logo=gitpod&logoColor=eee)](https://gitpod.io/#RUN_PATH=sample%2Frust%2Fmod_interface_with_debug_sample,SAMPLE_FILE=.%2Fsrc%2Fmain.rs/https://github.com/Wandalen/wTools)
[![docs.rs](https://raster.shields.io/static/v1?label=docs&message=online&color=eee&logo=docsdotrs&logoColor=eee)](https://docs.rs/mod_interface)

A sample demonstrates basic usage of macro `mod_interface`.

In file `inner.rs` demonstrated how to generate module interface from namespace `private` and its public routine.

In file `main.rs` demonstrated how to generate module interface from layer ( file with full module interface ).

The directive `#![ debug ]` in declaration of macro `mod_interface` allow to show generated module interface as the standard output in compile time.

0 comments on commit 1e490a8

Please sign in to comment.