| 151 | } |
| 152 | |
| 153 | std::string Regexp::Dump() { |
| 154 | // Make sure that we are being called from a unit test. |
| 155 | // Should cause a link error if used outside of testing. |
| 156 | CHECK(!::testing::TempDir().empty()); |
| 157 | |
| 158 | std::string s; |
| 159 | DumpRegexpAppending(this, &s); |
| 160 | return s; |
| 161 | } |
| 162 | |
| 163 | } // namespace re2 |