Merge [2323] from trunk (handle and ignore [warning]).
svn path=/branches/yasm-1.0/; revision=2325
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0bbb68b..018f345 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -26,11 +26,11 @@
FORCE)
ENDIF(NOT CMAKE_BUILD_TYPE)
-set (YASM_VERSION_MAJOR 0)
-set (YASM_VERSION_MINOR 6)
-set (YASM_VERSION_SUBMINOR 99)
+set (YASM_VERSION_MAJOR 1)
+set (YASM_VERSION_MINOR 0)
+set (YASM_VERSION_SUBMINOR 0)
set (PACKAGE_INTVER "${YASM_VERSION_MAJOR}.${YASM_VERSION_MINOR}.${YASM_VERSION_SUBMINOR}")
-set (PACKAGE_BUILD "HEAD")
+set (PACKAGE_BUILD "BRANCH")
set (PACKAGE_VERSION ${PACKAGE_BUILD})
set (PACKAGE_STRING "yasm ${PACKAGE_VERSION}")
diff --git a/Mkfiles/dj/config.h b/Mkfiles/dj/config.h
index 0ce8a3f..2383b19 100644
--- a/Mkfiles/dj/config.h
+++ b/Mkfiles/dj/config.h
@@ -119,22 +119,22 @@
#define PACKAGE_BUGREPORT "bug-yasm@tortall.net"
/* Define to build version of this package. */
-#define PACKAGE_BUILD "HEAD"
+#define PACKAGE_BUILD "BRANCH"
/* Define to internal version of this package. */
-#define PACKAGE_INTVER "0.7.99"
+#define PACKAGE_INTVER "1.0.0"
/* Define to the full name of this package. */
#define PACKAGE_NAME "yasm"
/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "yasm HEAD"
+#define PACKAGE_STRING "yasm 1.0.x"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "yasm"
/* Define to the version of this package. */
-#define PACKAGE_VERSION "HEAD"
+#define PACKAGE_VERSION "1.0.x"
/* Define if the C compiler supports function prototypes. */
#define PROTOTYPES 1
@@ -158,7 +158,7 @@
#define STDC_HEADERS 1
/* Version number of package */
-#define VERSION "HEAD"
+#define VERSION "1.0.x"
/* Define if using the dmalloc debugging malloc package */
/* #undef WITH_DMALLOC */
diff --git a/Mkfiles/vc10/config.h b/Mkfiles/vc10/config.h
index 96e2ddd..100c87d 100644
--- a/Mkfiles/vc10/config.h
+++ b/Mkfiles/vc10/config.h
@@ -117,22 +117,22 @@
#define PACKAGE_BUGREPORT "bug-yasm@tortall.net"
/* Define to build version of this package. */
-#define PACKAGE_BUILD "HEAD"
+#define PACKAGE_BUILD "BRANCH"
/* Define to internal version of this package. */
-#define PACKAGE_INTVER "0.7.99"
+#define PACKAGE_INTVER "1.0.0"
/* Define to the full name of this package. */
#define PACKAGE_NAME "yasm"
/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "yasm HEAD"
+#define PACKAGE_STRING "yasm 1.0.x"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "yasm"
/* Define to the version of this package. */
-#define PACKAGE_VERSION "HEAD"
+#define PACKAGE_VERSION "1.0.x"
/* Define if the C compiler supports function prototypes. */
#define PROTOTYPES 1
@@ -156,7 +156,7 @@
#define STDC_HEADERS 1
/* Version number of package */
-#define VERSION "HEAD"
+#define VERSION "1.0.x"
/* Define if using the dmalloc debugging malloc package */
/* #undef WITH_DMALLOC */
diff --git a/Mkfiles/vc9/config.h b/Mkfiles/vc9/config.h
index 96e2ddd..100c87d 100644
--- a/Mkfiles/vc9/config.h
+++ b/Mkfiles/vc9/config.h
@@ -117,22 +117,22 @@
#define PACKAGE_BUGREPORT "bug-yasm@tortall.net"
/* Define to build version of this package. */
-#define PACKAGE_BUILD "HEAD"
+#define PACKAGE_BUILD "BRANCH"
/* Define to internal version of this package. */
-#define PACKAGE_INTVER "0.7.99"
+#define PACKAGE_INTVER "1.0.0"
/* Define to the full name of this package. */
#define PACKAGE_NAME "yasm"
/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "yasm HEAD"
+#define PACKAGE_STRING "yasm 1.0.x"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "yasm"
/* Define to the version of this package. */
-#define PACKAGE_VERSION "HEAD"
+#define PACKAGE_VERSION "1.0.x"
/* Define if the C compiler supports function prototypes. */
#define PROTOTYPES 1
@@ -156,7 +156,7 @@
#define STDC_HEADERS 1
/* Version number of package */
-#define VERSION "HEAD"
+#define VERSION "1.0.x"
/* Define if using the dmalloc debugging malloc package */
/* #undef WITH_DMALLOC */
diff --git a/configure.ac b/configure.ac
index 638d654..628e734 100644
--- a/configure.ac
+++ b/configure.ac
@@ -5,7 +5,7 @@
# autoconf setup
#
AC_PREREQ(2.53)
-AC_INIT([yasm], [HEAD], [bug-yasm@tortall.net])
+AC_INIT([yasm], [1.0.x], [bug-yasm@tortall.net])
#AC_CONFIG_SRCDIR([src/main.c])
AC_CONFIG_AUX_DIR(config)
AC_CONFIG_HEADER([config.h])
@@ -13,9 +13,9 @@
AM_INIT_AUTOMAKE([1.9.6 foreign])
AM_MAINTAINER_MODE
-AC_DEFINE(PACKAGE_INTVER, ["0.7.99"],
+AC_DEFINE(PACKAGE_INTVER, ["1.0.0"],
[Define to internal version of this package.])
-AC_DEFINE(PACKAGE_BUILD, ["HEAD"], [Define to build version of this package.])
+AC_DEFINE(PACKAGE_BUILD, ["BRANCH"], [Define to build version of this package.])
#
# autoconf command-line options
diff --git a/modules/parsers/nasm/nasm-parse.c b/modules/parsers/nasm/nasm-parse.c
index 8cbbe53..1fcffe0 100644
--- a/modules/parsers/nasm/nasm-parse.c
+++ b/modules/parsers/nasm/nasm-parse.c
@@ -1337,7 +1337,47 @@
yasm_expr *e;
yasm_symrec *sym;
- switch (curtok) {
+ /* directives allow very little and handle IDs specially */
+ if (type == DIR_EXPR) {
+ switch (curtok) {
+ case '~':
+ get_next_token();
+ e = parse_expr6(parser_nasm, type);
+ if (!e) {
+ yasm_error_set(YASM_ERROR_SYNTAX,
+ N_("expected expression after %s"), "`~'");
+ return NULL;
+ }
+ return p_expr_new_branch(YASM_EXPR_NOT, e);
+ case '(':
+ get_next_token();
+ e = parse_expr(parser_nasm, type);
+ if (!e) {
+ yasm_error_set(YASM_ERROR_SYNTAX,
+ N_("expected expression after %s"), "`('");
+ return NULL;
+ }
+ if (!expect(')')) {
+ yasm_error_set(YASM_ERROR_SYNTAX, N_("missing parenthesis"));
+ return NULL;
+ }
+ get_next_token();
+ return e;
+ case INTNUM:
+ e = p_expr_new_ident(yasm_expr_int(INTNUM_val));
+ break;
+ case REG:
+ e = p_expr_new_ident(yasm_expr_reg(REG_val));
+ break;
+ case ID:
+ sym = yasm_symtab_use(p_symtab, ID_val, cur_line);
+ e = p_expr_new_ident(yasm_expr_sym(sym));
+ yasm_xfree(ID_val);
+ break;
+ default:
+ return NULL;
+ }
+ } else switch (curtok) {
case '+':
get_next_token();
e = parse_expr6(parser_nasm, type);
@@ -1413,8 +1453,10 @@
return e;
case INTNUM:
e = p_expr_new_ident(yasm_expr_int(INTNUM_val));
- get_next_token();
- return e;
+ break;
+ case FLTNUM:
+ e = p_expr_new_ident(yasm_expr_float(FLTNUM_val));
+ break;
case REG:
if (type == DV_EXPR) {
yasm_error_set(YASM_ERROR_SYNTAX,
@@ -1422,24 +1464,6 @@
return NULL;
}
e = p_expr_new_ident(yasm_expr_reg(REG_val));
- get_next_token();
- return e;
- }
-
- /* directives allow very little and handle IDs specially */
- if (type == DIR_EXPR) {
- switch (curtok) {
- case ID:
- sym = yasm_symtab_use(p_symtab, ID_val, cur_line);
- e = p_expr_new_ident(yasm_expr_sym(sym));
- yasm_xfree(ID_val);
- break;
- default:
- return NULL;
- }
- } else switch (curtok) {
- case FLTNUM:
- e = p_expr_new_ident(yasm_expr_float(FLTNUM_val));
break;
case STRING:
{
@@ -1490,7 +1514,6 @@
default:
return NULL;
}
-
get_next_token();
return e;
}