]> Git Repo - qemu.git/commit - target-ppc/dfp_helper.c
target-ppc: Fix compiler warning
authorStefan Weil <[email protected]>
Tue, 17 Jun 2014 17:18:28 +0000 (19:18 +0200)
committerMichael Tokarev <[email protected]>
Tue, 24 Jun 2014 16:01:24 +0000 (20:01 +0400)
commit0211b5cf2d933e10b5916b203fc3fad805a9a3c0
treef1489e1f0ed3121bf0e95180e803938733f711bc
parente91c793cb50b83a695bbbf677ebfff478d8c62f2
target-ppc: Fix compiler warning

gcc reports a warning which is usually wrong:

target-ppc/dfp_helper.c: In function ‘dfp_get_digit’:
target-ppc/dfp_helper.c:417:1: warning:
 control reaches end of non-void function [-Wreturn-type]

The compiler shows the warning if assert is not marked with the noreturn
attribute or if the code is compiled with -DNDEBUG.

Using g_assert_not_reached better documents the intention and does not
have these problems.

Signed-off-by: Stefan Weil <[email protected]>
Reviewed-by: Alexander Graf <[email protected]>
Signed-off-by: Michael Tokarev <[email protected]>
target-ppc/dfp_helper.c
This page took 0.0257 seconds and 4 git commands to generate.