Return-Path: Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by lists.linuxfoundation.org (Postfix) with ESMTP id A631FC0032 for ; Fri, 11 Aug 2023 13:45:39 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 6B16C40580 for ; Fri, 11 Aug 2023 13:45:39 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 6B16C40580 Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key) header.d=mail.wpsoftware.net header.i=@mail.wpsoftware.net header.a=rsa-sha256 header.s=default header.b=UpqR9ka0 X-Virus-Scanned: amavisd-new at osuosl.org X-Spam-Flag: NO X-Spam-Score: -1.107 X-Spam-Level: X-Spam-Status: No, score=-1.107 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=no autolearn_force=no Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id MjBU7iNhLRmE for ; Fri, 11 Aug 2023 13:45:38 +0000 (UTC) Received: from mail.wpsoftware.net (unknown [66.183.0.205]) by smtp4.osuosl.org (Postfix) with ESMTP id 2215F4054C for ; Fri, 11 Aug 2023 13:45:37 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 2215F4054C Received: from camus (camus-andrew.lan [192.168.0.190]) by mail.wpsoftware.net (Postfix) with ESMTPSA id 0893D40095; Fri, 11 Aug 2023 13:45:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mail.wpsoftware.net; s=default; t=1691761537; bh=D30qY9OOKL8Ds2mLmVyMeRTGFRQcd4bZbdt/6Bfw+DY=; h=Date:From:To:Subject:References:In-Reply-To; b=UpqR9ka0TSSp5ciYS4w2t8nZLoDdAN0XwRgWIYwCh4A7Y/f7Lpk4qUJKmhWr8YG4Q DR5OuZQx+q7a6L1JRQu3UVxMpyBweD4TKKRBy+5QVPFS5n6/NXZ23fEGrdEbC7BZad NL57twa6NrGej/R5ea+BFv/MzsIeoH1U0oM2JpsoUKpipZh7YWpnyAi1MxuF6k54vm MmZul7OHghRrXJROw2MRaekHDDsg5/H7IUEf/UHxeWDGNR38VWix+T/4wVVWSvCMZv xbwZWfQ6DGEGpsAX9+2EQkD4L6hS1/B83WyfGyYbzhbb7AMoexiTjHPkSgv9r9mf07 IC1aYq/ZMRsPQ== Date: Fri, 11 Aug 2023 13:45:35 +0000 From: Andrew Poelstra To: Tobin Harding , Bitcoin Protocol Discussion Message-ID: References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="XxnP3vfVQL6HUXlF" Content-Disposition: inline In-Reply-To: Subject: Re: [bitcoin-dev] segwit naming ambiguity X-BeenThere: bitcoin-dev@lists.linuxfoundation.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Bitcoin Protocol Discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Aug 2023 13:45:39 -0000 --XxnP3vfVQL6HUXlF Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Aug 11, 2023 at 02:45:57PM +1000, Tobin Harding via bitcoin-dev wro= te: > Question for OG bitcoin API designers please. >=20 > If you were to see the following function >=20 > `is_segwit()` >=20 > would you assume it returns `true` or `false` for a p2tr transaction? >=20 >=20 > Currently we (rust-bitcoin) are being liberal with the use of `v0` but > its a pretty ugly. Is there an official, or widely used, name for segwit = v0? > As others have said, I think `is_segwit` should match all segwit versions. Pavol also sorta answered your "widely used name" question though he didn't draw attention to it -- segwit v0 outputs are called "p2wsh" or "p2wpkh". But I don't know any term that covers "p2wsh or p2wpkh but not p2tr". Other than "segwit_v0", which we are currently using, and which I agree is a bit of a mouthful. --=20 Andrew Poelstra Director of Research, Blockstream Email: apoelstra at wpsoftware.net Web: https://www.wpsoftware.net/andrew The sun is always shining in space -Justin Lewis-Webster --XxnP3vfVQL6HUXlF Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEkPnKPD7Je+ki35VexYjWPOQbl8EFAmTWO38ACgkQxYjWPOQb l8HAvwgAl7rgvJq+5cZCenntjwaa6lKnriNerZZ5G+kuwCbkhUS63bisLeNKhzu1 gRUHRnfLpJIWVaN2Qg0is5KmNl06Gz0MjAmlKEz/To2u9KfkvJL2kXRdMDhFOUeW Ku7UHc8ey02ASUJeguG2IFuOWAgKPSIubxJRCnffoDssy89Zm40fWfX8EE5cMMog 4fD8IZbziOGxJ0XDj43P8pkeHOoYhpYq+3I8FpV+DX7EtV8R0ZZ/SFB8QrSeg/jW 2422lUApKxB5LDdCOGl8j56cITyrbWyC4fHBH9kUMx5J075PXze/mcL+s6kyFCTB IrtySiue2WdsVGgPv7fsmiKpFz2yBg== =/lX4 -----END PGP SIGNATURE----- --XxnP3vfVQL6HUXlF--