0
有人可以帮助我将这个使用新的C#6语法的简单代码段翻译成Vb.Net吗?将C#6语法的简单代码转换为Vb.Net
产生的LINQ查询是不完整的(错误的语法)从Telerik做这样一个在某些在线服务转换时。
/// <summary>
/// An XElement extension method that removes all namespaces described by @this.
/// </summary>
/// <param name="this">The @this to act on.</param>
/// <returns>An XElement.</returns>
public static XElement RemoveAllNamespaces(this XElement @this)
{
return new XElement(@this.Name.LocalName,
(from n in @this.Nodes()
select ((n is XElement) ? RemoveAllNamespaces(n as XElement) : n)),
(@this.HasAttributes) ? (from a in @this.Attributes() select a) : null);
}
反射V9的表现非常体面的工作,反编译这VB。拿到你自己的副本。 –
这可能工作。 [转换代码](http://converter.telerik.com/)或让你非常接近。 – JAZ