Quadratic Micropass Type Inference