From mboxrd@z Thu Jan 1 00:00:00 1970 From: Samuel Loury Subject: `org-make-tags-matcher' broken by lexical-binding Date: Thu, 07 Jan 2016 08:58:16 +0100 Message-ID: <87si294y93.fsf@gmail.com> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:48024) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aH5Sq-0006ud-EO for emacs-orgmode@gnu.org; Thu, 07 Jan 2016 02:58:33 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aH5Sn-0007OU-Nf for emacs-orgmode@gnu.org; Thu, 07 Jan 2016 02:58:32 -0500 Received: from mail-wm0-x22c.google.com ([2a00:1450:400c:c09::22c]:34814) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aH5Sn-0007OO-GK for emacs-orgmode@gnu.org; Thu, 07 Jan 2016 02:58:29 -0500 Received: by mail-wm0-x22c.google.com with SMTP id u188so87634138wmu.1 for ; Wed, 06 Jan 2016 23:58:28 -0800 (PST) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: OrgMode ML , Nicolas Goaziou --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hi, I tried to move to the master branch and found out that the work about lexical-binding everywhere is going well. Nice work Nicolas :-). I found out that `org-make-tags-matcher' relies heavily on the dynamic binding. First of all, it assumes that the `todo-only' variable is scoped in. This is simple to fix by making todo-only a parameter of the function and fixing the calls. Then, it returns a form that relies on the fact that the variables todo and tags-list are scoped in. AFAICU, this sounds a bit trickier to fix because the usage of the returned "matcher" can be correctly used depending on the case. For instance, `org-clock-get-table-data' gives to `org-clock-sum' a lamdba function that evaluates the obtained matcher. The attempt to funcall-ing the lambda in `org-clock-sum' complains that tags-list does not exist. I probably won't have the time to create a patch for that, so I just warn about the problem. Hope that helps. =2D-=20 Konubinix GPG Key : 7439106A Fingerprint: 5993 BE7A DA65 E2D9 06CE 5C36 75D2 3CED 7439 106A --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBAgAGBQJWjhqbAAoJEHXSPO10ORBq4zAH/2WZza17ylb1obE1b9ymEA/c qJqSvE6cRttm9+AdRXYrsnP62xoUrnZYwnHEpQxyRBjzPYtDDOnbP+OFSwEcVjeQ Cvowgd7VLbQiREXGh7GtSC2L++0apvdOvwIvn0jKdNolQbs0IclvOgX65rMz3rno L3qp+8zK3uRU5ag3XutVspWPh+6OsV8mUL8g7HojkS1q+rNFwDIT7MOrZ2i13Tn5 yRuXFF5XfIcj2nRHxqXoXuRYtGBNvbEJaXm4aduhJXJtogoky8qkIfqIznWPTF4B xlOaVBqcm5vEwFCc7CXHL710z1HQgG8r6cUIgzdrKF3SBdVWDYWvr1XNo3jqA5E= =bfGz -----END PGP SIGNATURE----- --=-=-=--