[jira] [Updated] (NETBEANS-1728) ClassCastException in switch expression
[ https://issues.apache.org/jira/browse/NETBEANS-1728?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] ASF GitHub Bot updated NETBEANS-1728: - Labels: NB-JDK12 pull-request-available (was: NB-JDK12) > ClassCastException in switch expression > > > Key: NETBEANS-1728 > URL: https://issues.apache.org/jira/browse/NETBEANS-1728 > Project: NetBeans > Issue Type: Bug >Reporter: vikas kumar prabhakar >Assignee: Sarvesh Kesharwani >Priority: Major > Labels: NB-JDK12, pull-request-available > > Exception occur "java.lang.ClassCastException" with following code snippet: > int i=10; > final String val = > switch (i) > { case 1 : break "one"; case 2 -> "two"; } > ; > > Exception logs: > java.lang.ClassCastException: class > com.sun.tools.javac.tree.JCTree$JCSwitchExpression cannot be cast to class > com.sun.source.tree.StatementTree > (com.sun.tools.javac.tree.JCTree$JCSwitchExpression and > com.sun.source.tree.StatementTree are in module jdk.compiler of loader 'app') > at > org.netbeans.api.java.source.TreeUtilities.getBreakContinueTarget(TreeUtilities.java:1358) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.visitBreak(NPECheck.java:1252) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.visitBreak(NPECheck.java:545) > at > jdk.compiler/com.sun.tools.javac.tree.JCTree$JCBreak.accept(JCTree.java:1575) > at > jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:82) > at > org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:69) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.scan(NPECheck.java:624) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.scan(NPECheck.java:545) > at jdk.compiler/com.sun.source.util.TreeScanner.scan(TreeScanner.java:106) > at > org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:78) > at > jdk.compiler/com.sun.source.util.TreeScanner.scanAndReduce(TreeScanner.java:114) > at > jdk.compiler/com.sun.source.util.TreeScanner.visitCase(TreeScanner.java:372) > at > jdk.compiler/com.sun.tools.javac.tree.JCTree$JCCase.accept(JCTree.java:1293) > at > jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:82) > at > org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:69) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.scan(NPECheck.java:624) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.scan(NPECheck.java:545) > at jdk.compiler/com.sun.source.util.TreeScanner.scan(TreeScanner.java:106) > at > org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:78) > at > jdk.compiler/com.sun.source.util.TreeScanner.scanAndReduce(TreeScanner.java:114) > at > jdk.compiler/com.sun.source.util.TreeScanner.visitSwitchExpression(TreeScanner.java:354) > at > jdk.compiler/com.sun.tools.javac.tree.JCTree$JCSwitchExpression.accept(JCTree.java:1323) > at > jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:82) > at > org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:69) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.scan(NPECheck.java:624) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.visitVariable(NPECheck.java:704) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.visitVariable(NPECheck.java:545) > at > jdk.compiler/com.sun.tools.javac.tree.JCTree$JCVariableDecl.accept(JCTree.java:980) > at > jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:82) > at > org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:69) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.scan(NPECheck.java:624) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.scan(NPECheck.java:545) > at > jdk.compiler/com.sun.source.util.TreeScanner.scanAndReduce(TreeScanner.java:91) > at jdk.compiler/com.sun.source.util.TreeScanner.scan(TreeScanner.java:106) > at > org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:78) > at > jdk.compiler/com.sun.source.util.TreeScanner.visitBlock(TreeScanner.java:249) > at > jdk.compiler/com.sun.tools.javac.tree.JCTree$JCBlock.accept(JCTree.java:1038) > at > jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:82) > at > org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:69) > at > org.netbeans.modules.java.hints.bugs.NPECheck$VisitorImpl.scan(NPECheck.java:624) > at
[jira] [Created] (NETBEANS-1857) Incorrect charset detection. Incorrect character display.
Old Knight created NETBEANS-1857: Summary: Incorrect charset detection. Incorrect character display. Key: NETBEANS-1857 URL: https://issues.apache.org/jira/browse/NETBEANS-1857 Project: NetBeans Issue Type: Bug Affects Versions: 10.0 Environment: Windows 7, 64bits Reporter: Old Knight Attachments: screen-01.png, screen-02.png, screen-03.png, screen-04.png When opening a PHP project in utf8, NetBeans erroneously detects a file with windows1252 encoding, but the file is correctly in utf8 (as shown in Notepad++) Bug not present in "10 vc4" version -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Updated] (NETBEANS-1857) Incorrect charset detection. Incorrect character display.
[ https://issues.apache.org/jira/browse/NETBEANS-1857?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Old Knight updated NETBEANS-1857: - Environment: Windows 7, 64bits, pt-BR (brazilian portuguese) (was: Windows 7, 64bits) > Incorrect charset detection. Incorrect character display. > - > > Key: NETBEANS-1857 > URL: https://issues.apache.org/jira/browse/NETBEANS-1857 > Project: NetBeans > Issue Type: Bug >Affects Versions: 10.0 > Environment: Windows 7, 64bits, pt-BR (brazilian portuguese) >Reporter: Old Knight >Priority: Major > Attachments: screen-01.png, screen-02.png, screen-03.png, > screen-04.png > > > When opening a PHP project in utf8, NetBeans erroneously detects a file with > windows1252 encoding, but the file is correctly in utf8 (as shown in > Notepad++) > Bug not present in "10 vc4" version -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Resolved] (NETBEANS-1834) Possible race condition in ExplorerActionsImpl
[ https://issues.apache.org/jira/browse/NETBEANS-1834?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Rangi Keen resolved NETBEANS-1834. -- Resolution: Fixed Assignee: (was: Rangi Keen) Fix Version/s: Next > Possible race condition in ExplorerActionsImpl > -- > > Key: NETBEANS-1834 > URL: https://issues.apache.org/jira/browse/NETBEANS-1834 > Project: NetBeans > Issue Type: Bug > Components: platform - Explorer >Affects Versions: 8.2 >Reporter: Rangi Keen >Priority: Minor > Labels: pull-request-available > Fix For: Next > > Attachments: ExplorerActionsImpl.Race.patch > > Time Spent: 0.5h > Remaining Estimate: 0h > > {{ExplorerActionsImpl}} uses a background thread to determine the enabled > state of its actions. The background thread calls > {{ExplorerActionsImpl.BaseAction.toEnabled(boolean)}} to set the target state > from the background thread and then queues up a call on the {{EventQueue}} to > be run on the EDT that calls {{ExplorerActionsImpl.BaseAction.syncEnable()}} > which calls {{setEnabled}} if {{toEnable}} is non-null. > However, since the check for {{toEnable != null}}, the use of {{toEnable}} in > the call to {{setEnabled}}, and the set of {{toEnable = null}} are all on > separate lines there is the possibility that another call to > {{toEnabled(boolean)}} will set {{toEnable}} after the call to {{setEnabled}} > but before it is reset to null. The end result is that if the new value of > {{toEnable}} was different from the one being acted upon, the action may end > up in the wrong state. > One solution (in [^ExplorerActionsImpl.Race.patch]) is to use an > {{AtomicInteger}} to get the value of {{toEnable}} and set it to null (or > {{NO_CHANGE}}) atomically, thus avoiding the race condition. > I don't have a reproducible case in the NetBeans IDE, but we encountered this > in our custom application using the NetBeans platform. The attached patch > solved the issue in our case. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Closed] (NETBEANS-1857) Incorrect charset detection. Incorrect character display.
[ https://issues.apache.org/jira/browse/NETBEANS-1857?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Old Knight closed NETBEANS-1857. Resolution: Cannot Reproduce > Incorrect charset detection. Incorrect character display. > - > > Key: NETBEANS-1857 > URL: https://issues.apache.org/jira/browse/NETBEANS-1857 > Project: NetBeans > Issue Type: Bug >Affects Versions: 10.0 > Environment: Windows 7, 64bits, pt-BR (brazilian portuguese) >Reporter: Old Knight >Priority: Major > Attachments: screen-01.png, screen-02.png, screen-03.png, > screen-04.png > > > When opening a PHP project in utf8, NetBeans erroneously detects a file with > windows1252 encoding, but the file is correctly in utf8 (as shown in > Notepad++) > Bug not present in "10 vc4" version -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Created] (NETBEANS-1858) Apply Code Changes not working
Tomasz Kubik created NETBEANS-1858: -- Summary: Apply Code Changes not working Key: NETBEANS-1858 URL: https://issues.apache.org/jira/browse/NETBEANS-1858 Project: NetBeans Issue Type: Bug Affects Versions: 10.0 Reporter: Tomasz Kubik Fix For: 10.0 Button "Apply Code Changes" is always disabled. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Commented] (NETBEANS-360) Autocomplete, better name matching
[ https://issues.apache.org/jira/browse/NETBEANS-360?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16734370#comment-16734370 ] Bo Andersen commented on NETBEANS-360: -- This information should not get lost, if someone is trying to add this feature to the PHP language, from the mailing list: https://lists.apache.org/thread.html/53e825e433962bb9fdc72dea5fe691517f5cd7c887eb365dec496686@%3Cusers.netbeans.apache.org%3E {quote}You want a 'CompletionProvider', most likely PhpTypeCompletionProvider (although there are some other subclasses in the php/ folder). You have Set getItems(FileObject sourceFile, String prefix) where `prefix` is what the user already typed. Oddly enough I see php defines it's own org.netbeans.modules.php.spi.templates.completion.CompletionProvider while I remeber being a common interface, but I'm probably thinking of csl.api GsfCompletionProvider which was used in the Javascript support. Feel free to email me directly (or to CC me when writing to the mailing list) I might have some ideas there. I suspect fuzzy search might not work immediately, as while the completion popup is shown any further edit will just filter the list (and not re-generate the list from the provider). But perhaps there is a way for force refresh that list... Anyhow, start playing with that API and see if you make progress. --emi{quote} > Autocomplete, better name matching > -- > > Key: NETBEANS-360 > URL: https://issues.apache.org/jira/browse/NETBEANS-360 > Project: NetBeans > Issue Type: Improvement > Components: php - Editor >Affects Versions: Next > Environment: Windows 10 >Reporter: Bo Andersen >Priority: Major > Attachments: autocomplete_all.png, autocomplete_search.png > > > I am using the Netbeans 9 beta release (RC2). I needed a method in a > test-framework, and couldn't remember the exact naming, but only some part of > it. Netbeans seems only to match the beginning of methods names. I know other > IDEs can suggest methods based on naming-parts in a method, I think this is > very useful :) > > Update: I added example (attachments) of usage from another IDE, for > inspiration -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Updated] (NETBEANS-1773) autocomplete improving
[ https://issues.apache.org/jira/browse/NETBEANS-1773?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Los Vitaly updated NETBEANS-1773: - Attachment: no-this.gif > autocomplete improving > -- > > Key: NETBEANS-1773 > URL: https://issues.apache.org/jira/browse/NETBEANS-1773 > Project: NetBeans > Issue Type: Improvement > Components: php - Editor >Affects Versions: 8.2, 9.0 >Reporter: Marcos Vinicius Soares Souza >Assignee: Marcos Vinicius Soares Souza >Priority: Blocker > Attachments: no-this.gif > > > Is it possible to fix some bugs in PHP autocomplete in netbens? > The problem I identified was the following: I created a config.php file in my > project and within that file I created a PDO type object. > Soon after I created another file called index.php and I imported the file > config.php > through of comand "require" into index.php. > The problem occurs when I call the PDO methods in the index.php file. > Netbeans does not show me the methods available in the class, so I have to > type everything manually. > If possible, also leave the autocomplete better, making it necessary to > insert the "$" only once in the variable declaration, so that programmers > can, for example, declare a variable "$ a" and then call it just by typing > "a", just like in PHPStorm. > If possible too, make the autocomplete work perfectly in .class files. > Generally in my PHP projects I use the .class extension in my classes to > differentiate from other .php files that are not classes. But autocomplete > does not work perfectly on these file types, for example, if I declare a > variable in a .class file, I will not be able to call it through autocomplete > even with these problems I can not leave netbeans, I really like this IDE and > I will like it much more if these problems are solved. > Thank you, for you are giving continuity to the project. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Commented] (NETBEANS-1773) autocomplete improving
[ https://issues.apache.org/jira/browse/NETBEANS-1773?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16734397#comment-16734397 ] Los Vitaly commented on NETBEANS-1773: -- It's related to my report for PHP autocomplete property and method without typing $this->, but only in class context https://issues.apache.org/jira/browse/NETBEANS-1855 Maybe, it's better to close my report, because it's almost identical to third paragraph. Here I just leave a image for better understanding > autocomplete improving > -- > > Key: NETBEANS-1773 > URL: https://issues.apache.org/jira/browse/NETBEANS-1773 > Project: NetBeans > Issue Type: Improvement > Components: php - Editor >Affects Versions: 8.2, 9.0 >Reporter: Marcos Vinicius Soares Souza >Assignee: Marcos Vinicius Soares Souza >Priority: Blocker > Attachments: no-this.gif > > > Is it possible to fix some bugs in PHP autocomplete in netbens? > The problem I identified was the following: I created a config.php file in my > project and within that file I created a PDO type object. > Soon after I created another file called index.php and I imported the file > config.php > through of comand "require" into index.php. > The problem occurs when I call the PDO methods in the index.php file. > Netbeans does not show me the methods available in the class, so I have to > type everything manually. > If possible, also leave the autocomplete better, making it necessary to > insert the "$" only once in the variable declaration, so that programmers > can, for example, declare a variable "$ a" and then call it just by typing > "a", just like in PHPStorm. > If possible too, make the autocomplete work perfectly in .class files. > Generally in my PHP projects I use the .class extension in my classes to > differentiate from other .php files that are not classes. But autocomplete > does not work perfectly on these file types, for example, if I declare a > variable in a .class file, I will not be able to call it through autocomplete > even with these problems I can not leave netbeans, I really like this IDE and > I will like it much more if these problems are solved. > Thank you, for you are giving continuity to the project. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Closed] (NETBEANS-1855) Autocomplete for property and method without $this->
[ https://issues.apache.org/jira/browse/NETBEANS-1855?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Los Vitaly closed NETBEANS-1855. Resolution: Duplicate > Autocomplete for property and method without $this-> > > > Key: NETBEANS-1855 > URL: https://issues.apache.org/jira/browse/NETBEANS-1855 > Project: NetBeans > Issue Type: Improvement >Affects Versions: 11.0 >Reporter: Los Vitaly >Priority: Major > Attachments: no-this.gif > > > I think properties and methods have to be first in popup window and user can > quickly choose the right one. > It very nice and useful improvement for PHP (Java?) developers, because in > nowadays all are OOP. I add image, for better understanding. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Commented] (NETBEANS-540) Mercurial versioning. Lost diff history after refactoring
[ https://issues.apache.org/jira/browse/NETBEANS-540?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16734545#comment-16734545 ] mike duigou commented on NETBEANS-540: -- The same issue applies for git > Mercurial versioning. Lost diff history after refactoring > - > > Key: NETBEANS-540 > URL: https://issues.apache.org/jira/browse/NETBEANS-540 > Project: NetBeans > Issue Type: Bug > Components: versioncontrol - Mercurial >Affects Versions: 9.0 >Reporter: Vldimir Orlyansky >Priority: Minor > > Found through NetCat 9.0 > After refactoring file Mercurial history from Editor page does not show diff > to previous version. > Search history for file does not show history before renaming (history for > file when it had previous name). -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Updated] (NETBEANS-540) Mercurial versioning. Lost diff history after refactoring
[ https://issues.apache.org/jira/browse/NETBEANS-540?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] mike duigou updated NETBEANS-540: - Component/s: versioncontrol - Git > Mercurial versioning. Lost diff history after refactoring > - > > Key: NETBEANS-540 > URL: https://issues.apache.org/jira/browse/NETBEANS-540 > Project: NetBeans > Issue Type: Bug > Components: versioncontrol - Git, versioncontrol - Mercurial >Affects Versions: 9.0 >Reporter: Vldimir Orlyansky >Priority: Minor > > Found through NetCat 9.0 > After refactoring file Mercurial history from Editor page does not show diff > to previous version. > Search history for file does not show history before renaming (history for > file when it had previous name). -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Updated] (NETBEANS-540) Lost diff history after refactoring changed file name
[ https://issues.apache.org/jira/browse/NETBEANS-540?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] mike duigou updated NETBEANS-540: - Summary: Lost diff history after refactoring changed file name (was: Mercurial versioning. Lost diff history after refactoring) > Lost diff history after refactoring changed file name > - > > Key: NETBEANS-540 > URL: https://issues.apache.org/jira/browse/NETBEANS-540 > Project: NetBeans > Issue Type: Bug > Components: versioncontrol - Git, versioncontrol - Mercurial >Affects Versions: 9.0 >Reporter: Vldimir Orlyansky >Priority: Minor > > Found through NetCat 9.0 > After refactoring file Mercurial history from Editor page does not show diff > to previous version. > Search history for file does not show history before renaming (history for > file when it had previous name). -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists