From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Pietro Giorgianni" Newsgroups: gmane.emacs.bugs Subject: bug#1593: ruby-mode: problems with font-lock Date: Tue, 16 Dec 2008 12:06:43 +0100 Message-ID: <50177d450812160306v70f3661tabbe7eabd0c1545b@mail.gmail.com> Reply-To: Pietro Giorgianni , 1593@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1229522881 18878 80.91.229.12 (17 Dec 2008 14:08:01 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 17 Dec 2008 14:08:01 +0000 (UTC) To: bug-gnu-emacs@gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Dec 17 15:09:05 2008 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1LCx55-0005l4-5d for geb-bug-gnu-emacs@m.gmane.org; Wed, 17 Dec 2008 15:08:55 +0100 Original-Received: from localhost ([127.0.0.1]:53804 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LCx3s-0001GF-P1 for geb-bug-gnu-emacs@m.gmane.org; Wed, 17 Dec 2008 09:07:40 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LCqm6-0002lb-OK for bug-gnu-emacs@gnu.org; Wed, 17 Dec 2008 02:24:56 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LCqlr-0002Tf-2h for bug-gnu-emacs@gnu.org; Wed, 17 Dec 2008 02:24:39 -0500 Original-Received: from [199.232.76.173] (port=42300 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LCqln-0002SR-Lo for bug-gnu-emacs@gnu.org; Wed, 17 Dec 2008 02:24:35 -0500 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:60180) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LCqlm-0005pS-Li for bug-gnu-emacs@gnu.org; Wed, 17 Dec 2008 02:24:35 -0500 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id mBH7OJFm014034; Tue, 16 Dec 2008 23:24:32 -0800 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id mBH6vD8w005497; Tue, 16 Dec 2008 22:57:13 -0800 X-Loop: don@donarmstrong.com Resent-From: "Pietro Giorgianni" Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Wed, 17 Dec 2008 06:57:12 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1593 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by submit@emacsbugs.donarmstrong.com id=B.122942561226367 (code B ref -1); Wed, 17 Dec 2008 06:57:12 +0000 Original-Received: (at submit) by emacsbugs.donarmstrong.com; 16 Dec 2008 11:06:52 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id mBGB6mdR026355 for ; Tue, 16 Dec 2008 03:06:50 -0800 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LCXlH-0007tj-W9 for bug-gnu-emacs@gnu.org; Tue, 16 Dec 2008 06:06:48 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LCXlG-0007sm-02 for bug-gnu-emacs@gnu.org; Tue, 16 Dec 2008 06:06:47 -0500 Original-Received: from [199.232.76.173] (port=47028 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LCXlF-0007sc-Q5 for bug-gnu-emacs@gnu.org; Tue, 16 Dec 2008 06:06:45 -0500 Original-Received: from an-out-0708.google.com ([209.85.132.242]:17995) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LCXlE-0001l7-W9 for bug-gnu-emacs@gnu.org; Tue, 16 Dec 2008 06:06:45 -0500 Original-Received: by an-out-0708.google.com with SMTP id c38so1258086ana.21 for ; Tue, 16 Dec 2008 03:06:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type:content-transfer-encoding :content-disposition; bh=klmTpNRDMA+OrDyKg/eEx/0KLXN8MFGUmAbdrN85MME=; b=O5JbVpazmPFTBQc+F4gOKXu9adkNo1d7EH3GrsUTar5QQ2Y/aEgc3ekUVajohzOq/P 4IH8ZTziNU/k6/wVmnGTQgIK1m/kco3reXpWeC3qFy1xjn0YITwTMSYAKB3lGN++TQol Ha2nqw+j0uHcIyDSnF1qQIrjq+3Fnm3277oKc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type :content-transfer-encoding:content-disposition; b=UDP7NwBPRT1aNSWoFC7K7KwV4afEdbfHqhnjHmAA/HXBrQVYO2xevtM+nWgNZ9GB/W baXePdunSWbJX13d+4ENut5zwZG03SeMTWnkhIO+3vyCwvKW3OhVUGmOBhSlZCe+IPUZ nj1CE8oEhJhsRDOLrVTxmYfTh3xv8Q2/uBPw4= Original-Received: by 10.65.44.11 with SMTP id w11mr7219424qbj.58.1229425603141; Tue, 16 Dec 2008 03:06:43 -0800 (PST) Original-Received: by 10.65.220.16 with HTTP; Tue, 16 Dec 2008 03:06:43 -0800 (PST) Content-Disposition: inline X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Resent-Date: Wed, 17 Dec 2008 02:24:39 -0500 X-Mailman-Approved-At: Wed, 17 Dec 2008 08:59:00 -0500 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:23321 Archived-At: The syntax %{#{'?'}} , while legal (it is equivalent to '?'), makes all the following text appear in font-lock-string-face. The same happens with %{#{"?"}} , and seems to rise from the ?" or ?' part: if I put a space (or whatever) after the ? , things work. Real life example (from the sources of rubyonrails): self.class_eval %{ def self.#{method_id}(*args) guard_protected_attributes = false if args[0].is_a?(Hash) guard_protected_attributes = true attributes = args[0].with_indifferent_access find_attributes = attributes.slice(*[:#{attribute_names.join(',:')}]) else find_attributes = attributes = construct_attributes_from_arguments([:#{attribute_names.join(',:')}], args) end options = { :conditions => find_attributes } set_readonly_option!(options) record = find_initial(options) if record.nil? record = self.new { |r| r.send(:attributes=, attributes, guard_protected_attributes) } #{'yield(record) if block_given?'} #{'record.save' if instantiator == :create} record else record end end }, __FILE__, __LINE__ --- In GNU Emacs 22.3.1 (i386-mingw-nt5.1.2600) of 2008-09-06 on SOFT-MJASON Windowing system distributor `Microsoft Corp.', version 5.1.2600 configured using `configure --with-gcc (3.4)' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: ITA locale-coding-system: cp1252 default-enable-multibyte-characters: t Major mode: Ruby Minor modes in effect: erc-log-mode: t erc-menu-mode: t erc-autojoin-mode: t erc-ring-mode: t erc-pcomplete-mode: t erc-track-mode: t erc-track-minor-mode: t erc-match-mode: t erc-button-mode: t erc-fill-mode: t erc-stamp-mode: t erc-netsplit-mode: t erc-highlight-nicknames-mode: t erc-irccontrols-mode: t erc-noncommands-mode: t erc-readonly-mode: t shell-dirtrack-mode: t recentf-mode: t display-time-mode: t encoded-kbd-mode: t tooltip-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t unify-8859-on-encoding-mode: t utf-translate-cjk-mode: t auto-compression-mode: t column-number-mode: t line-number-mode: t Recent input: c e n s o r e d Recent messages: censored... Loading emacsbug...done