private static Selection GetStmtContextSelection(Declaration target) { switch (target.DeclarationType) { case DeclarationType.Variable: return(target.GetVariableStmtContextSelection()); case DeclarationType.Constant: return(target.GetConstStmtContextSelection()); default: return(target.Context.GetSelection()); } }
private Selection GetStmtContextSelection(Declaration target) { return(target.DeclarationType == DeclarationType.Variable ? target.GetVariableStmtContextSelection() : target.GetConstStmtContextSelection()); }