-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #124 from niklasdewally/pr/refactor-crates-for-macros
Refactor central ADTs into a core module for modularity
- Loading branch information
Showing
16 changed files
with
71 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
"rust": { | ||
{ | ||
"rust-analyzer.check.command": "check", | ||
"editor.defaultFormatter": "rust-lang.rust-analyzer", | ||
"editor.formatOnSave": true | ||
"editor.formatOnSave": true, | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
pub mod ast; | ||
pub mod error; | ||
pub mod find_conjure; | ||
pub mod parse; | ||
mod solvers; | ||
|
||
pub use ast::Model; | ||
pub use conjure_core::ast; // re-export core::ast as conjure_oxide::ast | ||
pub use conjure_core::ast::Model; // rexport core::ast::Model as conjure_oxide::Model | ||
pub use conjure_core::solvers::Solver; | ||
|
||
pub use error::Error; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,11 @@ | ||
mod error; | ||
pub mod minion; | ||
pub use crate::ast::Model; | ||
pub use error::*; | ||
mod solver_list; | ||
pub use solver_list::*; | ||
|
||
pub trait FromConjureModel | ||
where | ||
Self: Sized, | ||
{ | ||
fn from_conjure(model: Model) -> Result<Self, SolverError>; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
[package] | ||
name = "conjure_core" | ||
version = "0.0.1" | ||
edition = "2021" | ||
|
||
[dependencies] | ||
serde = { version = "1.0.192", features = ["derive"] } | ||
serde_json = "1.0.108" | ||
serde_with = "3.4.0" | ||
strum = "0.25.0" | ||
strum_macros = "0.25.3" | ||
thiserror = "1.0.50" | ||
|
||
[lints] | ||
workspace = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
Core datatypes for use in Conjure Oxide. | ||
|
||
This crate is internal to conjure_oxide, and should not be treated as a stable | ||
API. Relevant types are re-exported through conjure_oxide. |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
pub mod ast; | ||
|
||
pub mod solvers; | ||
pub use solvers::Solver; |
File renamed without changes.