消えますよ

[test.sh]
IFS=""
LF=$(printf '\012_') LF=${LF%_}
a="test$LF$LF$LF"
foo() { printf '%s' "$1"; }

printf '%s' "$a" # 1つめのテストの末尾のLFは消えていない
b="$(foo "$a")"
printf '%s' "$b" # 2つめのテストの末尾のLFは消えてる

[実行]
test.sh | hexdump -C

00000000 74 65 73 74 0a 0a 0a 74 65 73 74 |test...test|