Decompiler (dotPeek) output:
class Base {
public Base(int d, int e, int f) {
// logic
Console.WriteLine ("Base constructor");
}
}
class Child : Base {
public Child(string a, string b, string c) {
// logic before explicit call, calculating d, e, f
// ISSUE: explicit constructor call
base.\u002Ector(d, e, f);
// logic after explicit call
}
}
Trying to convert it to normal c# base constructor call, but can't figure out how to unpack tuple to pass it as args to parent constructor:
class Base {
public Base(int d, int e, int f) {
// logic
Console.WriteLine ("Base constructor");
}
}
class Child : Base {
public Child(string a, string b, string c) : base(DoWorkBeforeBaseConstructor(a, b, c)) {
// logic after explicit call
}
private static (int, int, int) DoWorkBeforeBaseConstructor(string a, string b, string c) {
// logic generating response based on params
// logic before explicit call
return (1, 2, 3);
}
}