Sven M. Hallberg
caf00006f3
add iterative API to LALR backend
2015-09-16 23:43:30 +02:00
Sven M. Hallberg
ff55937e00
split out h_pprint_lr_info for debugging purposes
2015-09-16 23:42:18 +02:00
Sven M. Hallberg
42d35fb883
move chunk position into HInputStream and simplify internal chunk API
2015-09-16 23:25:36 +02:00
Sven M. Hallberg
e385e0e5de
Merge branch 'fix-lalr_bugs' into iterative
2015-09-16 22:21:53 +02:00
Sven M. Hallberg
cdd1289936
fix printing of "negative" byte values
2015-09-16 22:17:31 +02:00
Sven M. Hallberg
7319c48e59
fix reshape for h_many
2015-09-16 20:06:24 +02:00
Sven M. Hallberg
db95cda229
add regression test for wrong nesting of h_many/h_sequence results with CFG backends
2015-09-16 20:06:06 +02:00
Sven M. Hallberg
3eb2a2023d
add a comment regarding another CHARSET case
2015-09-16 18:51:16 +02:00
Sven M. Hallberg
422f88c4aa
handle charset left-hand-side in LALR compile
2015-09-16 18:43:52 +02:00
Sven M. Hallberg
31c460780f
add regression test for unhandled charset left-hand-side case in LALR compile
2015-09-16 18:23:32 +02:00
Sven M. Hallberg
5b4550ab0f
make MARK a constant that points to itself
2015-09-08 16:19:45 +02:00
Sven M. Hallberg
fb5122ec88
fix result bit_length for LR backends
2015-09-07 15:37:26 +02:00
Sven M. Hallberg
4f455aa97e
fix result bit_length for LL(k)
2015-09-07 15:33:50 +02:00
Sven M. Hallberg
29434869d5
add result_length test
2015-09-07 11:05:06 +02:00
Sven M. Hallberg
bfb795b093
add window buffer to look across chunk boundaries
2015-09-06 14:48:51 +02:00
Sven M. Hallberg
73e92f04df
save kmax in HLLkTable
2015-09-06 14:48:41 +02:00
Sven M. Hallberg
8995097a1d
let's just use ((void *)-1) as another invalid pointer result
2015-09-05 22:43:49 +02:00
Sven M. Hallberg
90b6f30fa1
add a test that needs to suspend on lookahead in the middle of a chunk
2015-09-04 21:06:50 +02:00
Sven M. Hallberg
1276004250
handle suspend on lookahead at the very end of the chunk
2015-09-04 21:05:56 +02:00
Sven M. Hallberg
010a1a36ff
int_range test does not work for regex backend
2015-09-04 16:48:01 +02:00
Sven M. Hallberg
d4f933b2d3
move last_chunk flag into HInputStream
2015-09-04 12:55:37 +02:00
Sven M. Hallberg
28fa93d4cc
make overrun flag a bool to match its usage
2015-09-04 12:54:00 +02:00
Sven M. Hallberg
d3fd0da7b7
don't skip tests on compile failure anymore
2015-09-04 12:48:10 +02:00
Sven M. Hallberg
932c9717d7
oops, forgot about the lookahead
2015-09-04 12:34:34 +02:00
Sven M. Hallberg
10fde548ad
add a test for iterative parsing
2015-09-03 19:58:39 +02:00
Sven M. Hallberg
0231dc141e
add iterative API to LL(k) backend
2015-09-03 19:18:07 +02:00
Sven M. Hallberg
f1d6d0bc5e
split h_llk_parse into start/chunk/finish internally
2015-09-03 19:15:57 +02:00
Sven M. Hallberg
2845a9391e
add API and backend hooks for iterative (chunked) parsing
2015-09-03 15:03:01 +02:00
Sven M. Hallberg
57b3495d5e
calculate result bit_length of h_bind and h_left and friends properly
2015-08-31 17:28:01 +02:00
Meredith L. Patterson
e01d10f0ab
Merge pull request #139 from pesco/fix-llk_zero_end
...
add a missing end-of-input check in the LL(k) backend
2015-08-25 14:49:15 +02:00
Sven M. Hallberg
c5f2c5aa2b
add a missing end-of-input check in the LL(k) backend
2015-08-25 14:14:48 +02:00
TQ Hirsch
25b27490c3
Merge pull request #138 from uucidl/platform-timing
...
Platform compilation improvement (windows port)
2015-08-19 12:56:49 +02:00
Nicolas Léveillé
9557448ae6
Introduce {v,}asprintf for windows
...
We have now again two functions called h_platform_vasprintf and
h_platform_asprintf. On windows they are implemented in terms of vsnprint
and the like. On BSD/GNU libraries we use the supplied vasprintf and
asprintf.
2015-08-16 16:46:52 +02:00
Nicolas Léveillé
124b4c381b
regex_debug.c: Stop including dlfcn.h
...
Since the block of code has been disabled anyway and is not very
portable, we introduce a define to control both the include
and the code.
2015-08-16 16:21:21 +02:00
Nicolas Léveillé
102b9593dc
Update list of files to compile on windows
2015-08-16 16:20:53 +02:00
Nicolas Léveillé
e74e23d672
Change system_allocator to store size of blocks only for debugging
...
Storing the size of the blocks is now only activated when DEBUG__MEMFILL
has been defined.
2015-08-16 09:15:20 +02:00
Nicolas Léveillé
d9ae097533
Remove void pointer arithmetics in system_allocator.c
...
We replace instances of void* w/ char* arithmetics.
This allows system_allocator.c to be compiled with MSVC.
Also we introduce a struct to represent the size_t header.
2015-08-16 09:10:04 +02:00
Nicolas Léveillé
01333964bd
Substitute spaces for tabs
2015-08-15 15:43:46 +02:00
Nicolas Léveillé
2346239887
Implement h_platform_stopwatch for Windows
...
We use QueryPerformanceCounter which will return realtime, not user
time.
2015-08-15 15:43:35 +02:00
Nicolas Léveillé
739f5d6d5c
Split platform specific time measurement away
...
We now have a `stopwatch` to measure time between two moments.
2015-08-15 15:43:22 +02:00
Meredith L. Patterson
a7a5e8cfad
Merge pull request #137 from uucidl/building-on-appveyor
...
Building on appveyor
2015-08-12 10:01:03 +02:00
Nicolas Léveillé
226cad2ab2
Don't build all of Hammer on AppVeyor just now
...
Since the port is not finished yet, we remove some source files
and the compilation of examples.
2015-08-09 22:46:45 +02:00
Nicolas Léveillé
c0ab06736f
Deactivate compiler warnings from CL.EXE that fire in hammer
...
Some of them are completely spurious however some (marked FIXME(windows))
may benefit from being looked at.
2015-08-09 22:46:45 +02:00
Nicolas Léveillé
0c35525e30
Convert usages of errx to h_platform_errx
...
This BSD call will have to be implemented on windows. Right now
we have a stub that just exits the process.
2015-08-09 22:46:45 +02:00
Nicolas Léveillé
c8726244ae
Wrap remaining __attribute__
...
We wrap all remaining references to __attribute__ into a macro call to
H_GCC_ATTRIBUTE, to allow compilation with MSVC CL.EXE
2015-08-09 22:46:00 +02:00
Nicolas Léveillé
6b9ba6033e
Allow windows users to include hammer.h
...
We substitute H_GCC_ATTRIBUTE to any occurence of __attribute__ and
disable its function with non gcc, non clang compilers.
We use a H_ macro so as to not pollute users' namespaces.
On windows build without c4201 so as to allow anonymous struct. This
shows hammer is not C99 compliant but rather C11.
2015-08-09 22:46:00 +02:00
Nicolas Léveillé
e7620e3e4b
windows build: Build with debug symbols
2015-08-09 22:46:00 +02:00
Nicolas Léveillé
be30820023
windows build: Add build scripts + appveyor.yml
...
In order to guarantee that Hammer can build on Windows, an appveyor.yml
and associated build scripts will build hammer and its examples. The idea
is that as soon as the appveyor.yml exists in the repository, pull
requests that would impede Windows portability would be immediately
detected.
The scripts expect CL.EXE to be in the path, and will produce their
results in build/
The highest level of warning is enabled on CL.EXE, minus warnings that
bring CL.EXE to a level that ressembles C99. The only notable warning
that was disabled is the one that tells you about implicit truncating
conversions.
Hammer's source code has quite a few implicit conversions say from a 64bit
unsigned integer to a integer of a lesser size (signed or otherwise)
2015-08-09 22:46:00 +02:00
TQ Hirsch
402721ddb7
Merge pull request #136 from abiggerhammer/master
...
Fix #133
2015-08-03 00:00:06 +02:00
Meredith L. Patterson
0fb9d77e40
remove error from HSVMContext, make svm_stack_ensure_cap return bool instead
2015-08-02 23:42:38 +02:00