Re: draft-ietf-httpbis-header-structure-15, Serializing a Decimal

Mark Nottingham <mnot@mnot.net> Wed, 29 January 2020 22:23 UTC

Return-Path: <ietf-http-wg-request+bounce-httpbisa-archive-bis2juki=lists.ie@listhub.w3.org>
X-Original-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Delivered-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id EDA29120013 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Wed, 29 Jan 2020 14:23:36 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -7.748
X-Spam-Level:
X-Spam-Status: No, score=-7.748 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.25, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=mnot.net header.b=YXBXU4i/; dkim=pass (2048-bit key) header.d=messagingengine.com header.b=n8iSNGsP
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id a9UPX9KZOURm for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Wed, 29 Jan 2020 14:23:34 -0800 (PST)
Received: from frink.w3.org (frink.w3.org [128.30.52.56]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id F07B4120045 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Wed, 29 Jan 2020 14:23:33 -0800 (PST)
Received: from lists by frink.w3.org with local (Exim 4.89) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1iwvjT-0007lT-Vn for ietf-http-wg-dist@listhub.w3.org; Wed, 29 Jan 2020 22:22:47 +0000
Resent-Date: Wed, 29 Jan 2020 22:22:47 +0000
Resent-Message-Id: <E1iwvjT-0007lT-Vn@frink.w3.org>
Received: from mimas.w3.org ([2603:400a:ffff:804:801e:34:0:4f]) by frink.w3.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from <mnot@mnot.net>) id 1iwvjS-0007kM-4n for ietf-http-wg@listhub.w3.org; Wed, 29 Jan 2020 22:22:46 +0000
Received: from out2-smtp.messagingengine.com ([66.111.4.26]) by mimas.w3.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from <mnot@mnot.net>) id 1iwvjP-0002n5-QF for ietf-http-wg@w3.org; Wed, 29 Jan 2020 22:22:46 +0000
Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id B65BD218C1; Wed, 29 Jan 2020 17:22:41 -0500 (EST)
Received: from mailfrontend2 ([10.202.2.163]) by compute3.internal (MEProxy); Wed, 29 Jan 2020 17:22:41 -0500
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mnot.net; h= content-type:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; s=fm1; bh=2 8LpzxauiaXwqOe5V7nRwXTd9weRFPhpI0iTmCoRi9w=; b=YXBXU4i/5Z1iqtr83 NKhYNNKPLomOz3+XBb752+rL+PiQIe3YBPbS3IlEwhWxlGkRYJKYpEROpzAhS6Vl 5bbum3ImhYWVWSAP0+sIK0O6eO/EkjFRDoLxiWCLAzEVhLwAKVC+8KPvENLCJlwK n5t5Wy1brC3NABBfMr9z00nIRibBZ0vkSK8LkZwRk2hQVLV8sfE94cajNXeyQbGs 9QtfObm70f6N0rbiooLoLXX4ewA4h/IGd9zqT8eQQs0BbgE5tSW+rTakVrSCgaJv Kdu8Jqdj/XgwE4cPT3f/EJqoUpnLifv4eo3K0rhF4e0N3CQFOHOfn0gGwoCHGIPb +MOsQ==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=28LpzxauiaXwqOe5V7nRwXTd9weRFPhpI0iTmCoRi 9w=; b=n8iSNGsP7LquwKTvm+KHPIRndyH8+KJU2QfkSzsMXrFiAbk67+zO4f09+ QZaqpOsAqzgU3ds5vncgHoweqKPjx2KIvFzHX7Kz2EbL0K1duE3FPGyZOy9EeIL5 1HnRYj31Hi3VJfPXRj6ZsP9OdhQUSGbsKN6N2/LfSJwj5xPA01oaS4DQYBw3NjlC yiG7/HqxO1VSmAMqSCzvUNOtatzqqQEqhalOHdLTPpDJ6O4UsSLGNbk9+s+Y/18c ItXSWLvB2NWtrxPOEEBgRn8Uz/ZbhDfYlTYRwzMFbPOcwG3837QONkIygCD9noP0 OmhkRSRAMPy0Vvvn/+x8xGS0jWVXg==
X-ME-Sender: <xms:sQUyXrfs8nntc7fkFXe4a_oiMFN5oqpUJ3fGwiNZhTsjXito05E_nA>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedrfeeigdduheekucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurheptggguffhjgffgffkfhfvofesthhqmhdthhdtvdenucfhrhhomhepofgrrhhk ucfpohhtthhinhhghhgrmhcuoehmnhhothesmhhnohhtrdhnvghtqeenucffohhmrghinh epihgvthhfrdhorhhgpdhmnhhothdrnhgvthenucfkphepudduledrudejrdduheekrddv hedunecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepmh hnohhtsehmnhhothdrnhgvth
X-ME-Proxy: <xmx:sQUyXhxawGdMkIF18ob-88kfgsS0_xk81UK-lktxoolvykrBdT52DQ> <xmx:sQUyXta0TbCfBTf45q_R3UJTffKN-1oXKbRF29IPdN0fcSNJ8b4Fbg> <xmx:sQUyXnKPIFOnwgjECuno3wzzV5CzM4fELPaWyKfXzMmEwhU4KV54bA> <xmx:sQUyXrqFk_UCBYm0zor5u0XCeF3JH1Qh4fmZmAeYB-9BnlAU3EK6UQ>
Received: from macbook-pro.mnot.net (unknown [119.17.158.251]) by mail.messagingengine.com (Postfix) with ESMTPA id 0546F3060BE4; Wed, 29 Jan 2020 17:22:39 -0500 (EST)
Content-Type: text/plain; charset="us-ascii"
Mime-Version: 1.0 (Mac OS X Mail 13.0 \(3608.40.2.2.4\))
From: Mark Nottingham <mnot@mnot.net>
In-Reply-To: <c57f5766-08ee-79a2-8149-c273eabd6a26@gmx.de>
Date: Thu, 30 Jan 2020 09:22:39 +1100
Cc: Kari Hurtta <hurtta-ietf@elmme-mailer.org>, HTTP Working Group <ietf-http-wg@w3.org>, Poul-Henning Kamp <phk@varnish-cache.org>
Content-Transfer-Encoding: quoted-printable
Message-Id: <E21838F2-98E1-4FB6-92FB-4B79B05E80ED@mnot.net>
References: <158028031175.4610.9085377324549619919@ietfa.amsl.com> <20200129181750.78AF7350F@welho-filter3.welho.com> <c57f5766-08ee-79a2-8149-c273eabd6a26@gmx.de>
To: "Julian F. Reschke" <julian.reschke@gmx.de>
X-Mailer: Apple Mail (2.3608.40.2.2.4)
Received-SPF: pass client-ip=66.111.4.26; envelope-from=mnot@mnot.net; helo=out2-smtp.messagingengine.com
X-W3C-Hub-Spam-Status: No, score=-9.8
X-W3C-Hub-Spam-Report: BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, W3C_AA=-1, W3C_DB=-1, W3C_IRA=-1, W3C_IRR=-3, W3C_WL=-1
X-W3C-Scan-Sig: mimas.w3.org 1iwvjP-0002n5-QF 8ad76942548d0cce2a09382609900c7b
X-Original-To: ietf-http-wg@w3.org
Subject: Re: draft-ietf-httpbis-header-structure-15, Serializing a Decimal
Archived-At: <https://www.w3.org/mid/E21838F2-98E1-4FB6-92FB-4B79B05E80ED@mnot.net>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/37323
X-Loop: ietf-http-wg@w3.org
Resent-Sender: ietf-http-wg-request@w3.org
Precedence: list
List-Id: <ietf-http-wg.w3.org>
List-Help: <https://www.w3.org/Mail/>
List-Post: <mailto:ietf-http-wg@w3.org>
List-Unsubscribe: <mailto:ietf-http-wg-request@w3.org?subject=unsubscribe>


> On 30 Jan 2020, at 5:41 am, Julian Reschke <julian.reschke@gmx.de> wrote:
> 
> On 29.01.2020 19:17, Kari Hurtta wrote:
>> 4.1.5.  Serializing a Decimal
>> https://tools.ietf.org/html/draft-ietf-httpbis-header-structure-15#section-4.1.5
>> 
>> 
>> |   Given a decimal_number as input_decimal, return an ASCII string
>> |   suitable for use in a HTTP header value.
>> |
>> |   1.  Let output be an empty string.
>> |
>> |   2.  If input_decimal is less than (but not equal to) 0, append "-" to
>> |       output.
>> |
>> |   3.  Append input_decimal's integer component represented in base 10
>> |       (using only decimal digits) to output; if it is zero, append "0".
>> ...
> 
> That seems to assume that the integer component always is positive...?

How so? Is "using only decimal digits" unclear?


--
Mark Nottingham   https://www.mnot.net/