Replace int lines with file-associated SourceLocations (#779)

Most interesting changes should be ast/source_location.h and syntax/parse_and_lex_context.h
This commit is contained in:
Jon Meow
2021-08-26 10:07:16 -07:00
committed by GitHub
parent 33daf64329
commit 3ec550a85f
46 changed files with 607 additions and 518 deletions
+5 -4
View File
@@ -2,22 +2,23 @@
// Exceptions. See /LICENSE for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
#ifndef EXECUTABLE_SEMANTICS_AST_STRUCT_DEFINITION_H_
#define EXECUTABLE_SEMANTICS_AST_STRUCT_DEFINITION_H_
#ifndef EXECUTABLE_SEMANTICS_AST_CLASS_DEFINITION_H_
#define EXECUTABLE_SEMANTICS_AST_CLASS_DEFINITION_H_
#include <list>
#include <string>
#include "executable_semantics/ast/member.h"
#include "executable_semantics/ast/source_location.h"
namespace Carbon {
struct ClassDefinition {
int line_num;
SourceLocation loc;
std::string name;
std::list<Member*> members;
};
} // namespace Carbon
#endif // EXECUTABLE_SEMANTICS_AST_STRUCT_DEFINITION_H_
#endif // EXECUTABLE_SEMANTICS_AST_CLASS_DEFINITION_H_