Refactor LazyImportRef into ImportRefUnused. (#3656)

This makes some changes to the formatter so that ImportRefUnused and
ImportRefUsed will both be labeled as "import_ref" with an "unused ->
used" argument change in textual IR, but is otherwise not changing
logic.
This commit is contained in:
Jon Ross-Perkins
2024-01-26 03:10:00 +00:00
committed by GitHub
parent 7b933a1126
commit adad286b74
24 changed files with 96 additions and 97 deletions
+3 -3
View File
@@ -245,10 +245,10 @@ static auto GetTypePrecedence(InstKind kind) -> int {
case FieldDecl::Kind:
case FunctionDecl::Kind:
case Import::Kind:
case ImportRefUnused::Kind:
case InitializeFrom::Kind:
case InterfaceDecl::Kind:
case IntLiteral::Kind:
case LazyImportRef::Kind:
case Namespace::Kind:
case Param::Kind:
case RealLiteral::Kind:
@@ -451,10 +451,10 @@ auto File::StringifyTypeExpr(InstId outer_inst_id) const -> std::string {
case FieldDecl::Kind:
case FunctionDecl::Kind:
case Import::Kind:
case ImportRefUnused::Kind:
case InitializeFrom::Kind:
case InterfaceDecl::Kind:
case IntLiteral::Kind:
case LazyImportRef::Kind:
case Namespace::Kind:
case Param::Kind:
case RealLiteral::Kind:
@@ -509,8 +509,8 @@ auto GetExprCategory(const File& file, InstId inst_id) -> ExprCategory {
case FieldDecl::Kind:
case FunctionDecl::Kind:
case Import::Kind:
case ImportRefUnused::Kind:
case InterfaceDecl::Kind:
case LazyImportRef::Kind:
case Namespace::Kind:
case Return::Kind:
case ReturnExpr::Kind: