Skip to content

Commit

Permalink
todo for __slice deprecation
Browse files Browse the repository at this point in the history
  • Loading branch information
xunilrj committed Jul 31, 2024
1 parent 69bea71 commit 8d2dc05
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sway-parse/src/ty/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ impl Parse for Ty {
return Ok(Ty::Ptr { ptr_token, ty });
}

// slice like __slice[ty]
// slice like __slice[type]
// TODO: deprecate this syntax (see https://github.com/FuelLabs/sway/issues/5110)
if let Some(slice_token) = parser.take::<SliceToken>() {
let ty = SquareBrackets::<Box<Ty>>::parse_all_inner(parser, |mut parser| {
parser.emit_error(ParseErrorKind::UnexpectedTokenAfterSliceType)
Expand Down

0 comments on commit 8d2dc05

Please sign in to comment.