Home | History | Annotate | Line # | Download | only in indent
lsym_lbrace.c revision 1.2
      1  1.2  rillig /* $NetBSD: lsym_lbrace.c,v 1.2 2021/11/20 16:54:17 rillig Exp $ */
      2  1.1  rillig /* $FreeBSD$ */
      3  1.1  rillig 
      4  1.1  rillig /*
      5  1.1  rillig  * Tests for the token lsym_lbrace, which represents a '{' in these contexts:
      6  1.1  rillig  *
      7  1.1  rillig  * In an initializer, '{' starts an inner group of initializers, usually to
      8  1.1  rillig  * initialize a nested struct, union or array.
      9  1.1  rillig  *
     10  1.1  rillig  * In a function body, '{' starts a block.
     11  1.1  rillig  *
     12  1.1  rillig  * In an expression, '(type){' starts a compound expression that is typically
     13  1.1  rillig  * used in an assignment to a struct or array.
     14  1.2  rillig  *
     15  1.2  rillig  * TODO: try to split this token into lsym_lbrace_block and lsym_lbrace_init.
     16  1.1  rillig  */
     17  1.1  rillig 
     18  1.1  rillig #indent input
     19  1.1  rillig // TODO: add input
     20  1.1  rillig #indent end
     21  1.1  rillig 
     22  1.1  rillig #indent run-equals-input
     23