1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-11-19 12:20:52 +01:00

33793: add 0b binary interpretation to integer constants

This commit is contained in:
Peter Stephenson 2014-11-26 17:26:58 +00:00
parent c4110f7f4e
commit a8927bf27b
4 changed files with 13 additions and 3 deletions

View file

@ -2082,6 +2082,8 @@ zstrtol_underscore(const char *s, char **t, int base, int underscore)
base = 10;
else if (*++s == 'x' || *s == 'X')
base = 16, s++;
else if (*s == 'b' || *s == 'B')
base = 2, s++;
else
base = 8;
}