When #region a is selected it is expected, that next selection should be content of region "b" without region/endregion directives
#region b
if (statement.GetTreeStartOffset() >= maxOffset) break;
#region a
if (statement == declarationStatement)
{
startCollecting = true;
continue;
}
if (!startCollecting) continue;
IDeclarationStatement declStmt = statement as IDeclarationStatement;
#endregion
if (declStmt == null) continue;
#endregion