Michael Urman
970e89dbee
test case for %define to a %define. non-recursive.
...
svn path=/trunk/yasm/; revision=510
23 years ago
Michael Urman
a74a807bba
Catch a few missing inhibited directives (not implemented yet anyway).
...
Preserve non-trailing whitespace (cleaner look, supports %define foo()).
Condense %line, \n or %line, %line into single %line.
svn path=/trunk/yasm/; revision=509
23 years ago
Michael Urman
90283e877e
Handle output inhibition more properly; %includes inside %ifs don't
...
actually %include, etc.
Also fix starting line to be 1, not 0.
svn path=/trunk/yasm/; revision=508
23 years ago
Michael Urman
655f98255f
Several new tests.
...
svn path=/trunk/yasm/; revision=507
23 years ago
Michael Urman
86e1c8338c
Catch "errors" and update report format
...
svn path=/trunk/yasm/; revision=506
23 years ago
Michael Urman
716884b0bb
Add ifdef tests.
...
svn path=/trunk/yasm/; revision=505
23 years ago
Michael Urman
314085475c
add beginnings of test suite for yapp
...
svn path=/trunk/yasm/; revision=504
23 years ago
Michael Urman
2c051baa0b
return [ and ] characters
...
svn path=/trunk/yasm/; revision=503
23 years ago
Michael Urman
944853f03a
Removed spurious include of objfmt
...
Added some debugging printf to isolate and fix failing define case
svn path=/trunk/yasm/; revision=502
23 years ago
Michael Urman
22d4d7b74d
Remove some spurious includes.
...
svn path=/trunk/yasm/; revision=501
23 years ago
Peter Johnson
b667c33ea5
Don't call bc_resolve (it's going away soon).
...
FIXME: Do we really need to check completion of all sections?
svn path=/trunk/yasm/; revision=500
23 years ago
Peter Johnson
8b262b4a0c
Add autom4te.cache.
...
svn path=/trunk/yasm/; revision=499
23 years ago
Peter Johnson
8f44f77441
Switch to requiring autoconf 2.50. We should really be using configure.ac
...
instead of configure.in for the autoconf input file, but gettextize 0.10.35
complains if configure.in does not exist.
svn path=/trunk/yasm/; revision=498
23 years ago
Peter Johnson
d854f4cf9f
Switch to requiring autoconf 2.50. We should really be using configure.ac
...
instead of configure.in for the autoconf input file, but gettextize 0.10.35
complains if configure.in does not exist.
svn path=/trunk/yasm/; revision=497
23 years ago
Peter Johnson
d2a2e6b3f8
Add bcs_last() macro.
...
svn path=/trunk/yasm/; revision=496
23 years ago
Peter Johnson
251588a7ad
Only check for dmalloc library and dmalloc.h if --enable-dmalloc is used. This
...
prevents it being linked in even if it isn't enabled.
svn path=/trunk/yasm/; revision=495
23 years ago
Peter Johnson
35bdf289f4
Only check for dmalloc library and dmalloc.h if --enable-dmalloc is used. This
...
prevents it being linked in even if it isn't enabled.
svn path=/trunk/yasm/; revision=494
23 years ago
Peter Johnson
c9d73bae1e
Make duplicate definition (w/regards to COMMON and EXTERN) work properly.
...
svn path=/trunk/yasm/; revision=493
23 years ago
Peter Johnson
c855e4061e
Move static structures from .h to .c, include .h in .l.
...
svn path=/trunk/yasm/; revision=492
23 years ago
Peter Johnson
4933f17355
Fix warning.
...
svn path=/trunk/yasm/; revision=491
23 years ago
Peter Johnson
07c3299820
Add bin object format.
...
Changes to:
objfmt interface: added parameter to directive() for sections access.
section interface: moved start to be present for all section types.
basic optimizer: add section start to offset determination.
(much of the section start changes are due to the need to make sure offsets
don't end up being optimized into byte-sized offsets that can't be relocated).
svn path=/trunk/yasm/; revision=490
23 years ago
Peter Johnson
d738a39f49
Allow replacing with no extension (eg w/o an appended '.'). Needed for bin
...
objfmt output.
svn path=/trunk/yasm/; revision=489
23 years ago
Peter Johnson
ba2c819e71
Move BitCount() macro from hamt.c to util.h.
...
svn path=/trunk/yasm/; revision=488
23 years ago
Peter Johnson
96db2a27b2
Add yapp-token.c.
...
svn path=/trunk/yasm/; revision=487
23 years ago
Michael Urman
4818dbe555
Fixed some warnings.
...
The wussy way, cause i didn't comment any of the new prototypes.
svn path=/trunk/yasm/; revision=486
23 years ago
Michael Urman
7c073b5c23
Add const char *in_filename arguments to
...
- preproc initialize function
- parser parse function (to pass to preproc initialize)
so that the preprocessor has a clue what file it's in.
svn path=/trunk/yasm/; revision=484
23 years ago
Michael Urman
2d0615384d
YAPP has arrived.
...
Or at least it has begun. At this point it can only handle:
%define
%if*def
%el*def
%else
%endif
%include (to some degree; needs a lot of thought, but recurses fine)
and replacing simple %defines (like %define foo bar)
And like all code, it's probably horribly inconsistent about variable
names, etc. We'll wash it later.
svn path=/trunk/yasm/; revision=483
23 years ago
Michael Urman
6b65e7a522
Update main files to include support for yapp.
...
This includes defaulting to yapp for ./yasm -e passes.
svn path=/trunk/yasm/; revision=482
23 years ago
Peter Johnson
62750a30d3
Enhance bc_resolve() implementation a bit, but comment out, as this function
...
will probably disappear in the near future (its functionality will be handled
directly by the object format module without the need for another pass).
svn path=/trunk/yasm/; revision=481
23 years ago
Peter Johnson
97772e4452
Support NASM syntax of options such as -fobj (as well as -f obj).
...
svn path=/trunk/yasm/; revision=480
23 years ago
Peter Johnson
5d2e9ea0f0
Allow preprocess-only and setting of preproc. Update main() and related
...
functions to be a bit more clean.
svn path=/trunk/yasm/; revision=479
23 years ago
Peter Johnson
4ee8ccc660
Update bug mailing address to <bug-yasm@tortall.net>.
...
svn path=/trunk/yasm/; revision=478
23 years ago
Peter Johnson
f6f4313ff6
Use non-preprocessed BITS directive so this can be assembled with current YASM.
...
svn path=/trunk/yasm/; revision=477
23 years ago
Peter Johnson
0177d689a1
Revamp object format functional interface a bit. Now, only the output()
...
function gets a FILE *, and it's the only function that can write to a file.
The object file is thus not opened until AFTER parsing and most error checking
is complete. Necessitated adding a special case for the dbg object format
because it needs to output to the "object" (debug) file from essentially every
function. Added a global (debug_file) to support this.
svn path=/trunk/yasm/; revision=476
23 years ago
Peter Johnson
a0d61f00c1
Enable second pass (resolve/calculate known values).
...
svn path=/trunk/yasm/; revision=475
23 years ago
Peter Johnson
f5bf04dd41
Include errwarn.h to declare ErrorAt().
...
svn path=/trunk/yasm/; revision=474
23 years ago
Peter Johnson
01481e7d47
Test circular reference detection. Very basic examples from NASM's docs on
...
critical expressions.
NASM behavior: 1-3 fail, 4 generates a 4-byte offset in the memory expression.
YASM behavior: 1&2 fail (and rightfully so :), 3 works as expected, and 4
generates a 1-byte offset.
svn path=/trunk/yasm/; revision=473
23 years ago
Peter Johnson
964c755067
Indicate actual line number of circular reference error.
...
svn path=/trunk/yasm/; revision=472
23 years ago
Peter Johnson
7217fd10db
Bring up-to-date with traverse function changes. Start trying to check for
...
circular references.
svn path=/trunk/yasm/; revision=471
23 years ago
Peter Johnson
391736c2a6
Correct optimize() comment.
...
svn path=/trunk/yasm/; revision=470
23 years ago
Peter Johnson
f781881f80
Terminate & cleanup early if an error occurs during the optimization phase.
...
svn path=/trunk/yasm/; revision=469
23 years ago
Peter Johnson
8a515e968a
Reverse how traverse functions do early termination (now, they terminate on
...
a non-zero func return and return the value func returned). Document the
changes in the header files.
svn path=/trunk/yasm/; revision=468
23 years ago
Peter Johnson
4f7daa4d39
Fix issue with how symrec's are handled when an expression is copied: old code
...
just assigned the pointer: but the symrec is deleted (if it's not in the symbol
table) when the expr is deleted. Thus, we need to create a copy of the symrec
instead of just reusing the same value if it's going to be deleted later. This
trickles down to objfmt to copy the objfmt-local data.
svn path=/trunk/yasm/; revision=467
23 years ago
Peter Johnson
2f20fc4846
Added --version option. Pass option descriptions, --help, and --version
...
messages through gettext. Rework handling of --version and --help.
svn path=/trunk/yasm/; revision=466
23 years ago
Peter Johnson
90625f71e1
Add semicolon at end of error handling code to fix syntax errors. Only seen
...
on Cygwin so far, but a legitimate error.
svn path=/trunk/yasm/; revision=465
23 years ago
Peter Johnson
7462e32ecf
Bring up-to-date with tree and build changes.
...
svn path=/trunk/yasm/; revision=464
23 years ago
Peter Johnson
ef3eff4f62
Enhance error/warning framework by allowing specific warnings to be disabled,
...
all warnings to be disabled, and warnings to be treated as errors, much in the
style of GNU tools such as gcc.
svn path=/trunk/yasm/; revision=463
23 years ago
Peter Johnson
cf48f57fca
Check for param=NULL before dereferencing it in sopt case.
...
svn path=/trunk/yasm/; revision=462
23 years ago
Peter Johnson
f61b5746f1
Don't compact into a short form if one's not available.
...
svn path=/trunk/yasm/; revision=461
23 years ago
Peter Johnson
044cc90233
Make jcc's default to JR_SHORT in NASM syntax, and test for this possibility
...
in calc_len().
svn path=/trunk/yasm/; revision=460
23 years ago