1 2f1() 3{ 4 cat<<EOF 5EOF 6}; 7 8f2(){ :; } 9cat<<EOF 10bug2(){ :; } 11EOF 12 13f3(){ :; } 14cat<<"EOF" 15bug3(){ :; } 16EOF 17 18f4(){ :; } 19cat<<'EOF' 20bug4(){ :; } 21EOF 22 23f5(){ :; } 24cat<<'End Of File' 25bug5(){ :; } 26End Of File 27 28f6(){ :; } 29cat<<EOF 30this isn't terminated 31 32EOF#test 33 EOF 34 35bug6(){ :; } 36EOF 37 38f7(){ :; } 39cat<<"End Of \"File\"" 40bug7(){ :; } 41End Of "File" 42 43f8(){ :; } 44# this is valid, the heredoc starts on the next line after the <<DELIM 45cat<<EOF; fancy() { echo hello; } 46bug8(){ :; } 47EOF 48 49f9(){ :; } 50cat<<-EOF 51 bug9(){ :; } 52 this isn't the end, only tabulations are stripped, not spaces 53 EOF 54 EOF 55 56f10(){ :; } 57cat << EOF 58bug10(){ :; } 59EOF 60 61f11(){ :; } 62cat << EOF 63bug11(){ :; } 64EOF 65 66f12(){ :; } 67# this is not an indented here-document but a "-EOF" delimiter 68cat << -EOF 69bug12(){ :; } 70-EOF 71 72f13(){ :; } 73# quoted empty delimiters are valid 74cat <<'' 75bug13(){ :; } 76 77 78f14(){ :; } 79cat <<"" 80bug14(){ :; } 81 82 83f15(){ :; } 84cat <<-"" 85bug15(){ :; } 86 87 88f16(){ :; } 89 90fancy 91