You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@netbeans.apache.org by "Jonathan Mills (Jira)" <ji...@apache.org> on 2021/08/14 05:59:00 UTC

[jira] [Created] (NETBEANS-5921) JavaScript editor claims parseloat undefined if extra method appended

Jonathan Mills created NETBEANS-5921:
----------------------------------------

             Summary: JavaScript editor claims parseloat undefined if extra method appended
                 Key: NETBEANS-5921
                 URL: https://issues.apache.org/jira/browse/NETBEANS-5921
             Project: NetBeans
          Issue Type: Bug
          Components: javascript - Editor
    Affects Versions: 12.4
         Environment:  
*Product Version:* Apache NetBeans IDE 12.4

*Java:* 15.0.2; Java HotSpot(TM) 64-Bit Server VM 15.0.2+7-27

*Runtime:* Java(TM) SE Runtime Environment 15.0.2+7-27

*System:* Windows 10 version 10.0 running on amd64; Cp1252; en_GB (nb)
*User directory:* C:\Users\xyzzy\AppData\Roaming\NetBeans\12.4

*Cache directory:* C:\Users\xyzzy\AppData\Local\NetBeans\Cache\12.4

Windows 10 21H1 (Build 19043.1110)
            Reporter: Jonathan Mills
         Attachments: image-2021-08-14-06-51-24-430.png

The following javascript code in netbeans 12.5 generates underlining for all the "parseFloat" strings, claiming parseFloat (a standard JavaScript method) is not declared.
{noformat}
"use strict";
let a = parseInt(123);
let f = parseFloat("123.456")
let f1 = parseFloat("123.456").toFixed()
alert(`a=${a}, f=${f}`){noformat}
if the ".toFixed()" is removed, parseFloat is recognised.

It doesn't have to be "toFixed"... for instance .indexOf(".") also exhibits this behaviour

!image-2021-08-14-06-51-24-430.png|width=407,height=192!

Strictly, only lines 4 and 5 are fundamental to this report.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@netbeans.apache.org
For additional commands, e-mail: commits-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists