@@ -224,7 +224,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
224224 {
225225 if ( _qualifiedSelection . Selection . Contains ( context ) )
226226 {
227- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasErrorStatement ) ) ;
227+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "Error" ) ) ) ;
228228 return null ;
229229 }
230230
@@ -235,7 +235,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
235235 {
236236 if ( _qualifiedSelection . Selection . Contains ( context ) )
237237 {
238- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasEndStatement ) ) ;
238+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "End" ) ) ) ;
239239 return null ;
240240 }
241241
@@ -246,7 +246,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
246246 {
247247 if ( _qualifiedSelection . Selection . Contains ( context ) )
248248 {
249- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasExitStatement ) ) ;
249+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "Exit" ) ) ) ;
250250 return null ;
251251 }
252252
@@ -257,7 +257,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
257257 {
258258 if ( _qualifiedSelection . Selection . Contains ( context ) )
259259 {
260- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasGoSubStatement ) ) ;
260+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "GoSub" ) ) ) ;
261261 return null ;
262262 }
263263
@@ -268,7 +268,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
268268 {
269269 if ( _qualifiedSelection . Selection . Contains ( context ) )
270270 {
271- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasGoToStatement ) ) ;
271+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "GoTo" ) ) ) ;
272272 return null ;
273273 }
274274
@@ -279,7 +279,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
279279 {
280280 if ( _qualifiedSelection . Selection . Contains ( context ) )
281281 {
282- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasOnErrorStatement ) ) ;
282+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "On Error" ) ) ) ;
283283 return null ;
284284 }
285285
@@ -290,7 +290,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
290290 {
291291 if ( _qualifiedSelection . Selection . Contains ( context ) )
292292 {
293- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasLineLabelStatement ) ) ;
293+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "line label" ) ) ) ;
294294 return null ;
295295 }
296296
@@ -301,7 +301,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
301301 {
302302 if ( _qualifiedSelection . Selection . Contains ( context ) )
303303 {
304- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasLineLabelStatement ) ) ;
304+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "line label" ) ) ) ;
305305 return base . VisitCombinedLabels ( context ) ;
306306 }
307307
@@ -312,7 +312,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
312312 {
313313 if ( _qualifiedSelection . Selection . Contains ( context ) )
314314 {
315- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasLineLabelStatement ) ) ;
315+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "line label" ) ) ) ;
316316 return null ;
317317 }
318318
@@ -323,7 +323,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
323323 {
324324 if ( _qualifiedSelection . Selection . Contains ( context ) )
325325 {
326- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasOnGosubStatement ) ) ;
326+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "On...GoSub" ) ) ) ;
327327 return null ;
328328 }
329329
@@ -334,7 +334,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
334334 {
335335 if ( _qualifiedSelection . Selection . Contains ( context ) )
336336 {
337- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasOnGoToStatement ) ) ;
337+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "On...GoTo" ) ) ) ;
338338 return null ;
339339 }
340340
@@ -345,7 +345,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
345345 {
346346 if ( _qualifiedSelection . Selection . Contains ( context ) )
347347 {
348- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasResumeStatement ) ) ;
348+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "Resume" ) ) ) ;
349349 return null ;
350350 }
351351
@@ -356,7 +356,7 @@ protected override bool ShouldVisitNextChild(IRuleNode node, IEnumerable<VBAPars
356356 {
357357 if ( _qualifiedSelection . Selection . Contains ( context ) )
358358 {
359- InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasReturnStatement ) ) ;
359+ InvalidContexts . Add ( Tuple . Create ( context as ParserRuleContext , string . Format ( RefactoringsUI . ExtractMethod_InvalidMessageSelectionHasUnsupportedStatement , "Return" ) ) ) ;
360360 return null ;
361361 }
362362
0 commit comments