A small incompatibility with VS Intellisense

I am very fond of your graphical symbol announcing the "health" of each file:





Being able to see immediately that "all is green" has a lot of value, but there is one issue that causes grief. The warning "Redundant cast" shows up whenever I use the "this" operator, trying to get Intellisense to kick in. So, an innocent attempt to save typing (and recall what the heck was the name there), results with




Solution? R# could perhaps support the feature, where one can get the list of class attributes and methods without typing the whole word .this (say just "."), and have that "." removed when the symbol is selected. If the wrong symbol is selected in a hurry, one could just place a "." in front of that symbol, and enable another pick that would replace the current (incorrect) one.

Nik



Attachment(s):
AAA.jpg
AAA1.jpg
4 comments
Comment actions Permalink

You can switch off the 'this.' check in the options for R#.

I switched it off immediately as I use 'this.' everywhere in my code, I prefer 'this.' as I can read my code easier by knowing where an object/function comes from. :)


"Nik Ivancic" <nikivancic@yahoo.com> wrote in message news:dd0jtt$5v2$1@is.intellij.net...
I am very fond of your graphical symbol announcing the "health" of each file:





Being able to see immediately that "all is green" has a lot of value, but there is one issue that causes grief. The warning "Redundant cast" shows up whenever I use the "this" operator, trying to get Intellisense to kick in. So, an innocent attempt to save typing (and recall what the heck was the name there), results with




Solution? R# could perhaps support the feature, where one can get the list of class attributes and methods without typing the whole word .this (say just "."), and have that "." removed when the symbol is selected. If the wrong symbol is selected in a hurry, one could just place a "." in front of that symbol, and enable another pick that would replace the current (incorrect) one.

Nik



Attachment(s):
AAA.jpg
AAA1.jpg
0
Comment actions Permalink

Thanks, Pieter - that was the alternative I was ready to accept. It's not as good as the one I proposed, since in all truth, peppering your code with this. (which is what I was doing before getting R#) is redundant: the color coding already gives you the information you like to have.
"Pieter Jansen van Vuuren" <pieter@psh.co.za> wrote in message news:dd6bae$6np$1@is.intellij.net...
You can switch off the 'this.' check in the options for R#.

I switched it off immediately as I use 'this.' everywhere in my code, I prefer 'this.' as I can read my code easier by knowing where an object/function comes from. :)


"Nik Ivancic" <nikivancic@yahoo.com> wrote in message news:dd0jtt$5v2$1@is.intellij.net...
I am very fond of your graphical symbol announcing the "health" of each file:





Being able to see immediately that "all is green" has a lot of value, but there is one issue that causes grief. The warning "Redundant cast" shows up whenever I use the "this" operator, trying to get Intellisense to kick in. So, an innocent attempt to save typing (and recall what the heck was the name there), results with




Solution? R# could perhaps support the feature, where one can get the list of class attributes and methods without typing the whole word .this (say just "."), and have that "." removed when the symbol is selected. If the wrong symbol is selected in a hurry, one could just place a "." in front of that symbol, and enable another pick that would replace the current (incorrect) one.

Nik



Attachment(s):
AAA.jpg
AAA1.jpg
0
Comment actions Permalink

If there is no ".this", then it obviously comes from the current scope, and if you use the Resharper coloring options, you'll instantly know if it's a method, a property, a static field, a parameter, or a local variable.

Redundant use of "this." everywhere when it isn't required is really annoying to me, and I'm glad Resharper is going to let me yank all of those things out of the code I have to maintain... it's needless verbage and needlessly verbose. Just my opinion of course.
"Pieter Jansen van Vuuren" <pieter@psh.co.za> wrote in message news:dd6bae$6np$1@is.intellij.net...
You can switch off the 'this.' check in the options for R#.

I switched it off immediately as I use 'this.' everywhere in my code, I prefer 'this.' as I can read my code easier by knowing where an object/function comes from. :)


"Nik Ivancic" <nikivancic@yahoo.com> wrote in message news:dd0jtt$5v2$1@is.intellij.net...
I am very fond of your graphical symbol announcing the "health" of each file:





Being able to see immediately that "all is green" has a lot of value, but there is one issue that causes grief. The warning "Redundant cast" shows up whenever I use the "this" operator, trying to get Intellisense to kick in. So, an innocent attempt to save typing (and recall what the heck was the name there), results with




Solution? R# could perhaps support the feature, where one can get the list of class attributes and methods without typing the whole word .this (say just "."), and have that "." removed when the symbol is selected. If the wrong symbol is selected in a hurry, one could just place a "." in front of that symbol, and enable another pick that would replace the current (incorrect) one.

Nik



Attachment(s):
AAA.jpg
AAA1.jpg
0
Comment actions Permalink

Does CtrlShiftSpace do what you need? That's what I've used for years. (I,
too, am in the anti-this camp ;) )

-jk

"Nik Ivancic" <nikivancic@yahoo.com> wrote in message
news:dd0jtt$5v2$1@is.intellij.net...
I am very fond of your graphical symbol announcing the "health" of each
file:





Being able to see immediately that "all is green" has a lot of value, but
there is one issue that causes grief. The warning "Redundant cast" shows up
whenever I use the "this" operator, trying to get Intellisense to kick in.
So, an innocent attempt to save typing (and recall what the heck was the
name there), results with




Solution? R# could perhaps support the feature, where one can get the list
of class attributes and methods without typing the whole word .this (say
just "."), and have that "." removed when the symbol is selected. If the
wrong symbol is selected in a hurry, one could just place a "." in front of
that symbol, and enable another pick that would replace the current
(incorrect) one.

Nik


0

Please sign in to leave a comment.