Received: by 2002:a05:7412:cfc7:b0:fc:a2b0:25d7 with SMTP id by7csp1814936rdb; Tue, 20 Feb 2024 07:49:02 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWZI/1vo+wZnw7h8HdAV4eDWKKL3Rzee+HVbNZo/wwxWrUKvolMd+SihXRTVu4I2L7RlbUmni0TrzOtOsWup5QUtPFZZOdgjMnZgJycGQ== X-Google-Smtp-Source: AGHT+IGvitDAT5pTsa/tk01XhYxkwzqbwxbcRSSaqHzHqKtBKfQ5400DZBuGFxZh97jyjnOKZh1X X-Received: by 2002:a17:902:7888:b0:1d9:5cfc:ac6a with SMTP id q8-20020a170902788800b001d95cfcac6amr13890538pll.69.1708444142662; Tue, 20 Feb 2024 07:49:02 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708444142; cv=pass; d=google.com; s=arc-20160816; b=fTUXFVTMLETOX+Kmg2U1B60PKYLADJ285StfeK30/TXa3VTQYqxDISmE7asJ5ukon9 7A27UGXXVDq9b0/zuvZPv8mBxgMoZK+i+aDAncqkR2C6UjP/cxpicTv8/8UxhyerfhEq 1GfyjVOZ4H8Xb6ZesbZzYW+Q4j4NSpPl0luWIVUeHpJgInY7mZR0IA8zTG8pMTvpjNBl WShyZ8oCk30Zkoj0iFyK7DpqK9Ujob+W23upk8pMjH60A4QiqmW/75rTI2tL0sKizN+h fPgzmHAmRSgZe/dePRC1z5kdi4AYY5avZDGZM7tVyuGf804xuFFdyleRH1YHShpG1/23 5mHg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=T9V5XtIpSuhz+qbEYmW8Gv+3u3YMnmX//PpS72rrwGM=; fh=66A5CHQJAeeDukl66rdWa8b2N0eimCYMJw/WkGoQ2yg=; b=GsZoVzlC81P/JFeFyKEAjg4QMyN9iG7U4KkIIgD7lWwkm/Uu1S0hGkfYu5xgJVJJ1I /79agCqLRB39QX1cYXRIGsaag4sQUNzgL5omdsVmahP9jg7g6z8EfPOnE56TjI7ZWMsw 1nL6gCezEz4n6larQ8pin33VkirD+p1gXOgRZ+YM9PXleiLBzInourKhOarWuMXrY8Ho EybuNlp8jXaMzcehE3xu7aJ2UvB331ou+nOpazAvBMiffrtl7oGLrfVT1SnBpikj5nk6 5uHgN16qSqkLAZiOkGR0/9KXKBe2N12d/8d7GeU9BhBXB3ppZqJ/+kBkcvVd+YrO4gRM V/aQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=GpQKpKNg; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-73270-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-73270-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id ll13-20020a170903090d00b001dbedc935f9si3912239plb.9.2024.02.20.07.49.02 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Feb 2024 07:49:02 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-73270-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=GpQKpKNg; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-73270-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-73270-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 66A26B212FA for ; Tue, 20 Feb 2024 15:46:12 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id CE7A3762E8; Tue, 20 Feb 2024 15:45:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="GpQKpKNg" Received: from mail-pj1-f53.google.com (mail-pj1-f53.google.com [209.85.216.53]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B49F36A8AB; Tue, 20 Feb 2024 15:45:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.53 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708443959; cv=none; b=uMQNpQfyvKQrmhsCMlBbSuC93jnTru00o+/yDSqlYhiFScrws3NbGc3UbUX6lN1ubwxZmEf3PmrXjUu6klaLgCrgpxUxGqjKwlJLk0PXsqcq5fVkzp9soyYp/5/2XtLSk4U0HR+WpXAWdE3fwaYrT8p/seXiCYwp+cvdRk+cwrg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708443959; c=relaxed/simple; bh=T9V5XtIpSuhz+qbEYmW8Gv+3u3YMnmX//PpS72rrwGM=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=lksoEEotD+vMzjjD4tqaKsibzwb3P/cKbdJv3nBZT5Eayk/PTncA3F3n88yYmO1uM3e7JsejvR/xDnfKRrRPy09+claj7ZmhA/ACu8xJU51yHhTG56EWB8xpuRu8RzD/abexb6F09179SNuUnr6LWxD8/HFGEWeFDxvCjXCpZY0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=GpQKpKNg; arc=none smtp.client-ip=209.85.216.53 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pj1-f53.google.com with SMTP id 98e67ed59e1d1-299e0271294so527747a91.3; Tue, 20 Feb 2024 07:45:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1708443957; x=1709048757; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=T9V5XtIpSuhz+qbEYmW8Gv+3u3YMnmX//PpS72rrwGM=; b=GpQKpKNg0GcULlY/QxM3dAho2Os0HlD4GVx9X2+Yv86hL/ztdPR/pcMaRKyKMOL/5H GSn+hI6JQaj80uIv6LYch3f+uw59DeYOrc8O1qD04MQHAk3G0OkQl2VJ1o8JbKg5gIaS prBBRJ1tJk3Dh8Rbuxz+rBA0qpOJmnX4D1pkbA2rPLr1X4d7lDjquMArXiQnWNPFfqB5 QPEhG8k8YEkgPumfNvj0uHxD2NdVF0RcjOmhmWUs2K4q3oZKaEQctDiXXqi/s8offVpF 9J+dlJclav2OKXfzgEEWyUTWJiRv5BwaCQj2IIyMb+0nF1CAb27a2PiidnZyKYt3Tc/w EGIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708443957; x=1709048757; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=T9V5XtIpSuhz+qbEYmW8Gv+3u3YMnmX//PpS72rrwGM=; b=B2BnwNKxNtkLL1ykiz+8rzcj2SWKB+VFuNEvGhKra7bjuLGYlEBdYsPn22nFK/JY75 hxj5AzYpyjZ1BBhQIaVzGlXSOw1Ym6irnF9h9l6MIGKa6KWzhlIrTqNqJEOwGPz+rdTH i13g99G5+nhRSI0mztRqCTqBwcqpM7NGIe8nTcjV0/NawR9g56Txqp+Xsb0xatLii/PK zvJkMAj7S6vdN9PkkPVFlSbSdQ/fuTQmmA7IaWfhwm2KHixHLGQr9ynObMVmPs69oBVi 1D9o0KhqOxq/IBnALx6HZmms4W2D9MbEOmkzO2GvrOWxXMM54mYcEzh8ub3+3y1vTUxK Crew== X-Forwarded-Encrypted: i=1; AJvYcCXEk4i/Y9AJWfwb9B4jm+vP/ol3g1EzTrejr0Sj2ybgq4PmzgXddB+LqthhYEcoxFvUeqU/wq3dQ+pLcuvDjZW8/he/p5wK5LOQVPbZGyhTyk7z0xixlYIQisCEq/cv27/iJYyilppcO6IERwU= X-Gm-Message-State: AOJu0Yz1krqS7MmDevwqpfvy4ImdmrKVDxH6cAe1M/A/qffzkSlw/sXY L8qZcinVCXYx4zRQIBrmJm2PzUHyL0/f23tatp3l7ZnmDqAp8VINknihilEdHCceeVS+mykQZtH jFC//lSlP9DoFg2sf3ectgSXJCIE= X-Received: by 2002:a17:90a:3486:b0:299:398e:5cee with SMTP id p6-20020a17090a348600b00299398e5ceemr8445413pjb.13.1708443957074; Tue, 20 Feb 2024 07:45:57 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240219163915.2705-1-dakr@redhat.com> <20240220093541.280140-1-aliceryhl@google.com> <19d0a4a9-85bb-4b9e-96b0-338adebc90e5@redhat.com> In-Reply-To: <19d0a4a9-85bb-4b9e-96b0-338adebc90e5@redhat.com> From: Miguel Ojeda Date: Tue, 20 Feb 2024 16:45:44 +0100 Message-ID: Subject: Re: [PATCH v4] rust: str: add {make,to}_{upper,lower}case() to CString To: Danilo Krummrich Cc: Alice Ryhl , a.hindborg@samsung.com, alex.gaynor@gmail.com, benno.lossin@proton.me, bjorn3_gh@protonmail.com, boqun.feng@gmail.com, gary@garyguo.net, linux-kernel@vger.kernel.org, ojeda@kernel.org, rust-for-linux@vger.kernel.org, wedsonaf@gmail.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, Feb 20, 2024 at 3:53=E2=80=AFPM Danilo Krummrich = wrote: > > Just to clarify, I did not say anything else. As mentioned, I think those > should not even be warnings. Well, for things like the `return` one, I find it unlikely it will change. And for other things that there are 2 ways of doing it, what we typically want is to have one way of doing it, rather than allowing both ways. > I'm happy to do that. We should define the scope for that though. I think= this > should be set globally, or at least not per crate. However, I don't reall= y know > what's the best way to do that. We could pass '-Aclippy::' to the compile= r... The scope is already defined -- it is global, precisely because we want to keep all kernel code as consistent as possible. > Is there any objective reason not to be allowed to be explicit here? What is not objective about wanting to be consistent? How is your argument objective if ours isn't? > Well, I generally agree. However, I'm clearly against *blindly* following > formatters and linters. > > Forcing guidelines we don't have objective reasons for will otherwise jus= t annoy > people and lead to less ideal code for the project. And I intentionally s= ay "for > the project", since this context is important. Who is *blindly* following formatters and linters? We don't have objective reasons? I don't appreciate the way you are wording things here. Does it actually lead to "less ideal code", or the opposite? Cheers, Miguel