Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
Since MinGW 4.5 does not define these functions if __STRICT_ANSI__ is defined
(in case of _wfopen it defines it inconsistently between stdio.h and wchar.h)
use the baseline functions for MinGW 4.5 and earlier.
Fixes #23.
|
|
|
|
Since copying no longer relies on child insertion we have to also reserve
space in the hash table for the allocator so that pointer manipulations are
guaranteed to succeed.
|
|
|
|
node_copy_string relied on the fact that target node had an empty name and
value. Normally this is a safe assumption (and a good one to make since it
makes copying faster), however it was not checked and there was one case when
it did not hold.
Since we're reusing the logic for inserting nodes, newly inserted declaration
nodes had the name set automatically to xml, which in our case violates the
assumption and is counter-productive since we'll override the name right after
setting it.
For now the best solution is to do the same insertion manually - that results
in some code duplication that we can refactor later (same logic is partially
shared by _move variants anyway so on a level duplicating is not that bad).
|
|
Add allow_insert_attribute (similar to allow_insert_child).
|
|
Remove redundant this-> from type() call (argument used to be called type,
but it's now type_).
Use _root member directly when possible instead of calling internal_object.
|
|
This will allow us to implement nodeset_eval_last evaluation mode if necessary
without relying on a fragile boolean argument.
|
|
Extract end of string to rend and add comments to translate_table.
|
|
Right now remove_node is only used in contexts where parent is reset after
removing but this might be important in the future.
|
|
Since depth is unsigned this is actually well-defined but it's better to not
have the underflow anyway.
|
|
|
|
This is more for consistency with the surrounding code than for performance.
|
|
Some compilers don't handle NaNs properly.
Some compilers don't implement fmod in a IEEE-compatible way.
Some compilers have exception handling codegen bugs (DMC...).
|
|
Also fix documentation jam rules for Windows.
|
|
|
|
Release date is (tentatively) 11/27.
|
|
|
|
This should completely eliminate the confusion between load and load_file.
Of course, for compatibility reasons we have to preserve the old variant -
it will be deprecated in a future version and subsequently removed.
|
|
The behavior on OSX is different - we don't get a I/O error so the test is
useless.
|
|
|
|
Since we no longer have a name/value pair in nodes we need one less bit to
represent allocated flags. This reduces the page overhead by 32 bytes.
|
|
|
|
Previously push_back implementation was too big to inline; now the common case
(no realloc) is small and realloc variant is explicitly marked as no-inline.
This is similar to xml_allocator::allocate_memory/allocate_memory_oob and
makes some XPath queries 5% faster.
|
|
In some cases constant overhead on step evaluation is important - i.e. for
queries that evaluate a simple step in a predicate expression. Eliminating
a redundant function call thus can prove worthwhile.
This change makes some queries (e.g. //*[not(*)]) 4% faster.
|
|
This reverts commit 98713bcba94b33b1b45a8891ac2e9e11305c7553.
Travis multi-OS feature is invite-only for now...
|
|
Hopefully OSX defaults to clang so we get as much coverage as before...
|
|
Clang and gcc seem to treat string literals differently...
|
|
Memory allocation behavior is different in compact mode so tests that rely
on current behavior have to be adjusted.
|
|
|
|
Since page size can be customized let's do a special validation check for
compact encoding. Right now it's redundant since page size is limited by
64k in alloc_string, but that may change in the future.
|
|
This allows us to add pi value to restore target support for PI nodes without
increasing the memory usage for other nodes.
Right now the PI node has a separate header that's used for allocated bit;
this allows us to reduce header bitcount in the future.
|
|
Previously setting a large page size (i.e. 1M) would cause dynamic string
allocation to assert spuriously. A page size of 64K guarantees that all
offsets fit into 16 bits.
|
|
Computed offsets for documents with nodes that were added using append_buffer
or newly appended nodes without name/value information were invalid.
|
|
This reduces the number of unsafe pointer manipulations.
|
|
These used to result in better codegen for unknown reasons, but this is no
longer the case.
|
|
|
|
|
|
Split number/boolean filtering logic into two functions. This creates an
extra copy of a remove_if-like algorithm, but moves the type check out of
the loop and results in better organized filtering code.
Consolidate test-based dispatch into apply_predicate (which is now a member
function).
|
|
|
|
Calling memcpy(x, 0, 0) is technically undefined (although it should usually
be a no-op).
|
|
|
|
Calling memcpy(x, 0, 0) is technically undefined (although it should usually
be a no-op).
Fixes #20.
|
|
Not sure why xargs -r is not the default...
|
|
|
|
|
|
|