aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/lib.rs2
-rw-r--r--src/modelica_parser.lalrpop4
-rw-r--r--src/modelica_parser.rs10
3 files changed, 7 insertions, 9 deletions
diff --git a/src/lib.rs b/src/lib.rs
index 508eeec..c733dc7 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -26,7 +26,6 @@ pub enum ModelVarType {
Independent,
Dependent,
Constant,
- // XXX:
Time,
State,
Parameter,
@@ -48,7 +47,6 @@ pub struct ModelEntry {
pub markdown: String,
}
-// TODO: this
pub fn parse_metadata(raw: String) -> Result<ModelMetadata,String> {
let root = toml::Parser::new(&raw).parse().unwrap();
let model = root.get("model").unwrap().as_table().unwrap();
diff --git a/src/modelica_parser.lalrpop b/src/modelica_parser.lalrpop
index 6a1ceaf..f5d7958 100644
--- a/src/modelica_parser.lalrpop
+++ b/src/modelica_parser.lalrpop
@@ -1,6 +1,6 @@
use std::str::FromStr;
-// XXX: use modelica_ast::{ModelicaModel, Component, ComponentPrefix, Connection, SimpleEquation, Bin};
-use modelica_ast::*;
+use modelica_ast::{ModelicaModel,Component, ComponentPrefix, Connection,
+ SimpleEquation, Expr, BinOperator};
// This is an incomplete, non-standards-compliant, minimum-viable parser
diff --git a/src/modelica_parser.rs b/src/modelica_parser.rs
index 91e158b..d4aaf54 100644
--- a/src/modelica_parser.rs
+++ b/src/modelica_parser.rs
@@ -1,12 +1,12 @@
use std::str::FromStr;
-use modelica_ast::*;
+use modelica_ast::{ModelicaModel, Component, ComponentPrefix, Connection, SimpleEquation, Expr, BinOperator};
extern crate lalrpop_util as __lalrpop_util;
mod __parse__float {
#![allow(non_snake_case, non_camel_case_types, unused_mut, unused_variables, unused_imports)]
use std::str::FromStr;
- use modelica_ast::*;
+ use modelica_ast::{ModelicaModel, Component, ComponentPrefix, Connection, SimpleEquation, Expr, BinOperator};
extern crate lalrpop_util as __lalrpop_util;
#[allow(dead_code)]
pub enum __Symbol<'input> {
@@ -2024,7 +2024,7 @@ mod __parse__identifier {
#![allow(non_snake_case, non_camel_case_types, unused_mut, unused_variables, unused_imports)]
use std::str::FromStr;
- use modelica_ast::*;
+ use modelica_ast::{ModelicaModel, Component, ComponentPrefix, Connection, SimpleEquation, Expr, BinOperator};
extern crate lalrpop_util as __lalrpop_util;
#[allow(dead_code)]
pub enum __Symbol<'input> {
@@ -4042,7 +4042,7 @@ mod __parse__integer {
#![allow(non_snake_case, non_camel_case_types, unused_mut, unused_variables, unused_imports)]
use std::str::FromStr;
- use modelica_ast::*;
+ use modelica_ast::{ModelicaModel, Component, ComponentPrefix, Connection, SimpleEquation, Expr, BinOperator};
extern crate lalrpop_util as __lalrpop_util;
#[allow(dead_code)]
pub enum __Symbol<'input> {
@@ -6060,7 +6060,7 @@ mod __parse__model {
#![allow(non_snake_case, non_camel_case_types, unused_mut, unused_variables, unused_imports)]
use std::str::FromStr;
- use modelica_ast::*;
+ use modelica_ast::{ModelicaModel, Component, ComponentPrefix, Connection, SimpleEquation, Expr, BinOperator};
extern crate lalrpop_util as __lalrpop_util;
#[allow(dead_code)]
pub enum __Symbol<'input> {