Skip to content

Move contents of goto_program_template.cpp to goto_program.cpp #3028

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion src/goto-programs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ SRC = adjust_float_expressions.cpp \
goto_inline_class.cpp \
goto_inline.cpp \
goto_program.cpp \
goto_program_template.cpp \
goto_trace.cpp \
graphml_witness.cpp \
initialize_goto_model.cpp \
Expand Down
63 changes: 63 additions & 0 deletions src/goto-programs/goto_program.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -698,3 +698,66 @@ bool goto_programt::equals(const goto_programt &other) const

return true;
}

/// Outputs a string representation of a `goto_program_instruction_typet`
std::ostream &operator<<(std::ostream &out, goto_program_instruction_typet t)
{
switch(t)
{
case NO_INSTRUCTION_TYPE:
out << "NO_INSTRUCTION_TYPE";
break;
case GOTO:
out << "GOTO";
break;
case ASSUME:
out << "ASSUME";
break;
case ASSERT:
out << "ASSERT";
break;
case OTHER:
out << "OTHER";
break;
case DECL:
out << "DECL";
break;
case DEAD:
out << "DEAD";
break;
case SKIP:
out << "SKIP";
break;
case START_THREAD:
out << "START_THREAD";
break;
case END_THREAD:
out << "END_THREAD";
break;
case LOCATION:
out << "LOCATION";
break;
case END_FUNCTION:
out << "END_FUNCTION";
break;
case ATOMIC_BEGIN:
out << "ATOMIC_BEGIN";
break;
case ATOMIC_END:
out << "ATOMIC_END";
break;
case RETURN:
out << "RETURN";
break;
case ASSIGN:
out << "ASSIGN";
break;
case FUNCTION_CALL:
out << "FUNCTION_CALL";
break;
default:
out << "?";
}

return out;
}
42 changes: 0 additions & 42 deletions src/goto-programs/goto_program_template.cpp

This file was deleted.