The {} are used to disambiguate the variable name from the surrounding text. If it were simply /foo$rebar/, perl would look for a variable named $rebar instead of $re.
In reply to Re: /foo${re}bar/
by revdiablo
in thread /foo${re}bar/
by eweaverp
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |