Jump to page: 1 2
Thread overview
[Issue 107] Wrong filename in error message when using a mixin
Apr 27, 2007
d-bugmail
Jun 01, 2008
d-bugmail
Jun 01, 2008
d-bugmail
Nov 26, 2010
Leandro Lucarella
Nov 26, 2010
Leandro Lucarella
Jan 18, 2012
Leandro Lucarella
Jan 18, 2012
Leandro Lucarella
Jan 18, 2012
Walter Bright
Jan 19, 2012
Leandro Lucarella
April 27, 2007
http://d.puremagic.com/issues/show_bug.cgi?id=107


thomas-dloop@kuehne.cn changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         OS/Version|Linux                       |All




------- Comment #2 from thomas-dloop@kuehne.cn  2007-04-27 12:37 -------
DMD-1.013 uses the correct file but the wrong line number


-- 

June 01, 2008
http://d.puremagic.com/issues/show_bug.cgi?id=107





------- Comment #3 from diggory.hardy@gmail.com  2008-06-01 10:29 -------
Using dmd 1.030 I got errors like this with mixins and templates (in different
files):

(4): Error: ...
(5): Error: ...

I.e. no filename and wrong line numbers (no where near relevent lines in either file but the errors appear on lines 5 & 6 of the mixin string).


-- 

June 01, 2008
http://d.puremagic.com/issues/show_bug.cgi?id=107





------- Comment #4 from shro8822@vandals.uidaho.edu  2008-06-01 12:12 -------

As to the file name, this is not a bug (maybe a miss-feature). The actual file name can't be used as this will result in totally bogus error messages. What would be preferred would be something like the enclosing file suffixed with the line number of the mixin. It would make a good feature request though.

As to the line number, I'd say that using zero based indexing in mixins IS a bug.


-- 

November 26, 2010
http://d.puremagic.com/issues/show_bug.cgi?id=107


Andrei Alexandrescu <andrei@metalanguage.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |andrei@metalanguage.com
         Resolution|                            |FIXED


--- Comment #5 from Andrei Alexandrescu <andrei@metalanguage.com> 2010-11-26 10:03:49 PST ---
Could not reproduce on dmd 2.050, it probably was fixed a few releases ago for both D1 and D2.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
November 26, 2010
http://d.puremagic.com/issues/show_bug.cgi?id=107


Leandro Lucarella <llucax@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
                 CC|                            |llucax@gmail.com
         Resolution|FIXED                       |


--- Comment #6 from Leandro Lucarella <llucax@gmail.com> 2010-11-26 11:03:32 PST ---
luca@homero:/tmp/dmd/dmd$ cat -n mixin_21_A.d
     1  // $HeadURL: http://dstress.kuehne.cn/compile/m/mixin_21_A.d $
     2  // $Date: 2006-12-31 20:58:06 +0100 (Sun, 31 Dec 2006) $
     3  // $Author: thomask $
     4
     5  // @author@     <benoit@tionex.de>
     6  // @date@       2006-04-15
     7  // @uri@        http://d.puremagic.com/issues/show_bug.cgi?id=107
     8
     9  module mixin_21_A;
    10
    11  template T(){
    12          UNDEFINED x;
    13  }
    14
luca@homero:/tmp/dmd/dmd$ cat -n mixin_21_B.d
     1  // $HeadURL: http://dstress.kuehne.cn/nocompile/m/mixin_21_B.d $
     2  // $Date: 2006-12-31 20:58:06 +0100 (Sun, 31 Dec 2006) $
     3  // $Author: thomask $
     4
     5  // @author@     <benoit@tionex.de>
     6  // @date@       2006-04-15
     7  // @uri@        http://d.puremagic.com/issues/show_bug.cgi?id=107
     8
     9  // __DSTRESS_ELINE__ 15
    10
    11  module mixin_21_B;
    12
    13  import mixin_21_A;
    14
    15  mixin T!();
    16
luca@homero:/tmp/dmd/dmd$ ./linux/bin/dmd -c mixin_21_B.d
mixin_21_A.d(12): Error: identifier 'UNDEFINED' is not defined
mixin_21_A.d(12): Error: UNDEFINED is used as a type
mixin_21_B.d(12): Error: variable mixin_21_B.T!().x voids have no value
mixin_21_B.d(15): Error: mixin mixin_21_B.T!() error instantiating
luca@homero:/tmp/dmd/dmd$ ./linux/bin/dmd | head -n 1
Digital Mars D Compiler v1.065

Note that the 3er error is WRONG (line 12 in mixin_21_B.d is blank)


Andrei, this is the second bug you close that is NOT fixed. PLEASE, PLEASE, be a little more careful testing the bugs before you close them. It's not very serious, really.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
November 26, 2010
http://d.puremagic.com/issues/show_bug.cgi?id=107


Andrei Alexandrescu <andrei@metalanguage.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|0.150                       |D1


--- Comment #7 from Andrei Alexandrescu <andrei@metalanguage.com> 2010-11-26 11:11:20 PST ---
Marking as a D1 only issue. Sorry for not testing with D1 too; I wrongly assumed that most bugs will get fixed simultaneously on D1 and D2.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
November 26, 2010
http://d.puremagic.com/issues/show_bug.cgi?id=107



--- Comment #8 from Leandro Lucarella <llucax@gmail.com> 2010-11-26 11:17:36 PST ---
(In reply to comment #7)
> Marking as a D1 only issue. Sorry for not testing with D1 too; I wrongly assumed that most bugs will get fixed simultaneously on D1 and D2.

OK, I confirmed this one is really D1 only :)

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
November 26, 2010
http://d.puremagic.com/issues/show_bug.cgi?id=107


Andrei Alexandrescu <andrei@metalanguage.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |ASSIGNED
         AssignedTo|nobody@puremagic.com        |bugzilla@digitalmars.com


--- Comment #9 from Andrei Alexandrescu <andrei@metalanguage.com> 2010-11-26 11:22:29 PST ---
Assigning to Walter.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
January 18, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=107



--- Comment #10 from Leandro Lucarella <leandro.lucarella@sociomantic.com> 2012-01-18 09:32:34 PST ---
Works now on DMD 1.071. If it work with the current version too tests should be added to the test suit and the bug can be closed.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
January 18, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=107



--- Comment #11 from Leandro Lucarella <leandro.lucarella@sociomantic.com> 2012-01-18 09:33:52 PST ---
(In reply to comment #10)
> Works now on DMD 1.071. If it work with the current version too tests should be added to the test suit and the bug can be closed.

BTW, this is the error message I get, line numbers and files look good:

mixin_21_A.d(12): Error: undefined identifier UNDEFINED
mixin_21_B.d(15): Error: mixin mixin_21_B.T!() error instantiating

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
« First   ‹ Prev
1 2