Skip to content

Commit

Permalink
make cuchar alias uint8 instead of char (#17738)
Browse files Browse the repository at this point in the history
  • Loading branch information
shirleyquirk authored Apr 17, 2021
1 parent 8e124da commit c8b8cb8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

## Changes affecting backward compatibility

- `cuchar` now aliases `uint8` instead of `char`

- `repr` now doesn't insert trailing newline; previous behavior was very inconsistent,
see #16034. Use `-d:nimLegacyReprWithNewline` for previous behavior.

Expand Down
2 changes: 1 addition & 1 deletion lib/system.nim
Original file line number Diff line number Diff line change
Expand Up @@ -1452,7 +1452,7 @@ type # these work for most platforms:
## This is the same as the type `long double` in *C*.
## This C type is not supported by Nim's code generator.

cuchar* {.importc: "unsigned char", nodecl.} = char
cuchar* {.importc: "unsigned char", nodecl.} = uint8
## This is the same as the type `unsigned char` in *C*.
cushort* {.importc: "unsigned short", nodecl.} = uint16
## This is the same as the type `unsigned short` in *C*.
Expand Down

0 comments on commit c8b8cb8

Please sign in to comment.