If guile calls a C function which expects gnc_numeric but sends a
non-number, it will create a gnc_numeric_error object. This will allow
error gnc_numeric to be handled elsewhere.
Also the overflow gnc_numeric was incorrectly created.
locale-sensitive string-sorting functions -- currently mirrors guile's
(ice-9 i18n) functions -- may be modified to call C code if guile code
is not reliable.
Compiling our guile scripts will run loaded libraries. One of the libraries to
load is the engine library which expects to find the enabled backends (xml and or dbi).
If those aren't built yet, this will result in error messages printed in the build output.
subtle bug here-- used string-hash to convert guid-string to a number
which is faster to use as hash key. but string-hash does not guarantee
that there are no hash collisions. it is best to use guid string
instead which is guaranteed to uniquely define a split.
This also drops the python wrapper for gnc-module. As for the guile wrappers,
python should use other means of loading our shared libraries.
This commit required a few tweaks to the dependency chain as some units
inherited dependency information from gnc-module's public dependency
interface.
Emit appropriate deprecation warnings in case code tries to invoke the removed functions.
Only for gnc:module-load a more elaborate compat function has
been written which should allow code using this obsolete function
to continue to function. The emitted deprecation warning will
guide the user to update his/her code for future compatibility.
With that in place we no longer need to (gnc:module-load "gnucash/gnome-utils" 0)
the gnome-utils gncmodule. An ordinary (use-modules (gnucash gnome-utils)) suffices
With that in place we no longer need to (gnc:module-load "gnucash/app-utils" 0)
the app-utils gncmodule. An ordinary (use-modules (gnucash app-utils)) suffices
- move test modules into a subdirectory on Windows as well
- move the futuremod module into its own subdirectory
to avoid its load warnings each time gnc_module_init is called
That also tends to happen when building guile modules.
- remove the log handlers filtering out the futuremodsys warnings
They didn't match the actual warning signature anyway and
they're no longer emitted during testing
This is a first rudimentary separation of gnc-module tests
based on whether they require guile or not. Needs plenty of refinement
which will be applied in followup commits.
1. Instead of creating a C wrapper around gettext to then wrap in
guile, use guile's builtin gettext support directly.
The code still defines the _ and N_ shorthands. However it doesn't
really warant a separate module just for these two shorthands.
Instead define them in core-utils. So all code wanting to use
_ or N_ in guile should now use the (gnucash core-utils) module.
The bulk of this commit is actually deleting the scm-gettext
target and using (gnucash core-utils) instead of (gnucash gettext).
2. As the definition of _ and N_ is removed from app-utils.scm,
the app-utils test for a functional N_ macro has been moved to a
new test file in the guile bindinds tests.
3. The (gnucash gettext) module has been deprecated. Use
(gnucash core-utils) from now on.
This is just a cosmetic. This way the scm targets in the CMakeLists.txt
file are ordered according to their dependencies (targets later in the
file can depend on targets earlier in the file).