mbien commented on issue #3805: URL: https://github.com/apache/netbeans/issues/3805#issuecomment-1140241126
> PHP is not Java... indeed, but we can try to learn from it. PHP functions don't contain sufficient information in the declaration to allow the IDE to fully complete the return statement. An incomplete return statement is just like the bar method https://github.com/apache/netbeans/issues/3805#issuecomment-1139684802, (just without the space since the IDE can't guess that for PHP). The java editor does not add the semicolon there, the PHP editor probably shouldn't either. Maybe there should be two completion items for the `return` keyword. - One for `return;${cursor}` - and one for `return ${invokeCompletion}`. But that is just an idea, as i mentioned twice already, I have limited knowledge of the PHP editor. > I don't think NetBeans is IDE for only Java... correct. Who claimed anything else? > We should fix the editor without breaking the existing behavior of other languages. i have a draft pr pending which mitigates the symptom a bit in situations when completions are not behaving well (e.g if they keep looping when pressing ctrl+space). But i have to test a bit more to make sure it doesn't affect other languages (yes, other than PHP and Java ;)) and more complex templates. Essentially having to test that the behavior of NB <12.2 is still there and also that #2519 works (without causing the regression added by the same PR). -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
