Skip to content

Commit 717b598

Browse files
winterqtgiacomocavalieri
authored andcommitted
update to glance 6.0.0
1 parent 341b358 commit 717b598

File tree

3 files changed

+22
-17
lines changed

3 files changed

+22
-17
lines changed

gleam.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ justin = ">= 1.0.1 and < 2.0.0"
1212
gleam_community_ansi = ">= 1.4.0 and < 2.0.0"
1313
argv = ">= 1.0.2 and < 2.0.0"
1414
rank = ">= 1.0.0 and < 2.0.0"
15-
glance = ">= 5.0.0 and < 6.0.0"
15+
glance = ">= 6.0.0 and < 7.0.0"
1616
filepath = ">= 1.1.0 and < 2.0.0"
1717
trie_again = ">= 1.1.2 and < 2.0.0"
1818
simplifile = ">= 2.2.0 and < 3.0.0"

manifest.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ packages = [
66
{ name = "edit_distance", version = "3.0.0", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "edit_distance", source = "hex", outer_checksum = "7DC465C34695F9E57D79FC65670C53C992CE342BF29E0AA41FF44F61AF62FC56" },
77
{ name = "envoy", version = "1.1.0", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "envoy", source = "hex", outer_checksum = "850DA9D29D2E5987735872A2B5C81035146D7FE19EFC486129E44440D03FD832" },
88
{ name = "filepath", version = "1.1.2", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "filepath", source = "hex", outer_checksum = "B06A9AF0BF10E51401D64B98E4B627F1D2E48C154967DA7AF4D0914780A6D40A" },
9-
{ name = "glance", version = "5.0.1", build_tools = ["gleam"], requirements = ["gleam_stdlib", "glexer"], otp_app = "glance", source = "hex", outer_checksum = "7F216D97935465FF4AC46699CD1C3E0FB19CB678B002E4ACAFCE256E96312F14" },
9+
{ name = "glance", version = "6.0.0", build_tools = ["gleam"], requirements = ["gleam_stdlib", "glexer"], otp_app = "glance", source = "hex", outer_checksum = "49E0ED4793BB3F56C3E5ED00528D70CAE21D263F70A735604124B95C5F62E2DB" },
1010
{ name = "gleam_community_ansi", version = "1.4.3", build_tools = ["gleam"], requirements = ["gleam_community_colour", "gleam_regexp", "gleam_stdlib"], otp_app = "gleam_community_ansi", source = "hex", outer_checksum = "8A62AE9CC6EA65BEA630D95016D6C07E4F9973565FA3D0DE68DC4200D8E0DD27" },
1111
{ name = "gleam_community_colour", version = "2.0.2", build_tools = ["gleam"], requirements = ["gleam_json", "gleam_stdlib"], otp_app = "gleam_community_colour", source = "hex", outer_checksum = "E34DD2C896AC3792151EDA939DA435FF3B69922F33415ED3C4406C932FBE9634" },
1212
{ name = "gleam_json", version = "3.0.2", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "gleam_json", source = "hex", outer_checksum = "874FA3C3BB6E22DD2BB111966BD40B3759E9094E05257899A7C08F5DE77EC049" },
@@ -19,7 +19,7 @@ packages = [
1919
{ name = "justin", version = "1.0.1", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "justin", source = "hex", outer_checksum = "7FA0C6DB78640C6DC5FBFD59BF3456009F3F8B485BF6825E97E1EB44E9A1E2CD" },
2020
{ name = "rank", version = "1.0.0", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "rank", source = "hex", outer_checksum = "5660E361F0E49CBB714CC57CC4C89C63415D8986F05B2DA0C719D5642FAD91C9" },
2121
{ name = "simplifile", version = "2.3.0", build_tools = ["gleam"], requirements = ["filepath", "gleam_stdlib"], otp_app = "simplifile", source = "hex", outer_checksum = "0A868DAC6063D9E983477981839810DC2E553285AB4588B87E3E9C96A7FB4CB4" },
22-
{ name = "splitter", version = "1.1.0", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "splitter", source = "hex", outer_checksum = "05564A381580395DCDEFF4F88A64B021E8DAFA6540AE99B4623962F52976AA9D" },
22+
{ name = "splitter", version = "1.2.0", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "splitter", source = "hex", outer_checksum = "3DFD6B6C49E61EDAF6F7B27A42054A17CFF6CA2135FF553D0CB61C234D281DD0" },
2323
{ name = "term_size", version = "1.0.1", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "term_size", source = "hex", outer_checksum = "D00BD2BC8FB3EBB7E6AE076F3F1FF2AC9D5ED1805F004D0896C784D06C6645F1" },
2424
{ name = "tom", version = "2.0.0", build_tools = ["gleam"], requirements = ["gleam_stdlib", "gleam_time"], otp_app = "tom", source = "hex", outer_checksum = "74D0C5A3761F7A7D06994755D4D5AD854122EF8E9F9F76A3E7547606D8C77091" },
2525
{ name = "trie_again", version = "1.1.4", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "trie_again", source = "hex", outer_checksum = "E3BD66B4E126EF567EA8C4944EAB216413392ADF6C16C36047AF79EE5EF13466" },
@@ -30,7 +30,7 @@ argv = { version = ">= 1.0.2 and < 2.0.0" }
3030
edit_distance = { version = ">= 3.0.0 and < 4.0.0" }
3131
envoy = { version = ">= 1.1.0 and < 2.0.0" }
3232
filepath = { version = ">= 1.1.0 and < 2.0.0" }
33-
glance = { version = ">= 5.0.0 and < 6.0.0" }
33+
glance = { version = ">= 6.0.0 and < 7.0.0" }
3434
gleam_community_ansi = { version = ">= 1.4.0 and < 2.0.0" }
3535
gleam_stdlib = { version = ">= 0.43.0 and < 1.0.0" }
3636
gleeunit = { version = ">= 1.2.0 and < 2.0.0" }

src/birdie/internal/titles.gleam

Lines changed: 18 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ fn snap_call(
238238
function:,
239239
arguments: [
240240
glance.UnlabelledField(title),
241-
glance.LabelledField("content", _snapshot_content),
241+
glance.LabelledField("content", _location, _snapshot_content),
242242
],
243243
)
244244
| // A direct function call to the `birdie.snap` function where the first
@@ -257,7 +257,7 @@ fn snap_call(
257257
function:,
258258
arguments: [
259259
glance.UnlabelledField(_snapshot_content),
260-
glance.LabelledField("title", title),
260+
glance.LabelledField("title", _location, title),
261261
],
262262
)
263263
| // A direct function call to the `birdie.snap` function where the first
@@ -267,24 +267,27 @@ fn snap_call(
267267
location: _,
268268
function:,
269269
arguments: [
270-
glance.LabelledField("content", _snapshot_content),
270+
glance.LabelledField("content", _location, _snapshot_content),
271271
glance.UnlabelledField(title),
272272
],
273273
)
274274
| glance.Call(
275275
location: _,
276276
function:,
277277
arguments: [
278-
glance.LabelledField("content", _snapshot_content),
279-
glance.LabelledField("title", title),
278+
glance.LabelledField("content", _location, _snapshot_content),
279+
glance.LabelledField("title", _location, title),
280280
],
281281
)
282282
| // A direct function call to the `birdie.snap` function where the first
283283
// argument is the labelled title.
284284
glance.Call(
285285
location: _,
286286
function:,
287-
arguments: [glance.LabelledField("title", title), _content_field],
287+
arguments: [
288+
glance.LabelledField("title", _location, title),
289+
_content_field,
290+
],
288291
)
289292
| // A call to the `birdie.snap` function where the title is piped into it
290293
// and the content is passed as a labelled argument.
@@ -295,7 +298,9 @@ fn snap_call(
295298
right: glance.Call(
296299
location: _,
297300
function:,
298-
arguments: [glance.LabelledField("content", _snapshot_content)],
301+
arguments: [
302+
glance.LabelledField("content", _location, _snapshot_content),
303+
],
299304
),
300305
)
301306
| // A call to the `birdie.snap` function where the content is piped into
@@ -317,7 +322,7 @@ fn snap_call(
317322
right: glance.Call(
318323
location: _,
319324
function:,
320-
arguments: [glance.LabelledField("title", title)],
325+
arguments: [glance.LabelledField("title", _location, title)],
321326
),
322327
)
323328
| // We pipe into `title: _`, since we're using a label we don't have to
@@ -440,11 +445,11 @@ fn try_fold_expression(
440445
| glance.Variable(_, _)
441446
| glance.Panic(_, _)
442447
| glance.Todo(_, _)
443-
| glance.Echo(_, None) -> Ok(acc)
448+
| glance.Echo(_, None, _) -> Ok(acc)
444449

445450
glance.NegateInt(_location, expression)
446451
| glance.NegateBool(_location, expression)
447-
| glance.Echo(_location, Some(expression))
452+
| glance.Echo(_location, Some(expression), _message)
448453
| glance.FieldAccess(location: _, container: expression, label: _)
449454
| glance.TupleIndex(location: _, tuple: expression, index: _) ->
450455
try_fold_expression(expression, acc, fun)
@@ -527,9 +532,9 @@ fn try_fold_fields(
527532
) -> Result(a, b) {
528533
use acc, field <- list.try_fold(over: fields, from: acc)
529534
case field {
530-
glance.LabelledField(label: _, item:) | glance.UnlabelledField(item:) ->
531-
try_fold_expression(item, acc, fun)
532-
glance.ShorthandField(label: _) -> Ok(acc)
535+
glance.LabelledField(label: _, label_location: _, item:)
536+
| glance.UnlabelledField(item:) -> try_fold_expression(item, acc, fun)
537+
glance.ShorthandField(label: _, location: _) -> Ok(acc)
533538
}
534539
}
535540

0 commit comments

Comments
 (0)