On Tue, Mar 14, 2017 at 12:27 PM, Sebastian Lackner sebastian@fds-team.de wrote:
On 7 March 2017 at 18:29, Sebastian Lackner sebastian@fds-team.de wrote:
It can also be combined with a loop like:
for (i = 0; i < 100; i++) with_context("i = %d", i) { ... }
But e.g. "break" would be problematic inside such a loop, right?
Yes, break would be problematic, but continue for example would work fine.
As a workaround you could add a failing ok call before leaving the test explaining about the wrong usage of the macro (the context %s is still open, please fix). So it will never be commited upstream with incorrect usage. Too bad?