This is a combination of two extremely Frequently A'd Qs.
- finite floating-point precision: this R FAQ 7.31, see e.g. Why are these numbers not equal? . The value gets rounded to 178379.5. It won't help if you set
options(digits=22)
to print numbers to more decimal places; the precision has been lost because (as you suggested) R only stores values up to 53 binary/22ish decimal digits of precision.
- round to even: R "rounds to even", see Is there an error in round function in R? . That means the value will be rounded up.
This is not about printing precision.
If you had used fewer '9's, you would have seen what you expected (which would be a combination of R's limited printing precision plus the expected rounding)
> x <- 178379.49
>
> x
[1] 178379.5 ## prints as .5, but full precision is present
> round(x)
[1] 178379