Skip to main content

marauders/
lib.rs

1/// Marauders is a library and command line tool for injecting amd maintaining inline mutations in source code.
2///
3/// The tool can be used targeting singular files as well as entire projects, analyzing files to identity
4/// existing mutations, switching between them, and adding new ones.
5///
6/// The mutations use a comment-augmented syntax to identify the mutations and their variants.
7///
8/// ```rust
9/// fn add(a: i32, b: i32) -> i32 {
10///     /*| add_variation */
11///     a + b
12///     /*|| add_mutation_1 */
13///     /*|
14///     a - b
15///     */
16///     /*| add_mutation_2 */
17///     /*|
18///     a * b
19///     */
20///     /* |*/
21/// }
22/// ```
23///
24/// The users can invoke mutations by name, or a small DSL that expresses a set of mutations to apply. More details about the mutation
25/// DSL can be found in the documentation of the `algebra` module.
26/// The library is organized in the following modules:
27///
28/// * `algebra`: Contains the DSL for expressing mutations.
29pub mod algebra;
30/// * `api`: Contains the library API for programmatic access.
31pub mod api;
32pub use api::*;
33/// * `code`: Contains the way marauders handle the code it analyzes and processes.
34pub mod code;
35pub use code::*;
36/// * `languages`: Contains the language specific details for marauders supported languages.
37pub mod languages;
38pub use languages::*;
39/// * `project`: Contains the logic and structures for handling marauders projects.
40pub mod project;
41/// * `syntax`: Contains the different syntaxes for expressing mutants.
42pub mod syntax;
43pub use project::*;
44/// * `variation`: Contains the logic and structures for about variations.
45pub mod variation;
46pub use variation::*;