CodeQL library for C#
codeql/csharp-all 0.4.0-dev (changelog, source)
Search

Member predicate ObjectInitializer::getMemberInitializer

Gets the ith member initializer of this object initializer. For example, Y = 1 is the second (i = 1) member initializer of the object initializer { X = 0, Y = 1 } on line 6 in

class A {
  int X;
  int Y;

  public static A Create() {
    return new A { X = 0, Y = 1 };
  }
}
MemberInitializer getMemberInitializer(int i)