This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 246729

Summary: Function incorrectly evaluated as an object
Product: javascript Reporter: Roman Svitanic <rsvitanic>
Component: EditorAssignee: Petr Pisl <ppisl>
Status: NEW ---    
Severity: normal CC: vriha
Priority: P3    
Version: 8.1   
Hardware: PC   
OS: All   
Issue Type: DEFECT Exception Reporter:

Description Roman Svitanic 2014-08-27 14:39:18 UTC
Example:

obj.f1 = obj.f2 = function () {}

or

obj.f2 = function() { };
obj.f1 = obj.f2;

In both cases above obj.f1 should be evaluated as a function, not an object.
Comment 1 Roman Svitanic 2015-04-23 16:17:55 UTC
*** Bug 243918 has been marked as a duplicate of this bug. ***
Comment 2 Roman Svitanic 2015-04-23 16:19:21 UTC
Another simple case on which the issue can be reproduced:

function A() {
    this.test = function () {};
}
var a = new A();
var x = {
    demo: a.test()
};
x. // invoke CC here -> demo is not evaluated as a function
Comment 3 Roman Svitanic 2015-05-05 15:54:00 UTC
*** Bug 248159 has been marked as a duplicate of this bug. ***