compiler: avoid negative zero in float constants
commitcba143ad744756f751dc0f00aac377ce6587eaf6
authorian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 5 Feb 2018 15:28:59 +0000 (5 15:28 +0000)
committerian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 5 Feb 2018 15:28:59 +0000 (5 15:28 +0000)
treeb35c958fa28f08c28032e35dd056af7d988acc37
parenta9a9828b8ac9457ae5d758b08c47714216c0489a
compiler: avoid negative zero in float constants

    Check for negative numbers with very small magnitudes that will round
    to negative zero, and force them to positive zero instead.

    This implements the spec clarification in https://golang.org/cl/14727.
    The test is in https://golang.org/cl/91895.

    Fixes golang/go#12621

    Reviewed-on: https://go-review.googlesource.com/91915

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@257390 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/go/gofrontend/MERGE
gcc/go/gofrontend/expressions.cc
gcc/go/gofrontend/expressions.h