[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[IMP-dev] IMP_BEGIN_CHECK



As any of you who looked at the syntax may have noticed, the current syntax is a bit evil since you write

IMP_BEGIN_CHECK(EXPENSIVE);
some stuff which gets controlled by the surrounding statement and is in a nested scope
IMP_END_CHECK;

We want something that naturally conveys that the surrounded blocks are in a nested scope.

One possibility is something like

IMP_IF_CHECK(level)
which would expand to
if (get_check_level() > level)

So the user has to add braces to put more than one statement in there. I think I like that better and emacs does the right thing with indenting it. Any thoughts?