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

Decompiled code is missing backing field attributes on auto properties #26422

Closed
jhinder opened this issue Apr 26, 2018 · 3 comments
Closed

Decompiled code is missing backing field attributes on auto properties #26422

jhinder opened this issue Apr 26, 2018 · 3 comments
Labels
Area-External Area-IDE Resolution-External The behavior lies outside the functionality covered by this repository
Milestone

Comments

@jhinder
Copy link
Contributor

jhinder commented Apr 26, 2018

Version Used: VS 15.7 Preview 5 (2.8.0.62825)

Steps to Reproduce:

  1. Enable the decompiler feature.
  2. Generate a class library from the code below.
  3. Reference the generated binary from another project.
  4. Write new Repro.Test().Prop, put the caret on Prop and hit F12.
  5. Accept the licence agreement for the decompiler.

Both projects were configured to use C# 7.3.

using System;

namespace Repro
{
	public class Test
	{
		[field: Obsolete("Field")]
		[property: Obsolete("Property")]
		public int Prop { get; set; }
	}
}

Expected Behavior: The disassembled code shows both attributes, with the decompiled code looking similar to the code above.

Actual Behavior: Only the property attribute is there. The backing field attribute does not appear in the code.

@gafter gafter added the Area-IDE label May 8, 2018
@siegfriedpammer
Copy link
Contributor

See icsharpcode/ILSpy#829 -- the decompiler does not yet support this language feature. We're working hard to catch up as soon as possible.

@siegfriedpammer
Copy link
Contributor

siegfriedpammer commented May 11, 2018

As of version 3.2.0.3685-alpha this language feature is now implemented in the decompiler. It will hopefully land in VS with the next minor release, that is 3.2.0 final.

@jinujoseph jinujoseph added this to the Unknown milestone Jun 19, 2018
@jinujoseph jinujoseph added the Resolution-External The behavior lies outside the functionality covered by this repository label Jun 19, 2018
@jinujoseph
Copy link
Contributor

This will be automatically included when we update to an ILSpy version that supports it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-External Area-IDE Resolution-External The behavior lies outside the functionality covered by this repository
Projects
None yet
Development

No branches or pull requests

5 participants