In the past we declared properties like this:
public class MyClass
{
private int _age;
public int Age
{
get{ return _age; }
This syntax is commonly called "syntax sugar", which means that the compiler takes that syntax and translates it into something else. In your example, the compiler would generate code that looks something like this:
[CompilerGenerated]
private int k_BackingField;
public int Age
{
[CompilerGenerated]
get
{
return this.k_BackingField;
}
[CompilerGenerated]
set
{
this.k_BackingField = value;
}
Even knowing all of that, you could probably access the backing field directly but that sort of defeats the purpose of using automatic properties. I say probably here because you then depend on an implementation detail that could change at any point in a future release of the C# compiler.