Autocompletion of method overrides places method above attribute
- Dominant language
- C#
- Stars
- 20.7k
- Forks
- 4.3k
- PR merge metrics
- PR metrics pending
Description
**Version Used**: VS 18.0.0 Insiders [11121.172]
**Steps to Reproduce**:
Invoke auto-complete at the marked location.
```csharp
class TestAttribute : Attribute;
abstract class B
{
public abstract void M();
}
class C : B
{
[Test]
override M$$
}
```
**Expected Behavior**:
The existing attribute that is located before the stub override is applied to the generated method body (i.e. the method is placed after the attribute that precedes it).
```csharp
class C : B
{
[Test]
public override void M()
{
throw new NotImplementedException();
}
}
```
**Actual Behavior**:
The method declaration is placed above the attribute. This is easily fixable by hand, but it is annoying.
```csharp
class C : B
{
public override void M()
{
throw new NotImplementedException();
}
[Test]
}
```
Contributor guide
Assessment
This issue has not been assessed yet.