From owner-svn-src-head@FreeBSD.ORG Sun Sep 1 22:38:52 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 01D657E8; Sun, 1 Sep 2013 22:38:52 +0000 (UTC) (envelope-from davide.italiano@gmail.com) Received: from mail-ve0-x22e.google.com (mail-ve0-x22e.google.com [IPv6:2607:f8b0:400c:c01::22e]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 920A52993; Sun, 1 Sep 2013 22:38:51 +0000 (UTC) Received: by mail-ve0-f174.google.com with SMTP id d10so2655247vea.33 for ; Sun, 01 Sep 2013 15:38:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:content-type; bh=eC8/GVqQaRmw2g3I2bXOHTCIZxQVY1J59bWaTc3sRn8=; b=b+NplyQbHNcbjdxeEG/s603sNNh8BT9j/QCA4CYXyzWLvVnhPBhd6Vq18vRmmtFdsQ mvULvnjeOG7cb+SbjKKh9I/P4kjtyo929MhkxCzEtdbAy4q8PvJji+vPLXfcPJX5+Hmb uwjB18CxHyfQ7U4S6Xs6fZWWQ46UZdSt4b8WrWVfkRT9ulul2hBi35hmWImGbiUVMA86 PGHUBRPrv0GjYDwwJ5WNiluweaNYYdH6tiatnTVkD9aVoOLe22onwARwwqSHgLw3XD5z 5hyLFxxNnKm6vQKQuWvS8rkWEdiFWVI19HvxblooT6uNmEOWbMpAnWx5fH37JRmH7zJ/ W6Vw== MIME-Version: 1.0 X-Received: by 10.52.52.231 with SMTP id w7mr7546267vdo.12.1378075130663; Sun, 01 Sep 2013 15:38:50 -0700 (PDT) Sender: davide.italiano@gmail.com Received: by 10.220.65.132 with HTTP; Sun, 1 Sep 2013 15:38:50 -0700 (PDT) In-Reply-To: <201309012230.r81MUP6w036044@svn.freebsd.org> References: <201309012230.r81MUP6w036044@svn.freebsd.org> Date: Mon, 2 Sep 2013 00:38:50 +0200 X-Google-Sender-Auth: KZtAA0Q0O92tclh8r6yRKZkj37w Message-ID: Subject: Re: svn commit: r255135 - head/sys/sys From: Davide Italiano To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Sep 2013 22:38:52 -0000 On Mon, Sep 2, 2013 at 12:30 AM, Davide Italiano wrote: > Author: davide > Date: Sun Sep 1 22:30:24 2013 > New Revision: 255135 > URL: http://svnweb.freebsd.org/changeset/base/255135 > > Log: > Use single underscore for all parameters name and local variables in > bintime_* related functions. This commit completes what was already done > by theraven@ for bintime_shift, and just uses a single underscore instead > of two (which is a style bug according to Bruce). See r251855 for reference. > > Reported by: theraven > Discussed with: bde > Reviewed by: bde > This commit should fix the namespace problem(s) but still there are quite a few issues in time.h, as I previously privately discussed with Bruce. Other than stylistic issues, e.g. the usage of something more appropriate like _btp for pointers or something more explicative for second argument in bintime_add than _bt2, the main design error is that bintimes are pointers. This was good historically because it avoided passing large structs in 1978, but right now (with inline) there is little difference between using pointers and using structs, except the latter code is easier to write and optimize. JFYI, sbintime_t functions considers this previous "mistake" and do not rely on pointers. At some point probably bintime might be changed to be more similar to sbintime_t, even though this looks like a huge change for me now. Thanks, -- Davide "There are no solved problems; there are only problems that are more or less solved" -- Henri Poincare