theimpossibleastronaut / configster

Rust library for parsing configuration files

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

When "InvalidOption" is assigned, also show line number

andy5995 opened this issue · comments

I think it would be a worthwhile improvement if the line number were added to "InvalidOption", such as "InvalidOptionLnn" or "InvalidOptionLine_nn".

configster/src/lib.rs

Lines 139 to 140 in 96ab97d

if c.is_whitespace() {
option = "InvalidOption".to_string();

configster/src/lib.rs

Lines 95 to 96 in 96ab97d

// for (line, index) in reader.lines().enumerate() {
for line in reader.lines() {