Bug 10277 – Incorrect error file and line on redeclaration of TypeInfo

Status
RESOLVED
Resolution
FIXED
Severity
minor
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2013-06-05T12:25:00Z
Last change time
2013-09-21T09:17:08Z
Keywords
diagnostic, pull
Assigned to
nobody
Creator
robert

Comments

Comment #0 by robert — 2013-06-05T12:25:07Z
Test case: test.d: ---- class TypeInfo {} ---- test2.d: ---- import test; ---- $ dmd test2.d /usr/include/d/druntime/import/object.di(67): Error: class object.TypeInfo only object.d can define this reserved class name It should report line 1 of test2.d. $ dmd -v | head -n2 DMD64 D Compiler v2.063 Copyright (c) 1999-2012 by Digital Mars written by Walter Bright
Comment #1 by robert — 2013-06-05T12:25:58Z
The issue occurs with other reserved names such as Throwable, Exception and Error too.
Comment #2 by henning — 2013-06-12T16:25:23Z
Comment #3 by github-bugzilla — 2013-06-16T11:25:11Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/956eb92f1bc9d423480a3b708f17dc34db9d7e72 fix issue 10277 - Incorrect error file and line on redeclaration of TypeInfo https://github.com/D-Programming-Language/dmd/commit/6451593fb9bd8a718c0604cabaaf489fafd28d19 Merge pull request #2169 from hpohl/10277 fix issue 10277 - Incorrect error file and line on redeclaration of TypeInfo
Comment #4 by github-bugzilla — 2013-09-21T06:15:07Z
Commit pushed to master at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/9837043cfc75a37d4a79941cc5b401e19213088d Merge pull request #1592 from rainers/demangle_local fix issues 10277 & 6045:improve demangling for function local symbols
Comment #5 by github-bugzilla — 2013-09-21T09:17:08Z
Commit pushed to master at https://github.com/D-Programming-Language/druntime https://github.com/D-Programming-Language/druntime/commit/64ae912e8e89840a0ed14fc149c10fe6bfb8e169 Merge pull request #611 from rainers/demangle_local fix issues 10277 & 6045:improve demangling for function local symbols