D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 22841 - importC: Error: variable 'var' is shadowing variable 'var'
Summary: importC: Error: variable 'var' is shadowing variable 'var'
Status: RESOLVED FIXED
Alias: None
Product: D
Classification: Unclassified
Component: dmd (show other issues)
Version: D2
Hardware: All All
: P1 normal
Assignee: No Owner
URL:
Keywords: ImportC, pull, rejects-valid
Depends on:
Blocks:
 
Reported: 2022-03-03 17:45 UTC by Iain Buclaw
Modified: 2022-03-03 20:46 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Iain Buclaw 2022-03-03 17:45:54 UTC
Shadowing in C11 is not forbidden, but can be warned about.

---
void test()
{
    int i;
    { unsigned i; }
}
Comment 1 Dlang Bot 2022-03-03 17:52:31 UTC
@ibuclaw created dlang/dmd pull request #13750 "fix Issue 22841 - importC: Error: variable 'var' is shadowing variable 'var'" fixing this issue:

- fix Issue 22841 - importC: Error: variable 'var' is shadowing variable 'var'

https://github.com/dlang/dmd/pull/13750
Comment 2 Dlang Bot 2022-03-03 20:46:01 UTC
dlang/dmd pull request #13750 "fix Issue 22841 - importC: Error: variable 'var' is shadowing variable 'var'" was merged into master:

- 2544758390e0f7598ac4bc1a1b1d382d790da49b by Iain Buclaw:
  fix Issue 22841 - importC: Error: variable 'var' is shadowing variable 'var'

https://github.com/dlang/dmd/pull/13750