Bug 325377 - [content assist] Namespace objects don't show JSDoc when selecting from possible completions
Summary: [content assist] Namespace objects don't show JSDoc when selecting from possi...
Status: NEW
Alias: None
Product: JSDT
Classification: WebTools
Component: General (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 normal with 1 vote (vote)
Target Milestone: Future   Edit
Assignee: Project Inbox CLA
QA Contact: Chris Jaun CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-09-15 13:14 EDT by Mark Storer CLA
Modified: 2013-06-19 11:10 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mark Storer CLA 2010-09-15 13:14:10 EDT
Build Identifier: 20100615235519

/**
 * @namespace Foo is a singleton.
 */
var Foo = {};
/**
 * some stuff
 * @return {String} "some stuff"
 */
Foo.bar = function() { return "some stuff"; };
/**
 * other stuff
 * @return {String} "other stuff"
 */
Foo.baz = function() { return "other stuff"; };

-----

Given the above script in a library, typing "Foo." will generate a code completion list correctly, listing bar & baz as options.

HOWEVER, it will not show the "tool tip" style JSDoc for either function.

Classes with "myClass.prototype.someFun = function..." correctly display the JSDoc tool tip when that particular function is selected from a list of possible completions.

Reproducible: Always

Steps to Reproduce:
1. Define an object with several static methods & JSDoc, as in the Details.
2. Place that object in the include path (as a user library for example).
3. Create a JS project that uses the above library.
4. Create a JS file, containing "Foo."
5. After the '.', invoke code completion.
6. In the displayed list of functions select either "bar" or "baz"
7. Note that the JSDoc never appears in the tool tip.

If you select one of the Object methods in the same list (toString, valueOf, etc), the JSDoc tool tip appears correctly.
Comment 1 Mark Storer CLA 2010-09-17 16:40:22 EDT
Hover JSDoc does not appear for them either.  Probably related.

In my sample script, Foo is reported as an "any" in the outline and hover, but code completion still detects bar & baz.  Funky.