Version Used: VS2017 15.3.1
Steps to Reproduce:
Inline rename the attribute below from MyAttribute
to eg. XXXAttribute
C#
sealed class MyAttribute : Attribute {
}
Expected Behavior:
New name is XXXAttribute
Actual Behavior:
New name is XXXAttributeAttribute
Yes, I've encountered this problem too.
Having recently updated to 15.3.1, I'm now seeing the same problem. A workaround is to comment out the base class declaration, rename, and then uncomment the base class declaration.
Issue is still present in 15.7.0 Preview 3.0 [27602.0.d15.7]
I've encountered this problem in version: 15.7.3
Workaround:
Attribute
class, so you'll get e.g.
public sealed class MyAttribute // : Attribute
Attribute
again
public sealed class MyRenamedAttribute : Attribute
Well better workaround would be to first rename the class and then update references using the light bulb.
Guys, are you going to fix it? A year has passed already.
Guys, are you going to fix it? A
@yaroslavboev Are you interesting in contributing a fix? I can help walk you through the areas to look at here to fix this.
A year has passed already.
Time is generally only a small factor in prioritization of issues. In this case, the issue likely being out-prioritized by other work. If you'd like to help contribute here, that would help move things along! :)
@CyrusNajmabadi I would like to try to fix this issue
@lillo42 Great! Have you contributed to Roslyn before? Do you have an existing enlistmnet to work out of? Or would you need to get that set up?
@CyrusNajmabadi I haven't contributed before, I would like to get that set up. Do you recommend some article or something to read before I begin to fix?
@jmarolf Thanks much. I was just writing this up. You helped me out a lot finding all these references :)
@jmarolf @CyrusNajmabadi Thank very much.
also reported here
@OndrejVrsan Your workaround works thanks, issue still not resolved.
This issue still exists (at least in the version of Roslyn used by VS Community 2017 15.8.6)
@SaSiNO97 The fix will be available in VS 2019 Preview 2 (16.0 is the numeric version of VS 2019, just like 15.0 is for 2017), not in 15.8 or 15.9 unfortunately.
Why will this issue not be fixed in 15.9?
@PCC-UK Sadly, no.
@Neme12 There was a "Why" at the start of @PCC-UK's question :)
This is still an issue, why is this still not fixed?
@SieBrum
This is still an issue, why is this still not fixed?
Works for me:
@Neme12 Thanks, I really appreciate the work you are doing
Most helpful comment
Issue is still present in 15.7.0 Preview 3.0 [27602.0.d15.7]