Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.
Sign upRange operator with char returns unexpected value #5731
Comments
iSazonov
added
Area-Language
Issue-Bug
labels
Dec 21, 2017
iSazonov
self-assigned this
Dec 26, 2017
This comment has been minimized.
This comment has been minimized.
FireInWinter
commented
Jan 3, 2018
|
Oddly the actual behavior matches Windows PowerShell results. So changing this might break a few scripts that otherwise might work when on PowerShell 6. |
This comment has been minimized.
This comment has been minimized.
|
@FireInWinter Thanks! I'll label the fix as Breaking change. |
iSazonov
added
the
Breaking-Change
label
Jan 4, 2018
This comment has been minimized.
This comment has been minimized.
nightroman
commented
Jan 4, 2018
•
|
Is it a bug at all? The operator casts operands to integers and then increments. The result is integers. This looks fine (to me). What about |
This comment has been minimized.
This comment has been minimized.
|
It is bug for PowerShell Core not for Windows PowerShell. Windows PowerShell support only [Int]. PowerShell Core support [char]. |


stknohg commentedDec 21, 2017
Steps to reproduce
Expected behavior
# Char array ([char]'a', [char]'b', [char]'c', [char]'d', [char]'e') a b c d eActual behavior
Environment data