Date: Thu, 19 Jul 2018 20:19:42 +0000 From: Alexey Dokuchaev <danfe@FreeBSD.org> To: Devin Teske <dteske@FreeBSD.org> Cc: Ian Lepore <ian@freebsd.org>, Michael Tuexen <tuexen@FreeBSD.org>, src-committers <src-committers@freebsd.org>, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r336503 - in head/sys: netinet netinet6 Message-ID: <20180719201942.GA61225@FreeBSD.org> In-Reply-To: <06745A7A-2E1C-4E48-ADCE-F42447B28A2C@FreeBSD.org> References: <201807191933.w6JJXhof018383@repo.freebsd.org> <20180719195302.GA26853@FreeBSD.org> <1532030389.1344.9.camel@freebsd.org> <06745A7A-2E1C-4E48-ADCE-F42447B28A2C@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Jul 19, 2018 at 01:12:19PM -0700, Devin Teske wrote: > > On Jul 19, 2018, at 12:59 PM, Ian Lepore <ian@freebsd.org> wrote: > > ... > > "usually" may be true of freebsd, but most places I've worked consider > > the * (and & in c++) to be more associated with the type being declared > > than with the variable name This is often true for C++ (partially because it has both * and &), but... > > info, not the var name. Putting the * or & with the var name leads to > > particularly bad constructs such as > > > > int a, *b; > > > > which, for maximal clarity, should be: > > > > int a; > > int* b; > > Are we free to prefer the former in C if that's how we've been coding in > C for 20+ years? I agree with Devin here: we, in FreeBSD, which is mostly coded in C, place the star by the variable rather than its type. ./danfe
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20180719201942.GA61225>