in reply to Re: Is { } an empty block or a bug in perl?
in thread Is { } an empty block or a bug in perl?

I would argue that it is not well written code.

This website is frequently the meeting place for showdowns about "show-off perl" vs "safe perl" programming.

I often write an empty block as follows:

{ ; }
usually for the following
if ($condition_that_should_return_true) { ; # success! } elsif (...) . .

If you are coding in a manner than can be interpreted a multiple number of ways depending on context, then you should either code within the context, or avoid expressing your statement when you're unsure of the context.

I suggest you have a read of Code Complete. It may make you aware of some programming methodologies that will help you avoid unsafe programming.