Optimize NodePath.prototype.needsParens by switching on .type.