unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Maxime Devos <maximedevos@telenet.be>
To: 57718@debbugs.gnu.org
Cc: Maxime Devos <maximedevos@telenet.be>
Subject: [bug#57718] [PATCH 3/3] daemon: Remove unused function findOutput.
Date: Sat, 10 Sep 2022 19:20:40 +0200	[thread overview]
Message-ID: <20220910172040.6469-3-maximedevos@telenet.be> (raw)
In-Reply-To: <20220910172040.6469-1-maximedevos@telenet.be>

* nix/libstore/misc.cc (findOutput): Remove it.
* nix/libstore/misc.hh (findOutput): Likewise.
---
 nix/libstore/misc.cc | 8 --------
 nix/libstore/misc.hh | 4 ----
 2 files changed, 12 deletions(-)

diff --git a/nix/libstore/misc.cc b/nix/libstore/misc.cc
index 97618089bd..d4e6d1b4af 100644
--- a/nix/libstore/misc.cc
+++ b/nix/libstore/misc.cc
@@ -59,14 +59,6 @@ void computeFSClosure(StoreAPI & store, const Path & path,
 }
 
 
-Path findOutput(const Derivation & drv, string id)
-{
-    foreach (DerivationOutputs::const_iterator, i, drv.outputs)
-        if (i->first == id) return i->second.path;
-    throw Error(format("derivation has no output `%1%'") % id);
-}
-
-
 static void dfsVisit(StoreAPI & store, const PathSet & paths,
     const Path & path, PathSet & visited, Paths & sorted,
     PathSet & parents)
diff --git a/nix/libstore/misc.hh b/nix/libstore/misc.hh
index edbf24047e..f70cda9fd0 100644
--- a/nix/libstore/misc.hh
+++ b/nix/libstore/misc.hh
@@ -21,10 +21,6 @@ void computeFSClosure(StoreAPI & store, const Path & path,
     PathSet & paths, bool flipDirection = false,
     bool includeOutputs = false, bool includeDerivers = false);
 
-/* Return the path corresponding to the output identifier `id' in the
-   given derivation. */
-Path findOutput(const Derivation & drv, string id);
-
 bool willBuildLocally(const Derivation & drv);
 
 bool substitutesAllowed(const Derivation & drv);
-- 
2.37.2





  parent reply	other threads:[~2022-09-10 17:22 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-10 17:18 [bug#57718] [PATCH 0/3] daemon: Remove unused code Maxime Devos
2022-09-10 17:20 ` [bug#57718] [PATCH 1/3] daemon: Remove unused function openStore Maxime Devos
2022-09-10 17:20   ` [bug#57718] [PATCH 2/3] daemon: Remove unused function exportPaths Maxime Devos
2022-09-10 17:20   ` Maxime Devos [this message]
2022-09-11 13:54     ` bug#57718: [PATCH 0/3] daemon: Remove unused code Mathieu Othacehe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220910172040.6469-3-maximedevos@telenet.be \
    --to=maximedevos@telenet.be \
    --cc=57718@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).