C++ Logo

std-proposals

Advanced search

[std-proposals] MACROS

From: Abdullah Qasim <iamminecraftredstoner_at_[hidden]>
Date: Thu, 28 Apr 2022 10:55:33 +0000
In <stdlib.h>

#define repeat(INT) for(int i{ 0 }; i < INT; ++i)

#define rep() while(true)

#define until(BOOL) while(!(BOOL))

#define rep_until(BOOL, todo) \
{ \
    ##todo \
                                                             \
    while (BOOL) { \
       ##todo \
    } \
};

Received on 2022-04-28 10:55:36