Skip to content

Commit 09b0114

Browse files
authored
Merge pull request #241 from Shopify/emily/remove-string-exception
Remove the exception from the `extractString` method
2 parents 9c010bb + eff93cf commit 09b0114

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

parser/prism/Parser.cc

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,6 @@ std::string_view Parser::resolveConstant(pm_constant_id_t constant_id) {
2525
}
2626

2727
std::string_view Parser::extractString(pm_string_t *string) {
28-
if (string->type != pm_string_t::PM_STRING_CONSTANT && string->type != pm_string_t::PM_STRING_SHARED) {
29-
Exception::raise(
30-
"This string needs to be freed eventually with `pm_string_free`, but that isn't implemented yet");
31-
}
32-
3328
return std::string_view(reinterpret_cast<const char *>(pm_string_source(string)), pm_string_length(string));
3429
}
3530

0 commit comments

Comments
 (0)