1*d219b4ceSAdam Hornacek/* 2*d219b4ceSAdam Hornacek * CDDL HEADER START 3*d219b4ceSAdam Hornacek * 4*d219b4ceSAdam Hornacek * The contents of this file are subject to the terms of the 5*d219b4ceSAdam Hornacek * Common Development and Distribution License (the "License"). 6*d219b4ceSAdam Hornacek * You may not use this file except in compliance with the License. 7*d219b4ceSAdam Hornacek * 8*d219b4ceSAdam Hornacek * See LICENSE.txt included in this distribution for the specific 9*d219b4ceSAdam Hornacek * language governing permissions and limitations under the License. 10*d219b4ceSAdam Hornacek * 11*d219b4ceSAdam Hornacek * When distributing Covered Code, include this CDDL HEADER in each 12*d219b4ceSAdam Hornacek * file and include the License file at LICENSE.txt. 13*d219b4ceSAdam Hornacek * If applicable, add the following below this CDDL HEADER, with the 14*d219b4ceSAdam Hornacek * fields enclosed by brackets "[]" replaced with your own identifying 15*d219b4ceSAdam Hornacek * information: Portions Copyright [yyyy] [name of copyright owner] 16*d219b4ceSAdam Hornacek * 17*d219b4ceSAdam Hornacek * CDDL HEADER END 18*d219b4ceSAdam Hornacek */ 19*d219b4ceSAdam Hornacek 20*d219b4ceSAdam Hornacek/* 21*d219b4ceSAdam Hornacek * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. 22*d219b4ceSAdam Hornacek * Portions Copyright (c) 2017, Chris Fraire <cfraire@me.com>. 23*d219b4ceSAdam Hornacek */ 24*d219b4ceSAdam Hornacek 25*d219b4ceSAdam HornacekIdentifier = [a-zA-Z_] [a-zA-Z0-9_]* 26*d219b4ceSAdam Hornacek 27*d219b4ceSAdam HornacekNumber = \$? [0-9]+\.[0-9]+| [0-9][0-9]* | [0][xX] [0-9a-fA-F]+ 28*d219b4ceSAdam Hornacek 29*d219b4ceSAdam Hornacek/* 30*d219b4ceSAdam Hornacek * Rather than enumerate letters, just treat all hyphen- or plus- with a 31*d219b4ceSAdam Hornacek * single-char as a unary op. "req_lookahead" because an assertion is needed 32*d219b4ceSAdam Hornacek * that it is followed by non-word or end-of-line. 33*d219b4ceSAdam Hornacek */ 34*d219b4ceSAdam HornacekUnary_op_req_lookahead = [\-\+]{Unary_op_char} 35*d219b4ceSAdam HornacekUnary_op_char = [A-Za-z] 36*d219b4ceSAdam Hornacek 37*d219b4ceSAdam HornacekBinary_op = [\-]("ef"|"nt"|"ot"|"eq"|"ge"|"gt"|"le"|"lt"|"ne"){WhspChar} 38