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

Constructor aren't handled correctly. #63

Closed
JoshVarty opened this issue Dec 27, 2014 · 1 comment · Fixed by #66
Closed

Constructor aren't handled correctly. #63

JoshVarty opened this issue Dec 27, 2014 · 1 comment · Fixed by #66
Assignees
Labels

Comments

@JoshVarty
Copy link
Contributor

Working at the token level has created some issues relating to constructors not linking correctly.

For example: http://sourcebrowser.io/Browse/RaYell/selenium-webdriver-extensions/src/Selenium.WebDriver.Extensions/By.cs#27

The constructor links incorrectly to: http://sourcebrowser.io/Browse/RaYell/selenium-webdriver-extensions/test/Selenium.WebDriver.Extensions.Tests/JQuerySelectorTests.cs#124

This is due to two bugs. The first is due to the following:

When traversing documents at the token level, occasionally we link to the type instead of the constructor.

For example retrieving the symbol for an ObjectExpressionSyntax like:
new JQuerySelector(selector, context, jQueryVariable)
will work correctly.

However, as we work with individual tokens, we're retrieving the symbol for the IdentifierSyntax:
JQuerySelector
which will provide a symbol that refers to the type instead of the constructor.

So in theory we should be linked to the JQuerySelector type.

We're not because of a second bug that is closely related to #57. We're not handling parameters correctly when they appear in method declarations. I'll reopen #57 and provide an explanation there.

@JoshVarty JoshVarty added the bug label Dec 27, 2014
@JoshVarty JoshVarty self-assigned this Dec 27, 2014
@AmadeusW
Copy link
Member

The example at http://sourcebrowser.io/Browse/RaYell/selenium-webdriver-extensions/src/Selenium.WebDriver.Extensions/By.cs#27 reminded me of problem where non-static method usages pointed to static method declarations and vice versa. We needed to store additional boolean isStatic that helped match methods usages to appropriate methods.

AmadeusW added a commit that referenced this issue Jan 3, 2015
Fixes #63 and miscellaneous bugs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants