-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Switch syntax parsing to texlab/pest/nom #2
Comments
syntax
crate of texlab
syntax
crate of texlab
syntax
crate of texlab
syntax
crate inside of texlab
Thanks for this suggestion; I would definitely be interested in moving the syntax parsing to a system based on |
There is the Since I've messaged you on Keybase. |
syntax
crate inside of texlab
Here's an explicit example of how this might work. use texlab::parser::parse_latex;
use texlab::syntax::latex::SyntaxNode;
fn main() {
// sample text
let text = "\
\\documentclass{article}\n\
\\begin{document}\n\
\\begin{equation}\n \
E = m c^2\n\
\\end{equation}\n\
\\end{document}";
// convert the text to a syntax tree
let tree = SyntaxNode::new_root(parse_latex(&text));
// display the syntax tree
dbg!(&tree);
// convert the syntax tree back to text
println!("{}", &tree.to_string());
} |
No description provided.
The text was updated successfully, but these errors were encountered: