Skip to content

Commit f688928

Browse files
committed
Reflect registration status when writing setLoadAction()
1 parent 5b9cb46 commit f688928

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/attributes.cpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2539,8 +2539,11 @@ namespace attributes {
25392539
ostr() << "# Register entry points for exported C++ functions"
25402540
<< std::endl;
25412541
ostr() << "methods::setLoadAction(function(ns) {" << std::endl;
2542-
ostr() << " .Call(`" << registerCCallableExportedName()
2543-
<< "`, PACKAGE = '" << package() << "')"
2542+
ostr() << " .Call("
2543+
<< (registration_ ? "`" : "'")
2544+
<< registerCCallableExportedName()
2545+
<< (registration_ ? "`" : "'")
2546+
<< ", PACKAGE = '" << package() << "')"
25442547
<< std::endl << "})" << std::endl; // #nocov end
25452548
}
25462549
}

0 commit comments

Comments
 (0)