From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Shiyuan Newsgroups: gmane.emacs.help Subject: define syntax using regex Date: Tue, 6 May 2014 16:35:59 -0700 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: ger.gmane.org 1399419385 10360 80.91.229.3 (6 May 2014 23:36:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 6 May 2014 23:36:25 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed May 07 01:36:18 2014 Return-path: Envelope-to: geh-help-gnu-emacs@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 1WhouI-0005EJ-Cq for geh-help-gnu-emacs@m.gmane.org; Wed, 07 May 2014 01:36:18 +0200 Original-Received: from localhost ([::1]:37796 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WhouH-0003Wv-UA for geh-help-gnu-emacs@m.gmane.org; Tue, 06 May 2014 19:36:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44596) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Whou4-0003Wo-AP for help-gnu-emacs@gnu.org; Tue, 06 May 2014 19:36:05 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Whou0-00085D-1d for help-gnu-emacs@gnu.org; Tue, 06 May 2014 19:36:04 -0400 Original-Received: from mail-vc0-x235.google.com ([2607:f8b0:400c:c03::235]:63233) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Whotz-000859-TX for help-gnu-emacs@gnu.org; Tue, 06 May 2014 19:35:59 -0400 Original-Received: by mail-vc0-f181.google.com with SMTP id hy4so254892vcb.26 for ; Tue, 06 May 2014 16:35:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=1JM8j2P5dfVikPHDqtvX5Jns7PwB2A3xIyD1sLjFUMw=; b=GIUqCdTaoFecVONyV26BfbQDd6AbEncQVdjXQtQAfrA77A3/wrOyNVPq/DraT6YnJ5 o6NgDACL4fJ6mhWJIAYxZSHPRt1jODIcbcvSVFJH1zONCGYtOD7B97reYGa9NMgoJRY6 BooSUT62MGZRiwy4qKr0xWyP1/sBy1gVIfrDU/UKesGv1lbT9oGyACyVlKQ4oHvR9oQC MtcuZNEvi74DsALI9XjzK5wDXlDTztu3sCijOsLwk/uxc2x0xjTABTRNdLl6p7ePbWAT fgI4W5zGJkFEifh6OZ47Y13W90TxUX8+avO9BTSBFS/DVZkS4MxthyG/P0ulLoWU9SCf J4vg== X-Received: by 10.52.141.74 with SMTP id rm10mr4568440vdb.6.1399419359112; Tue, 06 May 2014 16:35:59 -0700 (PDT) Original-Received: by 10.58.220.225 with HTTP; Tue, 6 May 2014 16:35:59 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:400c:c03::235 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:97568 Archived-At: Hi, I try to write a major mode for syntax highlight. The language has the structure type::variable, that is, the word before :: is a type name and after :: is a variable name. How can I define this syntax in emacs? Thanks.