It's the first time I have used a parser combinator, so maybe I just have a misunderstanding about how I should use a parser combinator. I have the f ...
It's the first time I have used a parser combinator, so maybe I just have a misunderstanding about how I should use a parser combinator. I have the f ...
I have a Nom parser that parses strings but fails on keywords. The parser below correctly fails when given a keyword. But the error message that say ...
I have a small parser that fails if the number it parses is out of bounds, (See on playground.) But I'd like for the error to be more meaningful. ...
From input "\"Name 1\" something else" I want to extract "Name 1" and the remaining string as " something else". Notice the escaped \". My current so ...
Just started to use the crate nom. Tried the simplest example: Additionally, if I include sign, things are getting more complicated: It looks li ...
I'm writing a parser using nom library in rust. When using tuple I encounter a problem. This snippet works fine: use std::str; use nom::bytes::compl ...
So I'm trying to port a parser written in Javascript with parsimmon. In the parser I feed a string source input and get tokens. A token is simply an o ...
I am trying to write a parser using the nom crate (and the nom_locate) that can parse strings such as u{12a}, i.e.: I wrote the following parser co ...
Currently i have 2 methods: parse_int and parse_string. They return either one number or one string, respectively. For example, if i have the parser t ...
In an attempt to write a parser in rust using nom. I ran into this error Fair enough, I got this to compile and return what I need it to by changin ...
If I want to write a nom parser that could fail internally, how do I propagate the error? As an example, something to parse a NaiveDate might look li ...
I am trying to parse using nom with nom_locate, following this tutorial. I only want output in the format: But currently I get: Relevant code: ...
After trying some tree structures in Rust, I finally decided to built up a linearized tree, e.g. something like struct AST { exprs: Vec<Expr> ...
I'm using nom. I'd like to parse a string that's surrounded by parentheses, and allowing for additional nested parentheses within the string. So (a + ...
I'd like to parse both of these with nom: Currently I have this code which parses the first but not the second (the first function is a recipe fr ...
It's easy to use nom to parse a string until a character is found. How to use nom to gobble a string until a delimiter or the end? deals with this. H ...
I have this test with nom version 7.1: Running cargo test gives error[E0283]: type annotations needed --> src/main.rs:5:18 | 5 | let ...
I am using Nom, the parser combinator, to write a TOML parser. The parser function I am having trouble with parses a date time string using the chrono ...
I have written the following silly nom parser code: use nom::character::complete::digit1; use nom::combinator::map_res; use nom::error::Error; use no ...
I'm having a hard time finding any useful examples of how to use nom to parse a binary file, since it seems that the documentation is heavily biased t ...