C# not able to understand a code snippet

T.Zacks 3,986 Reputation points

See this code
public override string EditorTypeName => CustomEditName;

what kind of code is it ?

is it any function declaration or property?

how to convert the above to .net 4.5 version compatible? thanks

An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,600 questions
0 comments No comments
{count} votes

Accepted answer
  1. Viorel 114.4K Reputation points

    how to convert the above to .net 4.5 version compatible?

    Place the caret at this line, press <Ctrl+.> and select “Use block body for properties”.

    If you do not have Visual Studio right now, it will transform it to:

    public override string EditorTypeName
          return CustomEditName;
    1 person found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. Sam of Simple Samples 5,526 Reputation points

    It is an Expression body definition, as in => operator.