a575963da9
Former-commit-id: da6be194a6b1221998fc28233f2503bd61dd9d14
28 lines
497 B
C#
28 lines
497 B
C#
public class Test
|
|
{
|
|
public delegate bool UnaryOperator(object self, out object res);
|
|
public void AddOperator(UnaryOperator target) {}
|
|
public bool TryGetValue(object self, out object value)
|
|
{
|
|
value = null;
|
|
return false;
|
|
}
|
|
|
|
public static void Main ()
|
|
{
|
|
}
|
|
|
|
void Foo ()
|
|
{
|
|
AddOperator (delegate(object self, out object res) {
|
|
object value;
|
|
if (TryGetValue(self, out value)) {
|
|
res = value;
|
|
if (res != null) return true;
|
|
}
|
|
res = null;
|
|
return false;
|
|
});
|
|
}
|
|
}
|