Skip to content

Commit

Permalink
Allow constructing an IR::ID from a std::string (#4549)
Browse files Browse the repository at this point in the history
- also add missing `override` (fix warning)

Co-authored-by: Chris Dodd <[email protected]>
  • Loading branch information
ChrisDodd and ChrisDodd authored Mar 20, 2024
1 parent 814ff5b commit 87f8353
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions ir/id.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ struct ID : Util::IHasSourceInfo {
}
ID(const char *n) : ID(Util::SourceInfo(), n) {} // NOLINT(runtime/explicit)
ID(cstring n) : ID(Util::SourceInfo(), n) {} // NOLINT(runtime/explicit)
ID(std::string n) : ID(Util::SourceInfo(), n) {} // NOLINT(runtime/explicit)
ID(cstring n, cstring old) : ID(Util::SourceInfo(), n, old) {}
void dbprint(std::ostream &out) const {
out << name;
Expand Down

0 comments on commit 87f8353

Please sign in to comment.