Skip to content
This repository has been archived by the owner on Sep 12, 2018. It is now read-only.

Expose errors in query parser #328

Closed
rnewman opened this issue Feb 17, 2017 · 0 comments
Closed

Expose errors in query parser #328

rnewman opened this issue Feb 17, 2017 · 0 comments

Comments

@rnewman
Copy link
Collaborator

rnewman commented Feb 17, 2017

We currently completely collapse errors from combine in mentat_query_parser:

#[derive(Clone, Debug, Eq, PartialEq)]
pub enum WhereParseError {
    Err,
}pub fn clause_seq_to_patterns(clauses: &[edn::Value]) -> WhereParseResult {
    Where::clauses()
        .parse(clauses)
        .map(|x| x.0)
        .map_err(|_| WhereParseError::Err)
}

After Marwes/combine#87, we'll be better able to turn these errors into something that's meaningful to propagate out of the query interface.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant