svn commit: r234850 - head/usr.bin/m4

Baptiste Daroussin bapt at FreeBSD.org
Mon Apr 30 21:02:58 UTC 2012


Author: bapt
Date: Mon Apr 30 21:02:57 2012
New Revision: 234850
URL: http://svn.freebsd.org/changeset/base/234850

Log:
  Respect mathematical operation order piority with the exponent gnu extension
  
  Obtained from:	OpenBSD
  Approved by:	des (mentor)

Modified:
  head/usr.bin/m4/parser.y

Modified: head/usr.bin/m4/parser.y
==============================================================================
--- head/usr.bin/m4/parser.y	Mon Apr 30 17:56:49 2012	(r234849)
+++ head/usr.bin/m4/parser.y	Mon Apr 30 21:02:57 2012	(r234850)
@@ -17,8 +17,8 @@
  *
  * $FreeBSD$
  */
-#include <stdint.h>
 #include <math.h>
+#include <stdint.h>
 #define YYSTYPE	int32_t
 extern int32_t end_result;
 extern int yylex(void);
@@ -35,9 +35,9 @@ extern int yyparse(void);
 %left EQ NE
 %left '<' LE '>' GE
 %left LSHIFT RSHIFT
-%right EXPONENT
 %left '+' '-'
 %left '*' '/' '%'
+%right EXPONENT
 %right UMINUS UPLUS '!' '~'
 
 %%


More information about the svn-src-head mailing list