| Summary: | JavaScript Generics: @returns {Array<Type>} | ||
|---|---|---|---|
| Product: | [WebTools] JSDT | Reporter: | domcap <dominic.chambers> |
| Component: | General | Assignee: | Project Inbox <jsdt.javascript-inbox> |
| Status: | RESOLVED WONTFIX | QA Contact: | Nitin Dahyabhai <thatnitind> |
| Severity: | enhancement | ||
| Priority: | P3 | CC: | philippe.marschall |
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Windows XP | ||
| Whiteboard: | |||
jsdoc-toolkit seems to use the following notation
@returns {Type[]}
http://code.google.com/p/jsdoc-toolkit/wiki/TagParam#Parameter_Type_Information
As linked in comment 1, there's a set format for the documentation we support. We're not going to invent/extend one and make people use it. Recommend advocating for something like this in JSDoc 3 (or 4?) and then we'll look into using it. I'm a bit confused, it's in JSDoc 2 http://code.google.com/p/jsdoc-toolkit/wiki/TagParam#Parameter_Type_Information so I'm not sure why there is a need to advocate this in JSDoc 3 (or 4). @Nittin You've closed this bug as won't fix but you also don't support the jsdoc array notation that other people have mentioned on this issue. Should I raise another issue for that instead? @Philippe I assume the reason Nittin is saying that I should ask for it in jsdoc v3 (or v4) is that the notation I was suggesting was more powerful as it allows typed maps too. As it happens, I didn't know about the jsdoc array notation since I'm still using jsdoc-pl (rather than jsdoc-toolkit), which doesn't have support for either notation. |
Build Identifier: 20100617-1415 The content assist in Eclipse works really well until you hit a method that returns arrays, at which point there is no way to inform Eclipse which type of object the array consists of. I'd like to propose the following (Java Generics style) notation for allowing this: @returns {Array<Type>} comment This would work immediately in jsdoc-toolkit and jsdoc.pl since it will just be interpreted as a string, but could also be supported more thourougly later, allowing hyperlinking of the type within the angle brackets. Reproducible: Always