From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andy Wingo Subject: Re: question regarding substitute* and #t Date: Wed, 24 Jan 2018 16:20:36 +0100 Message-ID: <87y3kn706z.fsf@igalia.com> References: <20180124010802.18874.3012@vcs0.savannah.gnu.org> <20180124010803.590AF2068F@vcs0.savannah.gnu.org> <874lnbzck5.fsf_-_@netris.org> <87372v8ndd.fsf_-_@igalia.com> <87h8rbtmhl.fsf@netris.org> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:39775) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eeMr6-00073m-B9 for guix-devel@gnu.org; Wed, 24 Jan 2018 10:20:53 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eeMr2-0006Xk-5T for guix-devel@gnu.org; Wed, 24 Jan 2018 10:20:52 -0500 Received: from pb-sasl1.pobox.com ([64.147.108.66]:59688 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eeMr2-0006Wf-0r for guix-devel@gnu.org; Wed, 24 Jan 2018 10:20:48 -0500 In-Reply-To: <87h8rbtmhl.fsf@netris.org> (Mark H. Weaver's message of "Wed, 24 Jan 2018 08:28:06 -0500") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Mark H Weaver Cc: guix-devel@gnu.org On Wed 24 Jan 2018 14:28, Mark H Weaver writes: > Andy Wingo writes: > >> On Wed 24 Jan 2018 13:06, Mark H Weaver writes: >> >>> + ;; Install to the right directory >>> + (substitute* '("Makefile" >>> + "Qsci/Makefile") >>> + (("\\$\\(INSTALL_ROOT\\)/gnu/store/[^/]+") >>> + (assoc-ref outputs "out"))) >>> + #t))))) >> >> I guess once we switch over all instances of "system" and "system*" to >> use invoke, does that mean we will also be able to remove these >> vestigial "#t" returns? > > After we switch to using 'invoke' everywhere, or more precisely, after > we arrange to never return #false from any phase or snippet, then there > should be one more step before removing the vestigial #true returns: we > should change the code that calls phases or snippets to ignore the > value(s) returned by those procedures. When that is done, then the #t's > will truly be vestigial. Does that make sense? Sure, makes sense. Thanks for thinking it through with me :) Andy