Can you use a keyword as an argument, or any other kind of local variable? Why would you want to do that? That aside: how?
Easy! Just use the @ in front of any keyword and you can now use it as a variable. For example:
class Program
{
static void UsingKeywordArg(string @string)
{
Console.WriteLine(@string);
}
static void Main(string[] args)
{
UsingKeywordArg("Hello world");
}
}
I found this while digging through some generated code from workflow foundation 4. Cool!