Go to file
H. Peter Anvin (Intel) f24d975008 preproc: fix list corruption bug; clean up token handling
expand_one_smacro() would corrupt the end of the list if a macro
expanded to another macro with arguments, which was also the last part
of the expansion.

Instead of doing all that testing with ttail, just scan forward at the
end to find the tail pointer; it is O(n) regardless.

Clean up the handling of tokens: use inline functions rather than odd
macros that sometimes modify their arguments and sometimes don't, and
fold some common code into new functions.

The tok_is() and tok_isnt() functions always are used with single
characters, so make it explicitly so (and remove the local hacks used
in some places.)

Allow using nasm_malloc() rather than blocked Tokens; this makes tools
like valgrind more useful in their reports.

For the future, consider making Tokens a separate memory allocation
immediately followed by the text, instead of using a pointer; we
allocate space for the string in almost every case anyway. Also
consider making it a doubly linked list...

Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com>
2019-09-18 18:17:26 -07:00
asm preproc: fix list corruption bug; clean up token handling 2019-09-18 18:17:26 -07:00
autoconf autoconf: update check for gcc inlines 2019-08-16 00:14:17 -07:00
common Don't sort opcodes; move all pseudo-ops to the beginning 2017-05-01 21:44:24 -07:00
config config.h: separate function and function pointer attributes; automate 2019-08-16 00:08:27 -07:00
contrib contrib/MSVC6.txt: Add guide how to use nasm in MSVC6 2010-01-24 23:17:55 +03:00
disasm error: replace nasm_verror() indirection with preproc callback 2019-08-28 19:02:47 -07:00
doc Correct __ALIGN_ -> __?ALIGN_ 2019-08-27 17:21:28 -07:00
headers headers: Update year 2010-04-25 12:02:38 +04:00
include Change LBL_NONE to LBL_none 2019-09-12 20:26:23 -04:00
macros Drop unnecessary EXTERN symbols 2019-09-12 20:21:03 -04:00
misc Move <string.h> inclusion to compiler.h 2018-12-26 06:32:37 -08:00
Mkfiles iflags: move definitions to a separate file; auto-generate more 2019-08-06 22:12:11 -07:00
nasmlib errors: be more robust in handling unexpected fatal errors 2019-08-28 18:32:46 -07:00
nsis nsis: use /solid compression for smaller size 2017-04-07 11:05:09 -07:00
output outelf: use "symbols" not "variables" in error messages 2019-09-12 17:48:16 -07:00
perllib perl files: clean up warnings 2019-08-09 13:30:19 -07:00
rdoff error: replace nasm_verror() indirection with preproc callback 2019-08-28 19:02:47 -07:00
stdlib Remove #includes already provided by "compiler.h" 2018-12-27 12:45:44 -08:00
test elf: fix "object" symbol keyword 2019-09-12 17:45:11 -07:00
tools perl files: clean up warnings 2019-08-09 13:30:19 -07:00
travis travis utf-error test: update error messages 2019-09-12 18:36:18 -07:00
x86 LEA: allow immediate syntax; ignore operand size entirely 2019-08-14 15:23:00 -07:00
.gitignore config.h: separate function and function pointer attributes; automate 2019-08-16 00:08:27 -07:00
.travis.yml travis: Disable osx for a while 2018-10-17 21:40:14 +03:00
AUTHORS Correct name spelling and email address 2015-01-18 20:21:14 +02:00
autogen.sh autogen.sh: allow overriding autotools location, and handle missing 2019-08-07 17:43:20 -07:00
ChangeLog Documention Changes for Release 2.00 2007-11-25 14:25:13 -08:00
CHANGES Move the revision history into the documentation 2008-07-14 02:45:57 -04:00
configure.ac configure.ac: look for unconfig.h not uninit.h... 2019-08-27 15:13:15 -07:00
INSTALL Update the INSTALL file to match current reality 2008-06-28 18:53:55 -07:00
LICENSE LICENSE: update year 2010-08-12 20:15:27 -07:00
Makefile.in Makefile.in: use $(ALL_LDFLAGS) 2019-08-16 01:29:49 -07:00
nasm.spec.in nasm.spec.in: remove obsolete files 2018-12-26 06:13:06 -08:00
nasm.spec.sed nasm.spec: use a sed file to insert perl dependencies 2017-04-23 18:54:23 -07:00
nasm.txt Add group aliases for all prefixed warnings. 2019-06-06 20:53:17 -07:00
ndisasm.txt ndisasm: man -- Add missing -p option 2013-04-20 20:18:46 +04:00
README.md Add travis status into readme 2018-10-17 21:40:14 +03:00
SubmittingPatches Add SubmittingPatches file 2010-10-03 21:02:08 +04:00
version Mark this branch as 2.15rc0 2018-06-15 17:59:34 -07:00
version.pl preproc: standard macros now C-safe, %aliases off, fix %? recursion 2019-08-27 16:42:41 -07:00

NASM, the Netwide Assembler

master

Many many developers all over the net respect NASM for what it is: a widespread (thus netwide), portable (thus netwide!), very flexible and mature assembler tool with support for many output formats (thus netwide!!).

Now we have good news for you: NASM is licensed under the "simplified" (2-clause) BSD license. This means its development is open to even wider society of programmers wishing to improve their lovely assembler.

Visit our nasm.us website for more details. We are gradually moving services away from Sourceforge. For our remaining Sourceforge services see here.

With best regards, the NASM crew.