Improved C# compat