Skip to content

Set -funsigned-char flag when exporting to GCC #1525

Closed
@aamcampbell

Description

@aamcampbell

Here's a minor feature request for exporting to GCC and GCC-based environments (such as KDS and Atmel Studio): add the compiler flag-funsigned-char in exported projects by default.
)
The mbed handbook lists the char type as being unsigned (here), but the C standard does not specify, and in GCC chars are signed by default (see http://stackoverflow.com/a/2054959/1858923). This leads to errors when exporting projects that assume that chars are unsigned, such as Neil Thiessen's SDFileSystem. If we automatically set -funsigned-char in exported projects, we reduce the inconsistencies between the mbed online compiler and other target compilers for exported projects.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions