Skip to content

Commit

Permalink
common/get_module_from_dep- was passing the wrong value to Module.from
Browse files Browse the repository at this point in the history
  • Loading branch information
nektro committed Dec 2, 2021
1 parent 5934811 commit df9cbb3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/common.zig
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ pub fn get_module_from_dep(d: *zigmod.Dep, cachepath: string, options: *CollectO
var dd = try collect_deps(cachepath, moddir, options) catch |e| switch (e) {
error.FileNotFound => {
if (d.main.len > 0 or d.c_include_dirs.len > 0 or d.c_source_files.len > 0 or d.keep) {
var mod_from = try zigmod.Module.from(options.alloc, d.*, cachepath, options);
var mod_from = try zigmod.Module.from(options.alloc, d.*, modpath, options);
if (d.type != .local) mod_from.clean_path = u.trim_prefix(modpath, cachepath)[1..];
if (mod_from.is_for_this()) return mod_from;
return null;
Expand Down

0 comments on commit df9cbb3

Please sign in to comment.