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

Debugging issue if property with name "Environment" exists #23962

Open
taori opened this issue Dec 29, 2017 · 3 comments
Open

Debugging issue if property with name "Environment" exists #23962

taori opened this issue Dec 29, 2017 · 3 comments

Comments

@taori
Copy link

taori commented Dec 29, 2017

Version Used:

Steps to Reproduce:
grafik

Expected Behavior:

This code should not fail or crash. It should either not compile if it can't distinguish between members or pick the property as i would expect it to

Actual Behavior:

As you can see in the image Environment is recognized as property by resharper as i would expect it. However when accessing "Environment.Authentication" an exception occurs. In the inspection window you can see the debugger thinks i want to use "System.Environment" - which i don't.

@jcouv
Copy link
Member

jcouv commented Dec 29, 2017

What's the exception/trace?

@jcouv
Copy link
Member

jcouv commented Jan 13, 2018

@taori Another question, can you repro with Resharper disabled? (ran into a few issues with Resharper recently, so I want to rule it out)

@taori
Copy link
Author

taori commented Jan 14, 2018

Sorry, didn't see your request - I don't have access to the stack trace anymore, but as you can see in the inspection window it does show different types for Environment and this.Environment. I guess that is evidence enough that this is not a resharper related issue? It was happening on Xamarin.Android if that adds any relevant information to find the source of this?

I also want to add that the reason of the exception was that authentication wasn't initialized which i was unable to detect because i got the inspection results for the wrong type

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

No branches or pull requests

3 participants