From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Paul Pogonyshev Newsgroups: gmane.emacs.devel Subject: Re: suppressable byte compilation warnings and cconv.el Date: Thu, 14 Apr 2016 10:44:52 +0200 Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1460623503 24969 80.91.229.3 (14 Apr 2016 08:45:03 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 14 Apr 2016 08:45:03 +0000 (UTC) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Apr 14 10:45:02 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1aqcta-00022I-1l for ged-emacs-devel@m.gmane.org; Thu, 14 Apr 2016 10:45:02 +0200 Original-Received: from localhost ([::1]:35109 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aqctY-0004r2-TD for ged-emacs-devel@m.gmane.org; Thu, 14 Apr 2016 04:45:00 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35845) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aqctU-0004nu-H8 for emacs-devel@gnu.org; Thu, 14 Apr 2016 04:44:57 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aqctT-0000CL-Ip for emacs-devel@gnu.org; Thu, 14 Apr 2016 04:44:56 -0400 Original-Received: from mail-oi0-x235.google.com ([2607:f8b0:4003:c06::235]:33930) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aqctT-0000Br-Dl for emacs-devel@gnu.org; Thu, 14 Apr 2016 04:44:55 -0400 Original-Received: by mail-oi0-x235.google.com with SMTP id s79so87246430oie.1 for ; Thu, 14 Apr 2016 01:44:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-transfer-encoding; bh=cqdQeP6+wnPYwdd5GOO+UQfevE1p/Pf9yX4h7V8bdQM=; b=Ne4rmqek7MvjjgBub+P0Zjf5UVfKuIAMWqilv90stWptJJRsdBr2WaxzjF0BWnnxXJ Z56pcMR6PS68lvUDbwbGipwMTNUAxGgkg9qMLgxONObPzOv36MKfJBeBCa2gsr1oP0qa qaUnfW0tWT7ciI8KaurwT/LkdF30HRB1XpQShGb72FERkYLtf4VoIByE2NzkI3Gl6SSp omCqd/LDlmja1/G+JxUnxMfWilpGSILIhJSvgw0SYFzZi9G7ScYLnZ16VVcvoa+5CT7n 70GgfEVzQ6REl1LT3iuDbCsSj0jatmdDWDMYP/hmJl/LPN+228YxdwKRd4CJUtuU2gVP Fufw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-transfer-encoding; bh=cqdQeP6+wnPYwdd5GOO+UQfevE1p/Pf9yX4h7V8bdQM=; b=Fd3aEy8vwqVAENpL6P5EpEjPIASDQkIEs5OnsVVq83SRCvbyvsGmNMOM5qfVBA8I+6 MIInM4S7Cbywf/Z2Og0a1vsymPDfdMjziKldfp2NGLzC3QfWnFnXik4BqU6ZBOYcJdN7 PQ8CwQCkHqv6rkhKlMlYLwMI2gHJ96M9zii7I2v0b8ogXR7R0fV7PGFgOuOVY8Y0I5rQ wNkmXqcHdT+IWQOG6RceKtXi5EorACDx26eC7mNbMrGHyzMahmCtMGdfQC8HMN6/JQ4n pX+sslTkqVpLjXk0BSnLbn8omTNz2eAyh6nPPkBWjg2+pSXmN0i2gvAFHUwBVzhniaHe BqZw== X-Gm-Message-State: AOPr4FX3C2lo0z+ejID+r3/ZBKtZkdJNubq1/w54nKUFpCU8bJf0avTd1J1VKUADcq68N+OV9GvDda7NwgnHOw== X-Received: by 10.202.69.134 with SMTP id s128mr6690812oia.97.1460623492764; Thu, 14 Apr 2016 01:44:52 -0700 (PDT) Original-Received: by 10.202.197.148 with HTTP; Thu, 14 Apr 2016 01:44:52 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2607:f8b0:4003:c06::235 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:202900 Archived-At: To clarify why I want it. I have some procedurally generated functions, which I byte-compile after generation. I would like to avoid renaming attributes in the generator (not to mention the logic needed to detect whether they are used), instead I'd just temporarily suppress "unused x" warnings during this particular byte compilation. Paul On 14 April 2016 at 09:49, Paul Pogonyshev wrote: >> You can silence those (and yes, selectively this time) by prefixing the >> variable name with an underscore, which makes it explicit that you know >> the variable is not used. > > Yes, I know about that, but that means you have to go about each > individual warning in every function. And remember to rename > parameters by adding/removing underscore when usage inside the > function changes. I'd like to also have the ability to silence all > such warnings altogether. > > Paul > > On 14 April 2016 at 03:35, Stefan Monnier wrot= e: >>> In file `bytecomp.el' there is a customizable variable >>> `byte-compile-warnings' that allows one to selectively silence certain >>> warnings. >> >> I wouldn't use the word "selectively" to describe it. >> It's extremely coarse only allowing you to control broad categories of >> errors file-wide. >> >>> In particular, I'm annoyed by warnings like this: >>> Warning: Unused lexical argument =E2=80=98size=E2=80=99 >> >> You can silence those (and yes, selectively this time) by prefixing the >> variable name with an underscore, which makes it explicit that you know >> the variable is not used. >> >> >> Stefan >> >>