Skip to content

Commit a4eb3ce

Browse files
committed
fixup! deps: update merve to 1.2.0
1 parent afcff17 commit a4eb3ce

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

src/node_cjs_lexer.cc

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,6 @@
66

77
#include "merve.h"
88

9-
#ifdef MERVE_ERROR_TODO
10-
#define DOT_NAME(exp) (exp.name)
11-
#else
12-
#define DOT_NAME(exp) (exp)
13-
#endif
14-
159
namespace node {
1610
namespace cjs_lexer {
1711

@@ -28,8 +22,9 @@ using v8::String;
2822
using v8::Value;
2923

3024
// Create a V8 string from an export_string variant, using fast path for ASCII
25+
template <typename T>
3126
inline Local<String> CreateString(Isolate* isolate,
32-
const lexer::export_string& str) {
27+
const T& str) {
3328
std::string_view sv = lexer::get_string_view(str);
3429

3530
if (simdutf::validate_ascii(sv.data(), sv.size())) {
@@ -77,15 +72,14 @@ void Parse(const FunctionCallbackInfo<Value>& args) {
7772
// Convert exports to JS Set
7873
Local<Set> exports_set = Set::New(isolate);
7974
for (const auto& exp : analysis.exports) {
80-
exports_set->Add(context, CreateString(isolate, DOT_NAME(exp)))
81-
.ToLocalChecked();
75+
exports_set->Add(context, CreateString(isolate, exp)).ToLocalChecked();
8276
}
8377

8478
// Convert reexports to JS array using batch creation
8579
LocalVector<Value> reexports_vec(isolate);
8680
reexports_vec.reserve(analysis.re_exports.size());
8781
for (const auto& reexp : analysis.re_exports) {
88-
reexports_vec.push_back(CreateString(isolate, DOT_NAME(reexp)));
82+
reexports_vec.push_back(CreateString(isolate, reexp));
8983
}
9084

9185
// Create result array [exports (Set), reexports (Array)]

0 commit comments

Comments
 (0)