
on Mon Aug 20 2007, Alexander Nasonov <alnsn-AT-yandex.ru> wrote:
2. Unusual syntax, both for me and someone who would later work on my code. Using preprocessor sequence and having BOOST_SCOPE_EXIT_END after {} braces looks so unnatural in C++.
Have you tried boost.lambda? I bet you will feel comfortable with ScopeExit syntax after writing 10 ScopeExit bodies but mastering lambda skills would take a month. I spent 5 minutes writing and debugging lambda for Alternatives.ScopeGuard section but it took me only 10 seconds to type ScopeExit.
I haven't often found myself in need of something like ScopeGuard/ScopeExit, but I am convinced that some people find it indispensible. I encourage those people to give the macros a chance, because what Alexander says about writing lambda expressions definitely rings true. -- Dave Abrahams Boost Consulting http://www.boost-consulting.com The Astoria Seminar ==> http://www.astoriaseminar.com