Gentoo Archives: gentoo-dev

From: Ulrich Mueller <ulm@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [PATCH v2] python-utils-r1.eclass: avoid nested ebegin calls
Date: Mon, 11 Jul 2022 16:56:47
Message-Id: u7d4j8u68@gentoo.org
In Reply to: Re: [gentoo-dev] [PATCH v2] python-utils-r1.eclass: avoid nested ebegin calls by Ionen Wolkens
1 >>>>> On Mon, 11 Jul 2022, Ionen Wolkens wrote:
2 >> - ebegin " python_check_deps"
3 >> - python_check_deps
4 >> - eend ${?}
5 >> + einfo " python_check_deps"
6 >> + if python_check_deps; then
7 >> + einfo " python_check_deps succeeded"
8 >> + else
9 >> + einfo " python_check_deps failed"
10 >> + fi
11 >> }
12
13 > I was about to go about merging this as suggested, but this masks the
14 > return value, and then things like this always succeed:
15
16 > if _python_run_check_deps "${impl}"; then
17
18 Maybe leave ebegin/eend in place then, which was invented precisely for
19 this use case? What's so bad about nesting it?
20
21 Ulrich

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies