Skip to content

Commit

Permalink
update stdlib dep
Browse files Browse the repository at this point in the history
  • Loading branch information
bcpeinhardt committed Feb 1, 2024
1 parent 44206aa commit a75bfa3
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

## Unreleased

## v1.3.1 - 1 February 2024
- Update to gleam_stdlib = "~> 0.34 or ~> 1.0" in preparation for 1.0

## v1.2.1 - 5 January 2024
- Fix bug with double commas producing error, now produce empty string

Expand Down
4 changes: 2 additions & 2 deletions gleam.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name = "gsv"
version = "1.2.1"
version = "1.3.1"
gleam = ">= 0.32.0"
description = "A simple csv parser and generator written in gleam "

Expand All @@ -12,7 +12,7 @@ internal_modules = [
]

[dependencies]
gleam_stdlib = "~> 0.28"
gleam_stdlib = "~> 0.34 or ~> 1.0"

[dev-dependencies]
gleeunit = "~> 1.0"
2 changes: 1 addition & 1 deletion manifest.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ packages = [
]

[requirements]
gleam_stdlib = { version = "~> 0.28" }
gleam_stdlib = { version = "~> 0.34 or ~> 1.0" }
gleeunit = { version = "~> 1.0" }
13 changes: 5 additions & 8 deletions src/gsv/internal/ast.gleam
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,7 @@ fn parse_p(
[#(tok, loc), ..], Beginning, _ ->
Error(ParseError(
loc,
"Unexpected start to csv content: "
<> token.to_lexeme(tok),
"Unexpected start to csv content: " <> token.to_lexeme(tok),
))

// If we just parsed a field, we're expecting either a comma or a CRLF
Expand All @@ -78,8 +77,7 @@ fn parse_p(
[#(tok, loc), ..], JustParsedField, _ ->
Error(ParseError(
loc,
"Expected comma or newline after field, found: "
<> token.to_lexeme(tok),
"Expected comma or newline after field, found: " <> token.to_lexeme(tok),
))

// If we just parsed a CR, we're expecting an LF
Expand All @@ -89,8 +87,7 @@ fn parse_p(
[#(tok, loc), ..], JustParsedCR, _ ->
Error(ParseError(
loc,
"Expected \"\\n\" after \"\\r\", found: "
<> token.to_lexeme(tok),
"Expected \"\\n\" after \"\\r\", found: " <> token.to_lexeme(tok),
))

// If we just parsed a comma, we're expecting an Escaped or Non-Escaped string, or another comma
Expand Down Expand Up @@ -126,7 +123,7 @@ fn parse_p(
Error(ParseError(
loc,
"Expected escaped or non-escaped string after comma, found: "
<> token.to_lexeme(tok),
<> token.to_lexeme(tok),
))

// If we just parsed a new line, we're expecting an escaped or non-escaped string
Expand All @@ -146,7 +143,7 @@ fn parse_p(
Error(ParseError(
loc,
"Expected escaped or non-escaped string after newline, found: "
<> token.to_lexeme(tok),
<> token.to_lexeme(tok),
))

// If we're inside an escaped string, we can take anything until we get a double quote,
Expand Down

0 comments on commit a75bfa3

Please sign in to comment.