Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CLOSED] [js code hints] code hint not consistently correct when calling a method which returns a method. #3628

Open
core-ai-bot opened this issue Aug 29, 2021 · 4 comments

Comments

@core-ai-bot
Copy link
Member

Issue by jodyzhang
Friday May 17, 2013 at 19:10 GMT
Originally opened as adobe/brackets#3885


  1. following following code snippet, try to get code hint after 20)(
function funD(a, b) {
    "use strict";
    var f = function () {return {x: a, y: b}; };
    return f;
}
var k = funD(10, 20)(;
k();

->try code hints for:
a.funD(
b.funD(10, 20)(
c.k()
d.funD(10, 20)(
e.funD(

Actual:
at b, function type is incorrect, it shows "fn(a:number, b:number) -> fn() -> {x,y}"
expect: fn() ->{x,y}

at e, funtion type is incorrect, it shows "funD() ->{x, y}"
expect: "fn(a:number, b:number) -> fn() -> {x,y}"

if you can't reproduce, try it couple times, different orders(a, c, e, d) etc. It is easily reproduced for me.

Expect: consistent code hint behaviors.

@core-ai-bot
Copy link
Member Author

Comment by gruehle
Monday May 20, 2013 at 18:24 GMT


Reviewed, to@dloverin.

@core-ai-bot
Copy link
Member Author

Comment by pfarland
Tuesday May 21, 2013 at 21:06 GMT


I can rarely reproduce any of the issues mentioned above. If the issue requires multiple syntactically invalid lines to be present before the hint then this is a very low priority and I suggest we close.

@core-ai-bot
Copy link
Member Author

Comment by dloverin
Friday Jun 07, 2013 at 20:50 GMT


@jodyzhang fixed.

@core-ai-bot
Copy link
Member Author

Comment by jodyzhang
Monday Jun 10, 2013 at 14:35 GMT


verified and closed it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant