Skip to content

C99 "compound literals are not allowed" is shown sometimes #1313

@Yanpas

Description

@Yanpas
  • Operating System : Linux Ubuntu
  • VS Code version 1.18.1
  • C/C++ extension version 0.14.3

Sampel code:

struct Foo {
	int a,b;
};

void foo(struct Foo* f) {
	//struct Foo f = {.a = 1};
	foo(&(struct Foo){.a=1});
        /* Sometimes " a compound literal of type "struct Foo" is not allowed" is shown */
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    Language ServicebugfixedCheck the Milestone for the release in which the fix is or will be available.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions