Add Field to store BraceIndentInfo

This commit is contained in:
Stefan Koch 2018-02-28 17:27:36 +01:00 committed by The Dlang Bot
parent b01c624ef0
commit c4a7f9cb04
1 changed files with 8 additions and 0 deletions

View File

@ -8,6 +8,12 @@ module dfmt.ast_info;
import dparse.lexer;
import dparse.ast;
struct BraceIndentInfo
{
size_t startLocation;
size_t endLocation;
}
/// AST information that is needed by the formatter.
struct ASTInformation
{
@ -85,6 +91,8 @@ struct ASTInformation
/// Locations of constructor/destructor "this" tokens ?
size_t[] constructorDestructorLocations;
BraceIndentInfo[] sortedByStartLocation;
}
/// Collects information from the AST that is useful for the formatter