Skip to content
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

SMV: set pretty names for top-level identifiers #452

Merged
merged 1 commit into from
Apr 23, 2024
Merged

Conversation

kroening
Copy link
Member

Identifiers in module main now no longer carry the prefix main::var::.

@kroening kroening marked this pull request as ready for review April 21, 2024 23:10
@kroening kroening force-pushed the smvlang-pretty-names branch from d1674c9 to 5728a30 Compare April 22, 2024 00:56
@tautschnig
Copy link
Collaborator

Rebase required to resolve conflicts.

Identifiers in module main now no longer carry the prefix main::var::.
@kroening kroening force-pushed the smvlang-pretty-names branch from 5728a30 to 3ec49b5 Compare April 22, 2024 15:44
@kroening
Copy link
Member Author

done

bool type2smv(const typet &type, std::string &code);

bool expr2smv(const exprt &, std::string &code, const namespacet &);
bool type2smv(const typet &, std::string &code, const namespacet &);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not for this PR, but rather asking about potential future work: Is bool really the appropriate return type? Shouldn't places that return true really be using UNIMPLEMENTED instead? Then the return type could instead be std::string.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another option would be to send anything that that code doesn't know how to format to format_expr.

Comment on lines +175 to +176
symbol_tablet symbol_table;
namespacet ns(symbol_table);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we really not have a symbol table or namespace available when invoking show_parse?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this is pre typechecking.

@kroening kroening merged commit 3c31174 into main Apr 23, 2024
5 checks passed
@kroening kroening deleted the smvlang-pretty-names branch April 23, 2024 21:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants