use constant HALFPI => ( PI / 2.0 ) ; to use constant HALFPI => { 0.5 * PI } ;