From owner-freebsd-chat@FreeBSD.ORG Sat Apr 15 16:04:09 2006 Return-Path: X-Original-To: freebsd-chat@freebsd.org Delivered-To: freebsd-chat@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 052F416A404 for ; Sat, 15 Apr 2006 16:04:09 +0000 (UTC) (envelope-from solskogen@carebears.mine.nu) Received: from mail.hjemme.no (mail.hjemme.no [62.97.193.11]) by mx1.FreeBSD.org (Postfix) with ESMTP id BFC2443D46 for ; Sat, 15 Apr 2006 16:04:07 +0000 (GMT) (envelope-from solskogen@carebears.mine.nu) Received: from carebears.mine.nu (151.85-200-10.bkkb.no [85.200.10.151]) by mail.hjemme.no (8.13.4/8.13.4) with ESMTP id k3FG42fC020683; Sat, 15 Apr 2006 18:04:04 +0200 Received: from localhost (localhost [127.0.0.1]) by carebears.mine.nu (Postfix) with ESMTP id ABEB7CD6E4; Sat, 15 Apr 2006 18:04:09 +0200 (CEST) X-Virus-Scanned: amavisd-new at carebears.mine.nu Received: from carebears.mine.nu ([127.0.0.1]) by localhost (shine.carebears.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id WcnRn1Lt6Gc9; Sat, 15 Apr 2006 18:04:00 +0200 (CEST) Received: from [127.0.0.1] (unknown [192.168.0.27]) by carebears.mine.nu (Postfix) with ESMTP id 97C93CD69F; Sat, 15 Apr 2006 18:04:00 +0200 (CEST) Message-ID: <4441199C.4090802@carebears.mine.nu> Date: Sat, 15 Apr 2006 18:04:44 +0200 From: Christer Solskogen User-Agent: Thunderbird 1.5 (Windows/20051201) MIME-Version: 1.0 To: Benjamin Lutz References: <200604151313.32519.benlutz@datacomm.ch> In-Reply-To: <200604151313.32519.benlutz@datacomm.ch> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Antivirus: avast! (VPS 0615-3, 14.04.2006), Outbound message X-Antivirus-Status: Clean Cc: freebsd-chat@freebsd.org Subject: Re: Why is not more FreeBSD software written in C++? X-BeenThere: freebsd-chat@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Non technical items related to the community List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Apr 2006 16:04:09 -0000 Benjamin Lutz wrote: > Something occurred to me just now. I've been looking at the summer of code > page, where I noticed the "Rewrite cvsup in C" entry. When Perl was removed > from the FreeBSD base, the general notion was to rewrite any Perl scripts in > sh or C. > > Why is it that C++ is not used for our programs? The C++ compiler is in the > base and built by default, and the OOP paradigm is a nice one, that many > programmers, especially the younger ones (like me :) ) are probably more > familiar with than the tricks and techniques used in C to achieve good > efficiency. > > My first guess is that it's a habit. People dealing with the FreeBSD source > code are used to C, and therefore use that for their apps. If it's only that, > there'd be no good reason for not writing a tool like cvsup in C++, right? Or > is there a more technical reason? If you really want you can code whatever tool you need in c++. I guess cvsup was rewritten in C because the developer understands C, and not C++ (or the task of rewrite cvsup in C++ would be harder) -- chs