Browse Source

- corrected AST

- fixed build (hopefully)

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/branches/vbnet@6014 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
pull/1/head
Siegfried Pammer 16 years ago
parent
commit
08b040e6f8
  1. 6
      src/AddIns/BackendBindings/Boo/BooBinding/Test/BooBinding.Tests.csproj
  2. 30
      src/AddIns/BackendBindings/Boo/NRefactoryToBooConverter/Project/ConvertVisitor.cs
  3. 11
      src/AddIns/BackendBindings/Boo/NRefactoryToBooConverter/Test/NRefactoryToBooConverter.Tests.csproj
  4. 2
      src/AddIns/BackendBindings/CSharpBinding/Tests/CSharpBinding.Tests.csproj
  5. 2
      src/AddIns/BackendBindings/Python/Python.Build.Tasks/Test/Python.Build.Tasks.Tests.csproj
  6. 2
      src/AddIns/BackendBindings/Python/PythonBinding/Test/PythonBinding.Tests.csproj
  7. 2
      src/AddIns/BackendBindings/WixBinding/Test/WixBinding.Tests.csproj
  8. 2
      src/AddIns/DisplayBindings/WpfDesign/WpfDesign.Designer/Tests/WpfDesign.Tests.csproj
  9. 5
      src/AddIns/Misc/ResourceToolkit/Test/ResourceToolkit.Tests.csproj
  10. 5
      src/AddIns/Misc/SearchAndReplace/Test/SearchAndReplace.Tests.csproj
  11. 10
      src/Libraries/NRefactory/NRefactoryASTGenerator/AST/Expressions.cs
  12. 63
      src/Libraries/NRefactory/Project/Src/Ast/Generated.cs
  13. 2
      src/Libraries/NRefactory/Project/Src/IAstVisitor.cs
  14. 32
      src/Libraries/NRefactory/Project/Src/Parser/VBNet/VBNET.ATG
  15. 5
      src/Libraries/NRefactory/Project/Src/Visitors/AbstractASTVisitor.cs
  16. 5
      src/Libraries/NRefactory/Project/Src/Visitors/AbstractAstTransformer.cs
  17. 11
      src/Libraries/NRefactory/Project/Src/Visitors/NodeTrackingAstVisitor.cs
  18. 4
      src/Libraries/NRefactory/Project/Src/Visitors/NotImplementedAstVisitor.cs
  19. 3
      src/Main/Base/Test/VBExpressionFinderTests.cs
  20. 12
      src/Main/Core/Test/ICSharpCode.Core.Tests.csproj

6
src/AddIns/BackendBindings/Boo/BooBinding/Test/BooBinding.Tests.csproj

@ -1,4 +1,5 @@
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> <?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
<PropertyGroup> <PropertyGroup>
<OutputType>Library</OutputType> <OutputType>Library</OutputType>
<RootNamespace>Grunwald.BooBinding.Tests</RootNamespace> <RootNamespace>Grunwald.BooBinding.Tests</RootNamespace>
@ -12,14 +13,13 @@
<RegisterForComInterop>False</RegisterForComInterop> <RegisterForComInterop>False</RegisterForComInterop>
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies> <GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<BaseAddress>4194304</BaseAddress> <BaseAddress>4194304</BaseAddress>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<FileAlignment>4096</FileAlignment> <FileAlignment>4096</FileAlignment>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors> <TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion> <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Debug' "> <PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
<BaseIntermediateOutputPath>obj\</BaseIntermediateOutputPath>
<IntermediateOutputPath>obj\Debug\</IntermediateOutputPath> <IntermediateOutputPath>obj\Debug\</IntermediateOutputPath>
<Optimize>False</Optimize> <Optimize>False</Optimize>
<DefineConstants>DEBUG;TRACE</DefineConstants> <DefineConstants>DEBUG;TRACE</DefineConstants>

30
src/AddIns/BackendBindings/Boo/NRefactoryToBooConverter/Project/ConvertVisitor.cs

@ -264,5 +264,35 @@ namespace NRefactoryToBooConverter
{ {
throw new NotImplementedException(); throw new NotImplementedException();
} }
public object VisitXmlAttribute(XmlAttribute xmlAttribute, object data)
{
throw new NotImplementedException();
}
public object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data)
{
throw new NotImplementedException();
}
public object VisitXmlElementExpression(XmlElementExpression xmlElementExpression, object data)
{
throw new NotImplementedException();
}
public object VisitXmlEmbeddedExpression(XmlEmbeddedExpression xmlEmbeddedExpression, object data)
{
throw new NotImplementedException();
}
public object VisitXmlLiteralExpression(XmlLiteralExpression xmlLiteralExpression, object data)
{
throw new NotImplementedException();
}
public object VisitXmlMemberAccessExpression(XmlMemberAccessExpression xmlMemberAccessExpression, object data)
{
throw new NotImplementedException();
}
} }
} }

11
src/AddIns/BackendBindings/Boo/NRefactoryToBooConverter/Test/NRefactoryToBooConverter.Tests.csproj

@ -1,4 +1,5 @@
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> <?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
<PropertyGroup> <PropertyGroup>
<OutputType>Library</OutputType> <OutputType>Library</OutputType>
<RootNamespace>NRefactoryToBooConverter.Tests</RootNamespace> <RootNamespace>NRefactoryToBooConverter.Tests</RootNamespace>
@ -12,10 +13,11 @@
<NoStdLib>False</NoStdLib> <NoStdLib>False</NoStdLib>
<DebugType>Full</DebugType> <DebugType>Full</DebugType>
<RegisterForComInterop>False</RegisterForComInterop> <RegisterForComInterop>False</RegisterForComInterop>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors> <TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<DebugSymbols>true</DebugSymbols> <DebugSymbols>true</DebugSymbols>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion> <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<WarningLevel>4</WarningLevel>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<Optimize>false</Optimize> <Optimize>false</Optimize>
@ -25,6 +27,11 @@
<Optimize>true</Optimize> <Optimize>true</Optimize>
<DefineConstants>TRACE</DefineConstants> <DefineConstants>TRACE</DefineConstants>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Platform)' == 'AnyCPU' ">
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<BaseAddress>4194304</BaseAddress>
<FileAlignment>4096</FileAlignment>
</PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="System" /> <Reference Include="System" />
<Reference Include="System.Xml" /> <Reference Include="System.Xml" />

2
src/AddIns/BackendBindings/CSharpBinding/Tests/CSharpBinding.Tests.csproj

@ -34,7 +34,7 @@
<RegisterForComInterop>False</RegisterForComInterop> <RegisterForComInterop>False</RegisterForComInterop>
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies> <GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<BaseAddress>4194304</BaseAddress> <BaseAddress>4194304</BaseAddress>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<FileAlignment>4096</FileAlignment> <FileAlignment>4096</FileAlignment>
</PropertyGroup> </PropertyGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" /> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" />

2
src/AddIns/BackendBindings/Python/Python.Build.Tasks/Test/Python.Build.Tasks.Tests.csproj

@ -33,7 +33,7 @@
<RegisterForComInterop>False</RegisterForComInterop> <RegisterForComInterop>False</RegisterForComInterop>
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies> <GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<BaseAddress>4194304</BaseAddress> <BaseAddress>4194304</BaseAddress>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<FileAlignment>4096</FileAlignment> <FileAlignment>4096</FileAlignment>
</PropertyGroup> </PropertyGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" /> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" />

2
src/AddIns/BackendBindings/Python/PythonBinding/Test/PythonBinding.Tests.csproj

@ -33,7 +33,7 @@
<RegisterForComInterop>False</RegisterForComInterop> <RegisterForComInterop>False</RegisterForComInterop>
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies> <GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<BaseAddress>4194304</BaseAddress> <BaseAddress>4194304</BaseAddress>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<FileAlignment>4096</FileAlignment> <FileAlignment>4096</FileAlignment>
</PropertyGroup> </PropertyGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" /> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" />

2
src/AddIns/BackendBindings/WixBinding/Test/WixBinding.Tests.csproj

@ -12,7 +12,7 @@
<RegisterForComInterop>False</RegisterForComInterop> <RegisterForComInterop>False</RegisterForComInterop>
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies> <GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<BaseAddress>4194304</BaseAddress> <BaseAddress>4194304</BaseAddress>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<FileAlignment>4096</FileAlignment> <FileAlignment>4096</FileAlignment>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors> <TreatWarningsAsErrors>false</TreatWarningsAsErrors>

2
src/AddIns/DisplayBindings/WpfDesign/WpfDesign.Designer/Tests/WpfDesign.Tests.csproj

@ -32,7 +32,7 @@
<RegisterForComInterop>False</RegisterForComInterop> <RegisterForComInterop>False</RegisterForComInterop>
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies> <GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<BaseAddress>4194304</BaseAddress> <BaseAddress>4194304</BaseAddress>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<FileAlignment>4096</FileAlignment> <FileAlignment>4096</FileAlignment>
</PropertyGroup> </PropertyGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" /> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" />

5
src/AddIns/Misc/ResourceToolkit/Test/ResourceToolkit.Tests.csproj

@ -1,4 +1,5 @@
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup> <PropertyGroup>
<ProjectGuid>{DD9AE6A5-2B9D-443A-BC71-38BE578C36BD}</ProjectGuid> <ProjectGuid>{DD9AE6A5-2B9D-443A-BC71-38BE578C36BD}</ProjectGuid>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
@ -30,7 +31,7 @@
<RegisterForComInterop>False</RegisterForComInterop> <RegisterForComInterop>False</RegisterForComInterop>
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies> <GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<BaseAddress>4194304</BaseAddress> <BaseAddress>4194304</BaseAddress>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<FileAlignment>4096</FileAlignment> <FileAlignment>4096</FileAlignment>
</PropertyGroup> </PropertyGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" /> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" />

5
src/AddIns/Misc/SearchAndReplace/Test/SearchAndReplace.Tests.csproj

@ -1,4 +1,5 @@
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> <?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
<PropertyGroup> <PropertyGroup>
<ProjectGuid>{A569DCC1-C608-45FD-B770-4F79335EF154}</ProjectGuid> <ProjectGuid>{A569DCC1-C608-45FD-B770-4F79335EF154}</ProjectGuid>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
@ -31,7 +32,7 @@
<RegisterForComInterop>False</RegisterForComInterop> <RegisterForComInterop>False</RegisterForComInterop>
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies> <GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<BaseAddress>4194304</BaseAddress> <BaseAddress>4194304</BaseAddress>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<FileAlignment>4096</FileAlignment> <FileAlignment>4096</FileAlignment>
</PropertyGroup> </PropertyGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" /> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.Targets" />

10
src/Libraries/NRefactory/NRefactoryASTGenerator/AST/Expressions.cs

@ -394,9 +394,11 @@ namespace NRefactoryASTGenerator.Ast
class XmlMemberAccessExpression : Expression { class XmlMemberAccessExpression : Expression {
Expression targetObject; Expression targetObject;
XmlAxisType type; XmlAxisType axisType;
bool isXmlIdentifier; bool isXmlIdentifier;
string identifier; string identifier;
public XmlMemberAccessExpression(Expression targetObject, XmlAxisType axisType, string identifier, bool isXmlIdentifier) {}
} }
abstract class XmlExpression : Expression { } abstract class XmlExpression : Expression { }
@ -404,16 +406,14 @@ namespace NRefactoryASTGenerator.Ast
class XmlLiteralExpression : Expression { class XmlLiteralExpression : Expression {
List<XmlExpression> expressions; List<XmlExpression> expressions;
} }
class XmlCommentExpression : XmlExpression {
string content;
}
enum XmlContentType { } enum XmlContentType { }
class XmlContentExpression : XmlExpression { class XmlContentExpression : XmlExpression {
string content; string content;
XmlContentType type; XmlContentType type;
public XmlContentExpression(string content, XmlContentType type) {}
} }
class XmlEmbeddedExpression : XmlExpression { class XmlEmbeddedExpression : XmlExpression {

63
src/Libraries/NRefactory/Project/Src/Ast/Generated.cs

@ -2421,12 +2421,6 @@ namespace ICSharpCode.NRefactory.Ast {
elseIfSections = new List<ElseIfSection>(); elseIfSections = new List<ElseIfSection>();
} }
public bool HasElseIfSections {
get {
return elseIfSections.Count > 0;
}
}
public bool HasElseStatements { public bool HasElseStatements {
get { get {
return falseStatement.Count > 0; return falseStatement.Count > 0;
@ -2442,6 +2436,12 @@ namespace ICSharpCode.NRefactory.Ast {
if (falseStatement != null) falseStatement.Parent = this; if (falseStatement != null) falseStatement.Parent = this;
} }
public bool HasElseIfSections {
get {
return elseIfSections.Count > 0;
}
}
public IfElseStatement(Expression condition, Statement trueStatement) public IfElseStatement(Expression condition, Statement trueStatement)
: this(condition) { : this(condition) {
@ -5515,32 +5515,6 @@ public UsingDeclaration(string @namespace, TypeReference alias) { usings = new L
} }
} }
public class XmlCommentExpression : XmlExpression {
string content;
public string Content {
get {
return content;
}
set {
content = value ?? "";
}
}
public XmlCommentExpression() {
content = "";
}
public override object AcceptVisitor(IAstVisitor visitor, object data) {
return visitor.VisitXmlCommentExpression(this, data);
}
public override string ToString() {
return string.Format("[XmlCommentExpression Content={0}]", Content);
}
}
public class XmlContentExpression : XmlExpression { public class XmlContentExpression : XmlExpression {
string content; string content;
@ -5565,8 +5539,9 @@ public UsingDeclaration(string @namespace, TypeReference alias) { usings = new L
} }
} }
public XmlContentExpression() { public XmlContentExpression(string content, XmlContentType type) {
content = ""; Content = content;
Type = type;
} }
public override object AcceptVisitor(IAstVisitor visitor, object data) { public override object AcceptVisitor(IAstVisitor visitor, object data) {
@ -5717,7 +5692,7 @@ public UsingDeclaration(string @namespace, TypeReference alias) { usings = new L
Expression targetObject; Expression targetObject;
XmlAxisType type; XmlAxisType axisType;
bool isXmlIdentifier; bool isXmlIdentifier;
@ -5733,12 +5708,12 @@ public UsingDeclaration(string @namespace, TypeReference alias) { usings = new L
} }
} }
public XmlAxisType Type { public XmlAxisType AxisType {
get { get {
return type; return axisType;
} }
set { set {
type = value; axisType = value;
} }
} }
@ -5760,9 +5735,11 @@ public UsingDeclaration(string @namespace, TypeReference alias) { usings = new L
} }
} }
public XmlMemberAccessExpression() { public XmlMemberAccessExpression(Expression targetObject, XmlAxisType axisType, string identifier, bool isXmlIdentifier) {
targetObject = Expression.Null; TargetObject = targetObject;
identifier = ""; AxisType = axisType;
Identifier = identifier;
IsXmlIdentifier = isXmlIdentifier;
} }
public override object AcceptVisitor(IAstVisitor visitor, object data) { public override object AcceptVisitor(IAstVisitor visitor, object data) {
@ -5770,8 +5747,8 @@ public UsingDeclaration(string @namespace, TypeReference alias) { usings = new L
} }
public override string ToString() { public override string ToString() {
return string.Format("[XmlMemberAccessExpression TargetObject={0} Type={1} IsXmlIdentifier={2} Identifi" + return string.Format("[XmlMemberAccessExpression TargetObject={0} AxisType={1} IsXmlIdentifier={2} Iden" +
"er={3}]", TargetObject, Type, IsXmlIdentifier, Identifier); "tifier={3}]", TargetObject, AxisType, IsXmlIdentifier, Identifier);
} }
} }

2
src/Libraries/NRefactory/Project/Src/IAstVisitor.cs

@ -263,8 +263,6 @@ namespace ICSharpCode.NRefactory {
object VisitXmlAttribute(XmlAttribute xmlAttribute, object data); object VisitXmlAttribute(XmlAttribute xmlAttribute, object data);
object VisitXmlCommentExpression(XmlCommentExpression xmlCommentExpression, object data);
object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data); object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data);
object VisitXmlElementExpression(XmlElementExpression xmlElementExpression, object data); object VisitXmlElementExpression(XmlElementExpression xmlElementExpression, object data);

32
src/Libraries/NRefactory/Project/Src/Parser/VBNet/VBNET.ATG

@ -1651,6 +1651,7 @@ Expr<out Expression expr>
QueryExpr<out expr> QueryExpr<out expr>
| LambdaExpr<out expr> | LambdaExpr<out expr>
| DisjunctionExpr<out expr> | DisjunctionExpr<out expr>
| XmlLiteralExpression<out expr>
. .
AssignmentOperator<out AssignmentOperatorType op> AssignmentOperator<out AssignmentOperatorType op>
@ -1673,12 +1674,19 @@ SimpleExpr<out Expression pexpr>
= =
SimpleNonInvocationExpression<out pexpr> SimpleNonInvocationExpression<out pexpr>
{ {
"." IdentifierOrKeyword<out name> "." (
(. pexpr = new MemberReferenceExpression(pexpr, name); .) IdentifierOrKeyword<out name>
(. pexpr = new MemberReferenceExpression(pexpr, name); .)
| XmlOpenTag IdentifierOrKeyword<out name> XmlCloseTag
(. pexpr = new XmlMemberAccessExpression(pexpr, XmlAxisType.Element, name, true); .)
)
[ IF (la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) [ IF (la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of)
"(" "Of" TypeArgumentList<((MemberReferenceExpression)pexpr).TypeArguments> ")" "(" "Of" TypeArgumentList<((MemberReferenceExpression)pexpr).TypeArguments> ")"
] ]
| "!" IdentifierOrKeyword<out name> (. pexpr = new BinaryOperatorExpression(pexpr, BinaryOperatorType.DictionaryAccess, new PrimitiveExpression(name, name)); .) | "!" IdentifierOrKeyword<out name> (. pexpr = new BinaryOperatorExpression(pexpr, BinaryOperatorType.DictionaryAccess, new PrimitiveExpression(name, name)); .)
| (. XmlAxisType type = XmlAxisType.Attribute; bool isXmlName = false; .)
( ".@" | "..." (. type = XmlAxisType.Descendents; .) ) [ XmlOpenTag (. isXmlName = true; .) ] IdentifierOrKeyword<out name> [ XmlCloseTag ]
(. pexpr = new XmlMemberAccessExpression(pexpr, type, name, isXmlName); .)
| InvocationExpression<ref pexpr> | InvocationExpression<ref pexpr>
} }
. .
@ -1749,6 +1757,26 @@ SimpleNonInvocationExpression<out Expression pexpr>
) )
. .
XmlLiteralExpression<out Expression pexpr>
(.
XmlLiteralExpression expr = pexpr = new XmlLiteralExpression();
List<XmlExpression> exprs = expr.Expressions;
XmlExpression currentExpression = null;
.)
=
(
XmlContent (. currentExpression = new XmlContentExpression(t.val, XmlContentType.Text); .)
| XmlCData (. currentExpression = new XmlContentExpression(t.val, XmlContentType.CData); .)
| XmlComment (. currentExpression = new XmlContentExpression(t.val, XmlContentType.Comment); .)
| XmlProcessingInstruction (. currentExpression = new XmlContentExpression(t.val, XmlContentType.ProcessingInstruction); .)
)
(.
currentExpression.Location = t.Location;
currentExpression.EndLocation = t.EndLocation;
exprs.Add(currentExpression);
.)
.
ConditionalExpression<out Expression expr> ConditionalExpression<out Expression expr>
(. (.
ConditionalExpression conditionalExpression = new ConditionalExpression(); ConditionalExpression conditionalExpression = new ConditionalExpression();

5
src/Libraries/NRefactory/Project/Src/Visitors/AbstractASTVisitor.cs

@ -1257,11 +1257,6 @@ namespace ICSharpCode.NRefactory.Visitors {
return xmlAttribute.ExpressionValue.AcceptVisitor(this, data); return xmlAttribute.ExpressionValue.AcceptVisitor(this, data);
} }
public virtual object VisitXmlCommentExpression(XmlCommentExpression xmlCommentExpression, object data) {
Debug.Assert((xmlCommentExpression != null));
return null;
}
public virtual object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data) { public virtual object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data) {
Debug.Assert((xmlContentExpression != null)); Debug.Assert((xmlContentExpression != null));
return null; return null;

5
src/Libraries/NRefactory/Project/Src/Visitors/AbstractAstTransformer.cs

@ -2253,11 +2253,6 @@ namespace ICSharpCode.NRefactory.Visitors {
return null; return null;
} }
public virtual object VisitXmlCommentExpression(XmlCommentExpression xmlCommentExpression, object data) {
Debug.Assert((xmlCommentExpression != null));
return null;
}
public virtual object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data) { public virtual object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data) {
Debug.Assert((xmlContentExpression != null)); Debug.Assert((xmlContentExpression != null));
return null; return null;

11
src/Libraries/NRefactory/Project/Src/Visitors/NodeTrackingAstVisitor.cs

@ -899,13 +899,6 @@ namespace ICSharpCode.NRefactory.Visitors {
return result; return result;
} }
public sealed override object VisitXmlCommentExpression(XmlCommentExpression xmlCommentExpression, object data) {
this.BeginVisit(xmlCommentExpression);
object result = this.TrackedVisitXmlCommentExpression(xmlCommentExpression, data);
this.EndVisit(xmlCommentExpression);
return result;
}
public sealed override object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data) { public sealed override object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data) {
this.BeginVisit(xmlContentExpression); this.BeginVisit(xmlContentExpression);
object result = this.TrackedVisitXmlContentExpression(xmlContentExpression, data); object result = this.TrackedVisitXmlContentExpression(xmlContentExpression, data);
@ -1444,10 +1437,6 @@ namespace ICSharpCode.NRefactory.Visitors {
return base.VisitXmlAttribute(xmlAttribute, data); return base.VisitXmlAttribute(xmlAttribute, data);
} }
public virtual object TrackedVisitXmlCommentExpression(XmlCommentExpression xmlCommentExpression, object data) {
return base.VisitXmlCommentExpression(xmlCommentExpression, data);
}
public virtual object TrackedVisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data) { public virtual object TrackedVisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data) {
return base.VisitXmlContentExpression(xmlContentExpression, data); return base.VisitXmlContentExpression(xmlContentExpression, data);
} }

4
src/Libraries/NRefactory/Project/Src/Visitors/NotImplementedAstVisitor.cs

@ -514,10 +514,6 @@ namespace ICSharpCode.NRefactory.Visitors {
throw new global::System.NotImplementedException("XmlAttribute"); throw new global::System.NotImplementedException("XmlAttribute");
} }
public virtual object VisitXmlCommentExpression(XmlCommentExpression xmlCommentExpression, object data) {
throw new global::System.NotImplementedException("XmlCommentExpression");
}
public virtual object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data) { public virtual object VisitXmlContentExpression(XmlContentExpression xmlContentExpression, object data) {
throw new global::System.NotImplementedException("XmlContentExpression"); throw new global::System.NotImplementedException("XmlContentExpression");
} }

3
src/Main/Base/Test/VBExpressionFinderTests.cs

@ -15,8 +15,7 @@ using ICSharpCode.SharpDevelop.Dom.VBNet;
namespace ICSharpCode.SharpDevelop.Tests namespace ICSharpCode.SharpDevelop.Tests
{ {
[TestFixture] [TestFixture, Ignore]
[Ignore("currently not working because VBExpressionFinder is not yet completed.")]
public class VBExpressionFinderTests public class VBExpressionFinderTests
{ {
const string program1 = @" const string program1 = @"

12
src/Main/Core/Test/ICSharpCode.Core.Tests.csproj

@ -20,23 +20,23 @@
<CheckForOverflowUnderflow>True</CheckForOverflowUnderflow> <CheckForOverflowUnderflow>True</CheckForOverflowUnderflow>
<DebugType>Full</DebugType> <DebugType>Full</DebugType>
<RegisterForComInterop>False</RegisterForComInterop> <RegisterForComInterop>False</RegisterForComInterop>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors> <TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion> <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<SignAssembly>True</SignAssembly> <SignAssembly>True</SignAssembly>
<AssemblyOriginatorKeyFile>..\..\ICSharpCode.SharpDevelop.snk</AssemblyOriginatorKeyFile> <AssemblyOriginatorKeyFile>..\..\ICSharpCode.SharpDevelop.snk</AssemblyOriginatorKeyFile>
<DelaySign>False</DelaySign> <DelaySign>False</DelaySign>
<AssemblyOriginatorKeyMode>File</AssemblyOriginatorKeyMode> <AssemblyOriginatorKeyMode>File</AssemblyOriginatorKeyMode>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugSymbols>true</DebugSymbols> <DebugSymbols>true</DebugSymbols>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Debug' "> <PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
<DefineConstants>DEBUG</DefineConstants> <DefineConstants>DEBUG</DefineConstants>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Platform)' == 'AnyCPU' ">
<GenerateSerializationAssemblies>Auto</GenerateSerializationAssemblies>
<BaseAddress>4194304</BaseAddress>
<FileAlignment>4096</FileAlignment>
</PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="System" /> <Reference Include="System" />
<Reference Include="System.Data" /> <Reference Include="System.Data" />

Loading…
Cancel
Save