On discriminant-like polynomials