Skip to content

Instantly share code, notes, and snippets.

@tachiken
Created December 16, 2011 18:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tachiken/1487386 to your computer and use it in GitHub Desktop.
Save tachiken/1487386 to your computer and use it in GitHub Desktop.
CS1628対応?
public static Action GenerateHandler(ref MyClass arg1)
{
return delegate()
{
// This make compile error CS1628
// ref または out パラメータ 'arg1' は、匿名メソッド、ラムダ式、またはクエリ式の内部では使用できません
arg1.Property1 = false;
arg1 = arg1.GetNeighbour() ?? arg1;
arg1.Property1 = true;
};
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment