senchalabs/jsduck — Issue #118: Constructors have Object has return type.
Author: davidfoley
Created: 2012-01-03 13:00:04+00:00
State: open

I'm really liking JsDuck, but one issue that is a little annoying is the return type given by constructors- for example, the documentation generated for the following vanilla JavaScript class

/**
* @class com.example.UserClass
*
* @param {String} name
* @constructor
*/

function UserClass (name)
{
this.setName(name)
};

UserClass.prototype.setName= function (name)
{
this.name= name;
};

shows the constructor as an instance method with a return type of Object

**Methods**
new com.example.UserClass():Object
*Returns* Object

Is there no special heading for constructors, and shouldn't they have the @class value as they're return type?