pub fn rtrim(s: &str, writer: &mut impl Write)Expand description
Note: the behavior of rtrim in PostgreSQL and trim_end (or trim_right) in Rust
are actually different when the string is in right-to-left languages like Arabic or Hebrew.
Since we would like to simplify the implementation, currently we omit this case.