Skip to content

POD struct 初始化 #10

@wolf5x

Description

@wolf5x
struct option {
    char a[32];
    int b;
    unsigned c;
    char d;
};

int main() {
    option haha = {"aa", 1, 2, '3'}; // error
    return 0;
}

C99标准的初始化,应该支持。

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions