You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You can run an example based on the distillation column after cloning by typing `cargo run`.
58
+
59
+
### Is that a reinvented wheel?
60
+
61
+
Well, actually I started this project to learn about procedural macros. I learnt that the use-case I had in mind
62
+
is often not supported. At least not as a first-class citizen. What I mean is the coupling between variables, as the `feed_place < trays`
63
+
contract in the example. I also perfer the attributes to be formal mathmatical, i.e. with comparsions and boolean logic.
64
+
As I believe that is benefical from an engineers perspective.
65
+
66
+
All that said, I found the following crates that may serve your use-case better:
67
+
68
+
-[Contract](https://docs.rs/contracts/latest/contracts/) - Allows the definition of preconditions, invariants and post-conditions supporting desing by contract.
69
+
-[Validator](https://github.com/Keats/validator) - A strong input validator useful for web input, supports e-mail and credit card validators.
70
+
-[prae](https://docs.rs/prae/latest/prae/index.html) - A declarative macro that defines types that require validation. It uses closures for validation and small adjustments.
71
+
72
+
## Roadmap
73
+
74
+
I have some ideas how to continue, but I also want to get inital feedback.
75
+
76
+
- Use a composite error type to collect all invalid contracts
77
+
- Enhance the automatically generated code
78
+
- Overthink the grammar, use `&&` and `||` instead of `,` to put multiple rules in a contract.
79
+
80
+
## Contributors
81
+
82
+
The following contributors have either helped to start this project, have contributed code, are actively maintaining it (including documentation), or in other ways being awesome contributors to this project. We'd like to take a moment to recognize them.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
87
+
88
+
## License
89
+
90
+
EngCon is free, open source and permissively licensed!
91
+
Except where noted (below and/or in individual files), all code in this repository is dual-licensed under either:
92
+
93
+
* MIT License ([LICENSE-MIT](LICENSE-MIT) or [http://opensource.org/licenses/MIT](http://opensource.org/licenses/MIT))
94
+
* Apache License, Version 2.0 ([LICENSE-APACHE](LICENSE-APACHE) or [http://www.apache.org/licenses/LICENSE-2.0](http://www.apache.org/licenses/LICENSE-2.0))
95
+
96
+
at your option.
97
+
This means you can select the license you prefer!
98
+
This dual-licensing approach is the de-facto standard in the Rust ecosystem and there are [very good reasons](https://github.com/bevyengine/bevy/issues/2373) to include both.
0 commit comments