colis-anr / morbig

A static parser for POSIX Shell
Other
190 stars 8 forks source link

Tilde prefixes are kept in the CST #163

Closed Niols closed 1 year ago

Niols commented 1 year ago

The Shell script:

~foo

is parsed as:

[ Simple ([], [[(WTildePrefix "~foo")]]) ]

I would not expect the ~ to be part of the string as this information is already carried by WTildePrefix. I would expect:

[ Simple ([], [[(WTildePrefix "foo")]]) ]

This is the same kind of things as https://github.com/colis-anr/morbig/pull/122 which should also be merged eventually in my opinion.