Skip to content

Commit

Permalink
Update plugify
Browse files Browse the repository at this point in the history
  • Loading branch information
qubka committed Jul 14, 2024
1 parent 277bd13 commit 024da67
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
14 changes: 7 additions & 7 deletions src/module.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ LoadResult CppLanguageModule::OnPluginLoad(PluginRef plugin) {

funcErrors.clear();

std::vector<MethodRef> exportedMethods = plugin.GetDescriptor().GetExportedMethods();
std::span<const MethodRef> exportedMethods = plugin.GetDescriptor().GetExportedMethods();
std::vector<MethodData> methods;
methods.reserve(exportedMethods.size());

Expand Down Expand Up @@ -215,13 +215,13 @@ const fs::path& GetPluginBaseDir(PluginRef plugin) {
}

std::vector<std::string_view> GetPluginDependencies(PluginRef plugin) {
std::vector<PluginReferenceDescriptorRef> deps = plugin.GetDescriptor().GetDependencies();
std::vector<std::string_view> dependencies;
dependencies.reserve(deps.size());
for (const auto& dependency : deps) {
dependencies.emplace_back(dependency.GetName());
std::span<const PluginReferenceDescriptorRef> dependencies = plugin.GetDescriptor().GetDependencies();
std::vector<std::string_view> deps;
deps.reserve(dependencies.size());
for (const auto& dependency : dependencies) {
deps.emplace_back(dependency.GetName());
}
return dependencies;
return deps;
}

std::optional<fs::path> FindPluginResource(PluginRef plugin, const fs::path& path) {
Expand Down

0 comments on commit 024da67

Please sign in to comment.