Thread overview
[Issue 3466] New: Wrong JSON output for templated classes and structs
[Issue 3466] Wrong JSON output for templated classes, structs, and interfaces
Jul 03, 2010
Simen Kjaeraas
Mar 14, 2012
Matt Peterson
Jan 20, 2013
Walter Bright
Jan 20, 2013
Walter Bright
November 02, 2009
http://d.puremagic.com/issues/show_bug.cgi?id=3466

           Summary: Wrong JSON output for templated classes and structs
           Product: D
           Version: 2.035
          Platform: Other
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody@puremagic.com
        ReportedBy: bugzilla@kyllingen.net


--- Comment #0 from Lars T. Kyllingstad <bugzilla@kyllingen.net> 2009-11-02 01:21:50 PST ---
test.d:

  module test;
  struct Foo(T) { T t; }
  class  Bar(T) { T t; }

Compiling this with "dmd -c -X test.d" results in the file test.json containing the following. Note that the "kind" field for Foo(T) and Bar(T) contains "struct" and "class" respectively, as opposed to "template". The same problem does not occur with templated functions.

{
"name" : "test",
"kind" : "module",
"file" : "test.d",
"members" : [
{
"name" : "Foo(T)",
"kind" : "struct",
"line" : 2,
"members" : [
{
"name" : "Foo",
"kind" : "struct",
"line" : 2,
"members" : [
{
"name" : "t",
"kind" : "variable",
"type" : "T",
"line" : 2}
]
}
]
}
,{
"name" : "Bar(T)",
"kind" : "class",
"line" : 3,
"members" : [
{
"name" : "Bar",
"kind" : "class",
"line" : 3,
"members" : [
{
"name" : "t",
"kind" : "variable",
"type" : "T",
"line" : 3}
]
}
]
}
]
}

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


Simen Kjaeraas <simen.kjaras@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |simen.kjaras@gmail.com
            Summary|Wrong JSON output for       |Wrong JSON output for
                   |templated classes and       |templated classes, structs,
                   |structs                     |and interfaces


--- Comment #1 from Simen Kjaeraas <simen.kjaras@gmail.com> 2010-07-03 06:29:45 PDT ---
This also applies to interfaces.

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


Matt Peterson <revcompgeek@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |revcompgeek@gmail.com


--- Comment #2 from Matt Peterson <revcompgeek@gmail.com> 2012-03-14 13:01:39 PDT ---
https://github.com/D-Programming-Language/dmd/pull/813

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



--- Comment #3 from Walter Bright <bugzilla@digitalmars.com> 2013-01-19 23:20:52 PST ---
https://github.com/D-Programming-Language/dmd/pull/1517

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


Walter Bright <bugzilla@digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED


-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------