From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([69.77.167.62] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1KuxTV-0004iV-Ul for garchives@archives.gentoo.org; Tue, 28 Oct 2008 22:55:46 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id E4E3DE04F5; Tue, 28 Oct 2008 22:55:43 +0000 (UTC) Received: from rn-out-0910.google.com (rn-out-0910.google.com [64.233.170.185]) by pigeon.gentoo.org (Postfix) with ESMTP id B9139E04F5 for ; Tue, 28 Oct 2008 22:55:43 +0000 (UTC) Received: by rn-out-0910.google.com with SMTP id m36so1770941rnd.14 for ; Tue, 28 Oct 2008 15:55:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:sender :to:subject:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references :x-google-sender-auth; bh=gg1JsJovcHjpf0G42TxWNJNMLz44qwsGLibdY0hqF+Q=; b=Ne1C6ExvFNFIO9cJvlaTiwzS1GuamYctCleEjgNIniURXbfvRTsUcH9nMfzn9cHmUL 3ztaxP02DYvjXQCfBZ88BVQs/+o8nrQq0y5nvIw3QHUqbCQKx08b2lKRyak94frksE3O Of/VlugUPwtFXKh9nD7TqZFfGLWJY2rG9w/xU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:sender:to:subject:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references:x-google-sender-auth; b=PkSSXKuFqPgsK814y1YMK3oQSrUqeJkdaP7eti8c2TQST/kNQ/+9p4Wdd3JQ391ann X5EGY4kDIdzySoVY0graLd6o+thc48yUIRkjVZoXU6NI5+7KlyqgQcYbV7Zmy3krXXi9 WkOrNXb7K/aUCouIAAbGDr1ugbGdkUGwa31VI= Received: by 10.90.68.12 with SMTP id q12mr6619111aga.100.1225234542084; Tue, 28 Oct 2008 15:55:42 -0700 (PDT) Received: by 10.90.81.1 with HTTP; Tue, 28 Oct 2008 15:55:42 -0700 (PDT) Message-ID: <38af3d670810281555j43a2c0dfl990860eb9b85921b@mail.gmail.com> Date: Tue, 28 Oct 2008 20:55:42 -0200 From: "Jorge Peixoto de Morais Neto" Sender: jorgepeixotomorais@gmail.com To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] package.keywords syntax? In-Reply-To: <200810290041.39256.alan.mckinnon@gmail.com> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <200810282356.25430.alan.mckinnon@gmail.com> <38af3d670810281517k186dfeacg80d7288c34d52043@mail.gmail.com> <200810290041.39256.alan.mckinnon@gmail.com> X-Google-Sender-Auth: 5d8f0467de1b6e51 X-Archives-Salt: 7ada550a-3628-48b5-93f6-afdbe166c4ba X-Archives-Hash: cab476b04e0da3c9e8f39e47559cd236 >> I mean to really know C, >> that is, read a rigorous book such as "C: A Reference Manual" and be >> able to write portable programs with well-defined behavior. Speaking >> of well-defined behavior, do you know what happens when you cast a >> float to an int, and the float is too big to fit into the int? > > Did oyu try it yourself and see? The point is that the behavior in this situation is "undefined". It might do anything. Programming in C is different than programming in Python. In Python, you must know the basic behavior of a statement/functions. If an error occurs, it raises an exception. If you do not catch the exception, the program exits (and you can arrange for cleanup actions to be performed before the program exits). In C, you must know exactly what the statement/function does, and you *must* handle the possibility of errors. If an error occurs and you do not handle it, the program may crash, or it may go on and behave erratically (such as deleting user files, or giving results subtly wrong, or leaking memory, or...) -- Software is like sex: it is better when it is free - Linus Torvalds