An Abstract Interpretation Framework for Type and Effect Systems