# stage\{1,2\}: Fix parsing of range literals · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/5c6cd5e2c9e8b2d0feb0026bad7c201035a175b4)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 5c6cd5e2c9e8b2d0feb0026bad7c201035a175b4

Requested commit: 5c6cd5e2c9e8b2d0feb0026bad7c201035a175b4

Commit: 5c6cd5e2c9e8b2d0feb0026bad7c201035a175b4

Tree: 78552e0b970107df097bc7699e0be5996aa2831b

Author: LemonBoy

Committer: Andrew Kelley

## Message

```
stage{1,2}: Fix parsing of range literals

stage1 was unable to parse ranges whose starting point was written in
binary/octal as the first dot in '...' was incorrectly interpreted as
decimal point.

stage2 forgot to reset the literal type to IntegerLiteral when it
discovered the dot was not a decimal point.

I've only stumbled across this bug because zig fmt keeps formatting the
ranges without any space around the ...

```

## Parents

- [e60939bfaafc9e6b3ccdc172009b950fc7a3eab1](https://git.cafe/gitcafe/zig/commit/e60939bfaafc9e6b3ccdc172009b950fc7a3eab1?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/5c6cd5e2c9e8b2d0feb0026bad7c201035a175b4?format=markdown)
