* Implement pretty printing
Signed-off-by: Victor Porof <victor.porof@gmail.com>
* Rewrite pretty printing.
This does a few things. First, it use pretty.rs directly, without the
layer of macro obfuscation. The code is significantly simpler as a
result.
Second, it tightens the layout, using pretty.rs to group nested
layouts that fit on a single line. This is Clojure's EDN style, more
or less.
Third, it drops "special format" support for queries. This wasn't
completely implemented; if we want it, we can newtype
Query(edn::Value) and figure out how to really implement this idea.
* Rename to reflect functionality.
* Make write interface more Rust-like.
There isn't a clear standard in the stdlib, but a function that takes
ownership of a writer and then returns it back is definitely not
Rust-like. That's what a (mutable) reference is for.
* Review comment: Use as_ref to avoid cloning strings.
* Post: Fix tests to use `without_spans()`.
* Make Variable::from_symbol public.
* Implement basic parsing of queries.
* Use pinned dependencies the hard way to fix Travis.
* Bump ordered-float dependency to 0.4.0.
* Error coercions to use ?, and finishing the find interface.
The parser mostly works and has a decent test suite. It parses all the
queries issued by the Tofino UAS, with some caveats. Known flaws:
* No support for tagged elements, comments, discarded elements or "'".
* Incomplete support for escaped characters in strings and the range of
characters that are allowed in keywords and symbols.
* Possible whitespace handling problems.