Home | History | Annotate | Line # | Download | only in indent
lsym_funcname.c revision 1.6
      1  1.6  rillig /* $NetBSD: lsym_funcname.c,v 1.6 2023/06/15 09:19:07 rillig Exp $ */
      2  1.1  rillig 
      3  1.1  rillig /*
      4  1.5  rillig  * Tests for the token lsym_funcname, which is the name of a function, but only
      5  1.5  rillig  * in a function definition, not in a declaration or a call expression.
      6  1.4  rillig  *
      7  1.1  rillig  * See also:
      8  1.1  rillig  *	lsym_word.c
      9  1.1  rillig  */
     10  1.1  rillig 
     11  1.3  rillig //indent input
     12  1.4  rillig void
     13  1.4  rillig function(void)
     14  1.4  rillig {
     15  1.4  rillig 	func();
     16  1.4  rillig 	(func)();
     17  1.4  rillig 	func(1, 2, 3);
     18  1.4  rillig }
     19  1.3  rillig //indent end
     20  1.1  rillig 
     21  1.3  rillig //indent run-equals-input
     22  1.6  rillig 
     23  1.6  rillig 
     24  1.6  rillig /*
     25  1.6  rillig  * The comment after the return type of a function definition is a code
     26  1.6  rillig  * comment, not a declaration comment.
     27  1.6  rillig  */
     28  1.6  rillig //indent input
     29  1.6  rillig void				// comment
     30  1.6  rillig function_with_comment(void)
     31  1.6  rillig {
     32  1.6  rillig }
     33  1.6  rillig //indent end
     34  1.6  rillig 
     35  1.6  rillig //indent run-equals-input
     36