Use package name instead of target name for --package filter

This commit is contained in:
Seiichi Uchida 2017-12-06 12:41:04 +09:00
parent b07e4339f0
commit b8448f6223

View File

@ -290,8 +290,8 @@ fn get_targets_with_hitlist(
let mut workspace_hitlist: HashSet<&String> = HashSet::from_iter(hitlist);
for package in metadata.packages {
for target in package.targets {
if workspace_hitlist.remove(&target.name) {
if workspace_hitlist.remove(&package.name) {
for target in package.targets {
targets.insert(Target::from_target(&target));
}
}