
20 Apr
2009
20 Apr
'09
2:28 p.m.
Sid Sacek <ssacek <at> securewatch24.com> writes:
struct {
int one;
} test ;
test.one = 55;
BOOST_SCOPE_EXIT( ( test.one ) )
{
}
BOOST_SCOPE_EXIT_END
The above code gives me lots of compiler errors. Is there a special syntax I have to provide to be able to use structure members?
This is not supported because only identifiers are allowed. If test was a variable of non-local non-anonymous struct type, you could pass it: BOOST_SCOPE_EXIT( (test ) ) { int one = test.one; ... } BOOST_SCOPE_EXIT_END Alex