Skip to content
This repository
Browse code

Added function to create a DA object to the refactoring context.

  • Loading branch information...
commit 14ca306cadab1b79e99617a7bd4870564cf9e0a7 1 parent 484c142
Mike Krüger authored April 08, 2012
19  ICSharpCode.NRefactory.CSharp/Refactoring/BaseRefactoringContext.cs
@@ -34,6 +34,7 @@
34 34
 using ICSharpCode.NRefactory.TypeSystem.Implementation;
35 35
 using ICSharpCode.NRefactory.Editor;
36 36
 using System.ComponentModel.Design;
  37
+using ICSharpCode.NRefactory.CSharp.Analysis;
37 38
 
38 39
 namespace ICSharpCode.NRefactory.CSharp.Refactoring
39 40
 {
@@ -119,7 +120,23 @@ public Conversion GetConversion (Expression expression)
119 120
 			return resolver.GetConversion(expression, cancellationToken);
120 121
 		}
121 122
 		#endregion
122  
-		
  123
+
  124
+		#region Code Analyzation
  125
+		/// <summary>
  126
+		/// Creates a new definite assignment analysis object with a given root statement.
  127
+		/// </summary>
  128
+		/// <returns>
  129
+		/// The definite assignment analysis object.
  130
+		/// </returns>
  131
+		/// <param name='root'>
  132
+		/// The root statement.
  133
+		/// </param>
  134
+		public DefiniteAssignmentAnalysis CreateDefiniteAssignmentAnalysis (Statement root)
  135
+		{
  136
+			return new DefiniteAssignmentAnalysis (root, resolver, CancellationToken);
  137
+		}
  138
+		#endregion
  139
+
123 140
 		/// <summary>
124 141
 		/// Translates the english input string to the context language.
125 142
 		/// </summary>

0 notes on commit 14ca306

Please sign in to comment.
Something went wrong with that request. Please try again.