Contents | Prev | Next

18.37 Problems with round

Official Description

6.6.6.3 For round(x), if x is positive or zero then round(x) is equivalent to trunc(x+0.5), otherwise round(x) is equivalent to trunc(x-0.5). It is an error if such a value does not exist.

Simplified Description

In other words, it is an error to use the round function to convert a value of real type into a value of integral type, if the real value is outside the range of integral values supported by Irie Pascal. For example

   round(1.0e16)

is an error.

Error Handling

This error is never reported.

Contents | Prev | Next