Home | History | Annotate | Line # | Download | only in indent
lsym_do.c revision 1.4
      1 /* $NetBSD: lsym_do.c,v 1.4 2022/04/24 10:36:37 rillig Exp $ */
      2 
      3 /*
      4  * Tests for the token lsym_do, which represents the keyword 'do' that starts
      5  * a 'do-while' loop.
      6  *
      7  * See also:
      8  *	psym_do.c
      9  *	psym_do_stmt.c
     10  *	C11 6.8.5		"Iteration statements"
     11  *	C11 6.8.5.2		"The 'do' statement"
     12  */
     13 
     14 //indent input
     15 void
     16 function(void)
     17 {
     18 	do stmt();while(cond);
     19 }
     20 //indent end
     21 
     22 //indent run
     23 void
     24 function(void)
     25 {
     26 	do
     27 		stmt();
     28 	while (cond);
     29 }
     30 //indent end
     31