[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v4 05/11] CODING-STYLE(tools/ocaml): add .editorconfig to clarify indentation uses spaces


  • To: Edwin Torok <edvin.torok@xxxxxxxxxx>
  • From: Christian Lindig <christian.lindig@xxxxxxxxxx>
  • Date: Mon, 19 Dec 2022 09:59:55 +0000
  • Accept-language: en-GB, en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=r23GlqhrFuYg0IYsnwfVRZNHFCcgbCjXHLf6Y0ptvdQ=; b=i6By8w15TmBRTvRkmJ4+WL/p2HHdfJmILQIM+UiZGhriyXU8Z1YaY5yRZTCu3PgaUS9HErs2tViVJLmYC3fBEAnMHesGyRr2vvvl1FPzN9Ide5Rvr9NoKpy5mvzMJ6Q6Yz5XMgxx7+LlN82p80dlni+hLOEJGT8BoWqAO+/KRrHsQXROT2yMISueVPdRNJ1k9paYc3eIL/Ro0utR1sd0+i9t9KatUPa6w51icq7lspgqmQ6OZVXxCwpBdVAB7VLai+FkH0nXE+v9oR3s0yo6qwnMWSuZ4mj61gbXa7ao3yM80Xuq6n7IfKOj27kJh9yg+1go4Q67OXUUEc4dE+XP+Q==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Tryl3G9plt+LVPqWaI0aAQP2638ptyOrQsxtXkgFPGmvOuNNogwJsDidxhP7bdqUl6/t+SpFPdvoPaRVW4ZjChGzSorjhBuGrDqdvlBeZ2P05udflvKdnurqIee1oIm+8njuH74FVqYRPTVe30sgJJwmjds0gIquQ3lEjNVVrXe7467XFuIzf4n504iaqHqgkswOZ/jyUhBMZMiT+4hVPYzXU6femeCpRdO29aLjfLSockoY7JDHGVBKFpprHn83GFAfJnugwZB14os16p+C6k4/hypuFCHLQ99947yZrxKHz+kfHa2HquBg8QzBNG9Fsplagf0fw9n1fAJwaYbX8A==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
  • Cc: Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Andrew Cooper <Andrew.Cooper3@xxxxxxxxxx>, George Dunlap <George.Dunlap@xxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
  • Delivery-date: Mon, 19 Dec 2022 10:00:19 +0000
  • Ironport-data: A9a23:qvNoUKOIRgaFjmbvrR1xlsFynXyQoLVcMsEvi/4bfWQNrUomhGcEn TEXDW+HM/yCMWTyf9EiOoS+p09S7JSAndBgTQto+SlhQUwRpJueD7x1DKtS0wC6dZSfER09v 63yTvGacajYm1eF/k/F3oDJ9CU6jufQA+KmU4YoAwgpLSd8UiAtlBl/rOAwh49skLCRDhiE/ Nj/uKUzAnf8s9JPGj9SuvzrRC9H5qyo4mpC5w1mPJingXeF/5UrJMNHTU2OByOQrrl8RoaSW +vFxbelyWLVlz9F5gSNy+uTnuUiG9Y+DCDW4pZkc/HKbitq/0Te5p0TJvsEAXq7vh3S9zxHJ HehgrTrIeshFvWkdO3wyHC0GQkmVUFN0OevzXRSLaV/ZqAJGpfh66wGMa04AWEX0rlGBlpQ3 uVIEzJOSzmThuPp75SiGuY506zPLOGzVG8ekldJ6GiASNoDH9XESaiM4sJE1jAtgMwIBezZe 8cSdTtoalLHfgFLPVAUTpk5mY9EhFGmK2Ee9A3T+PVxujeNpOBy+OGF3N79cdyQRN5Jn0+e4 GbH+Wj4DTkRNcCFyCrD+XWp7gPKtXKiBd5KSuDonhJsqHeq3lwfEQY7aV7l+KGejU+kY8J5I ENBr0LCqoB3riRHVOLVTxC+5XKJoBMYc95RCPEhrhGAzLLO5ASUDXRCSSROAPQkvsIrQT0h1 neSgsjkQzdotdW9S2+Z97qShSO/P24SN2BqTTQfUQIP7t3noYcyphHCVNBuFOiylNKdMS706 yCHqm45nbp7sCIQ/6Cy/FSCjzfyoJHMF1cx/l+OATzj6R5lbom4YYDu8ULc8ftLMIeeSB+Go WQAnM+dqusJCPlhiRCwfQnEJ5nxj97tDdEWqQcH80UJn9h1x0OeQA==
  • Ironport-hdrordr: A9a23:Zj5iSa7+gGzmZBY1VQPXwUKBI+orL9Y04lQ7vn2ZFiY5TiXIra qTdaogviMc0AxhI03Jmbi7Scq9qADnhORICOgqTP+ftWzd1FdAQ7sSircKrweAJ8S6zJ8k6U 4CSdk0NDSTNykdsS+S2mDRfLgdKZu8gdmVbIzlvhVQpHRRGsVdBnBCe2Om+yNNJDVuNN4cLt 6x98BHrz2vdTA8dcKgHEQIWODFupniiI/mSQRuPW9r1CC+yReTrJLqGRmR2RkTFxlVx605zG TDmwvloo2+rvCAzAPG3WO71eUbpDKh8KoNOCW/sLlVFtzesHfpWG2nYczAgNkBmpDg1L/tqq iPn/5vBbU315qbRBDJnfKk4Xid7N9p0Q6p9bbQuwqdneXpAD09EMZPnoRfb1/Q7Fchpsh11O ZR03uerIc/N2K2oM3R3am8a/hRrDvBnVMy1eoIy3BPW4oXb7Fc6YQZ4UNOCZ8FWCb38pouHu ViBNzVoK8+SyLSU1nJ+m10hNC8VHU6GRmLBkAEp8yOyjBT2HR01VERysATlmoJsJg9V55H7e LZNbkArsA5cuYGKaZmQOsRS8q+DWLABRrKLWKJOFziULoKPnrcwqSHkondJNvaC6Dg4KFC6K gpCmkoy1LaU3ieePGz4A==
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Thread-index: AQHZEXvS6RVw/jj4C0W0HfdHSBPV8K50/lEA
  • Thread-topic: [PATCH v4 05/11] CODING-STYLE(tools/ocaml): add .editorconfig to clarify indentation uses spaces


> On 16 Dec 2022, at 18:25, Edwin Török <edvin.torok@xxxxxxxxxx> wrote:
> 
> Add an .editorconfig to make it easier to keep patches compatible with
> Xen's coding style, and to reemphasize what Xen's coding style is.
> 
> I thought that Xen demands tabs rather than spaces (which is more
> difficult with OCaml because indentation tools use spaces,
> and the use of tabs requires changing editor settings),
> however CODING-STYLE says it is spaces.
> 
> Document this explicitly by adding a .editorconfig file (see 
> editorconfig.org),
> which is an editor agnostic format for specifying basic style properties like
> indentation, either with native support in editors or via plugins.
> 
> It is safer than modelines because it only supports controlling a
> restricted set of editor properties and not arbitrary commands as Vim
> modelines would have, and works with editors other than Vim too.
> (Vim has a deny list for modeline sandboxing, which is error-prone
> because every time a new command gets added it needs to be added to the
> deny list, which has been the source of a few CVEs in the past
> and I disable Vim modelines everywhere as a precaution).
> 
> This file is added as a convenience for those who might have an editor
> that supports it, and its presence should have no impact on those that
> do not (want to) use it.
> It also won't cause re-indentation of existing files when edited, only
> newly added lines would follow the convention.
> 
> No functional change.
> 
> Signed-off-by: Edwin Török <edvin.torok@xxxxxxxxxx>
> Cc: Christian Lindig <christian.lindig@xxxxxxxxxx>

Acked-by: Christian Lindig <christian.lindig@xxxxxxxxxx>

I am agnostic about this change. Automatic code formatting should take care of 
this but I see no harm including this file. The number of developers 
contributing to the OCaml code base is minuscule and we should try to keep 
barriers as low as possible. The wrangling about all these minutiae is already 
too much.

- C

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.