Skip to content

Improve handling of variables with different storage spec #4355

@llvmbot

Description

@llvmbot
Bugzilla Link 3983
Resolution FIXED
Resolved on Jun 21, 2012 16:31
Version unspecified
OS All
Reporter LLVM Bugzilla Contributor

Extended Description

This seems wrong, and the diagnostics could be nicer (see gcc):

void f0() {
// FIXME: Diagnose this?
int g6;
extern int g6;
}

void f1() {
// FIXME: Diagnose this?
int g7;
private_extern int g7;
}

void f2() {
extern int g8; // expected-note{{previous definition}}
// FIXME: Improve this diagnostic.
int g8; // expected-error{{redefinition of 'g8'}}
}

void f3() {
private_extern int g9; // expected-note{{previous definition}}
// FIXME: Improve this diagnostic.
int g9; // expected-error{{redefinition of 'g9'}}
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugzillaIssues migrated from bugzillaclang:frontendLanguage frontend issues, e.g. anything involving "Sema"

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions