lucy-clownfish.git
8 months agoMerge branch 'go_caller_filepath' master
Marvin Humphrey [Thu, 15 Feb 2018 02:58:40 +0000 (18:58 -0800)] 
Merge branch 'go_caller_filepath'

8 months agoKludge file location from Caller().
Marvin Humphrey [Thu, 15 Feb 2018 02:57:18 +0000 (18:57 -0800)] 
Kludge file location from Caller().

The behavior of Caller() is not guaranteed, and sometimes contains
artifacts of optimization.  Work around its unpredictability by adding
another case.

8 months agoFix -Wclobbered warnings
Nick Wellnhofer [Thu, 8 Feb 2018 12:54:07 +0000 (13:54 +0100)] 
Fix -Wclobbered warnings

8 months agoRun Travis tests with PERL_USE_UNSAFE_INC=0
Nick Wellnhofer [Thu, 8 Feb 2018 12:25:51 +0000 (13:25 +0100)] 
Run Travis tests with PERL_USE_UNSAFE_INC=0

This makes sure that Test::Harness doesn't set PERL_USE_UNSAFE_INC to 1
and that the tests are actually run without . in @INC.

10 months agoDisable thread support under Perl 5.8
Nick Wellnhofer [Fri, 24 Nov 2017 13:53:11 +0000 (14:53 +0100)] 
Disable thread support under Perl 5.8

We got some mysterious CPAN Testers failures with several 5.8 releases
when calling Err_get_error from a thread. Disable thread support under
Perl 5.8, even if 5.8.9 seems to work. (Note that version 5.10.0 has
already been blacklisted.)

http://matrix.cpantesters.org/?dist=Clownfish+0.6.2
http://www.cpantesters.org/cpan/report/4c2e4fd2-cf8c-11e7-b8bd-809199b835e7
http://www.cpantesters.org/cpan/report/a93c273a-cf8c-11e7-b8bd-809199b835e7

10 months agoFix Perl build if "." is not in @INC
Nick Wellnhofer [Fri, 24 Nov 2017 13:43:28 +0000 (14:43 +0100)] 
Fix Perl build if "." is not in @INC

Perl 5.26 doesn't put "." in @INC anymore. Add "." to a localized @INC
when loading Charmony.pm and the binding .pm files.

Fixes CLOWNFISH-119.

11 months agoAdd sha512 explicit algorithm to file extension
Nick Wellnhofer [Tue, 14 Nov 2017 14:09:14 +0000 (15:09 +0100)] 
Add sha512 explicit algorithm to file extension

11 months agoFix Travis Perl versions
Nick Wellnhofer [Tue, 14 Nov 2017 13:09:06 +0000 (14:09 +0100)] 
Fix Travis Perl versions

The Perl versions available under Travis have changed and many older
releases were removed. Make perlbrew build releases that aren't
installed. Reduce the number of tested versions, but add test with
blead.

11 months agoPrepare for CV-in-stash optimization in Perl 5.28.
Nick Wellnhofer [Fri, 27 Oct 2017 13:03:40 +0000 (15:03 +0200)] 
Prepare for CV-in-stash optimization in Perl 5.28.

Perl 5.28 will start to store subroutines in stashes as coderefs.

See

    https://rt.perl.org/Public/Bug/Display.html?id=129916
    https://rt.perl.org/Public/Bug/Display.html?id=132252
    https://perl5.git.perl.org/perl.git/commitdiff/7d65f652cb

18 months agoNormalize bools before passing them to Perl
Nick Wellnhofer [Sat, 22 Apr 2017 15:54:37 +0000 (17:54 +0200)] 
Normalize bools before passing them to Perl

18 months agoDon't create callbacks for excluded methods
Nick Wellnhofer [Fri, 24 Mar 2017 13:48:46 +0000 (14:48 +0100)] 
Don't create callbacks for excluded methods

Ideally, there should be a way to only omit the callback function
definition in order to allow custom implementations.

19 months agoAllow Perl subclasses to use hashrefs
Nick Wellnhofer [Mon, 6 Mar 2017 12:26:59 +0000 (13:26 +0100)] 
Allow Perl subclasses to use hashrefs

If a parent class without ivars is subclassed from Perl, don't store
the pointer to the Clownfish object in the SV, but use a hashref as
underlying Perl object. This allows Perl subclasses to store their own
ivars directly in the hashref without having to resort to inside-out
objects.

This requires to create a host object wrapper whenever an object is
constructed or a Clownfish method is invoked. A similar approach can
be used by other host languages without class-based inheritance.

The perl_to_cfish functions now use Class_fetch and an is_a check based
on the Clownfish parent class pointer instead of calling sv_derived_from.
I haven't checked whether there's a performance impact, but this might
actually be faster than the old code.

The old inside-out approach is still supported by overloading scalar
dereferencing for host object wrappers.

19 months agoMerge branch 'cfc-parcel'
Nick Wellnhofer [Sat, 18 Mar 2017 18:08:29 +0000 (19:08 +0100)] 
Merge branch 'cfc-parcel'

19 months agoFix global destruction check again
Nick Wellnhofer [Tue, 7 Mar 2017 18:17:16 +0000 (19:17 +0100)] 
Fix global destruction check again

The best we can do is to check for PL_dirty and the refcount.

19 months agoSwitch some code over to CFCClass_in_parcel
Nick Wellnhofer [Tue, 28 Feb 2017 15:42:08 +0000 (16:42 +0100)] 
Switch some code over to CFCClass_in_parcel

19 months agoSimplify CFCBindMeth_method_def
Nick Wellnhofer [Tue, 28 Feb 2017 15:41:14 +0000 (16:41 +0100)] 
Simplify CFCBindMeth_method_def

Remove unneeded static functions.

19 months agoRemove classes array from CFCHierarchy
Nick Wellnhofer [Tue, 28 Feb 2017 14:18:21 +0000 (15:18 +0100)] 
Remove classes array from CFCHierarchy

Replaced by class array in CFCParcel.

19 months agoStop tracking parcels that are inherited from
Nick Wellnhofer [Tue, 28 Feb 2017 13:49:02 +0000 (14:49 +0100)] 
Stop tracking parcels that are inherited from

This code was unused. The original idea was to allow circular
dependencies between parcels as long as they don't inherit classes
from each other. This is an unimportant feature that had to be solved
differently, now that we specify prereqs in .cfp files.

19 months agoRework setup of parent/child relationship
Nick Wellnhofer [Tue, 28 Feb 2017 13:11:25 +0000 (14:11 +0100)] 
Rework setup of parent/child relationship

Set up parent/child relationship of classes in CFCParcel. Connect and
sort classes in a single function.

Make sure that prereq parcels are registered first.

19 months agoRemove global class registry
Nick Wellnhofer [Mon, 27 Feb 2017 23:45:46 +0000 (00:45 +0100)] 
Remove global class registry

Replaced by the class array in CFCParcel.

19 months agoRework URI resolution
Nick Wellnhofer [Mon, 27 Feb 2017 22:46:41 +0000 (23:46 +0100)] 
Rework URI resolution

Add CFCMethod_get_docucomment to get inherited CFCDocuComment.

Use correct base class when resolving URIs. Only search parcel and
prereqs for full struct symbols. Also search prereqs for short struct
symbols. Search all source parcels and their prereqs for standalone .md
documents.

Minor cleanups.

19 months agoStore CFCClass pointer in CFCMethod
Nick Wellnhofer [Wed, 1 Mar 2017 13:52:23 +0000 (14:52 +0100)] 
Store CFCClass pointer in CFCMethod

Store a weak pointer to the class containing the method.

19 months agoStore CFCClass pointer in parser state
Nick Wellnhofer [Wed, 1 Mar 2017 13:01:40 +0000 (14:01 +0100)] 
Store CFCClass pointer in parser state

Store a CFCClass pointer instead of the class name.

19 months agoAdd CFCType_get_class
Nick Wellnhofer [Mon, 27 Feb 2017 18:45:52 +0000 (19:45 +0100)] 
Add CFCType_get_class

Store a weak pointer to CFCClass in CFCType for object types.

19 months agoAdd CFCParcel_class functions
Nick Wellnhofer [Mon, 27 Feb 2017 17:53:58 +0000 (18:53 +0100)] 
Add CFCParcel_class functions

Search classes in a parcel by name or struct symbol.

In most cases, it's important to only search classes in a parcel or
its direct prerequisites. Otherwise, classes from random other parcels
could be picked up.

19 months agoRemove CFCHierarchy_ordered_classes
Nick Wellnhofer [Mon, 27 Feb 2017 00:23:14 +0000 (01:23 +0100)] 
Remove CFCHierarchy_ordered_classes

19 months agoStart to use CFCParcel_get_classes
Nick Wellnhofer [Sun, 26 Feb 2017 23:58:43 +0000 (00:58 +0100)] 
Start to use CFCParcel_get_classes

Replace CFCHierarchy_ordered_classes with CFCParcel_get_classes.

19 months agoSort class arrays of parcels
Nick Wellnhofer [Sun, 26 Feb 2017 22:11:47 +0000 (23:11 +0100)] 
Sort class arrays of parcels

Some of the code generators require that parent classes are processed
before subclasses. Sort the class array accordingly when building the
hierarchy.

Also sort subclasses by class name to guarantee a consistent order.
This should make the CFC output completely deterministic. (Except for
output that depends on the order of parcels in the global parcel
registry. I think the only example is the Perl typemap.)

19 months agoStore class array in parcel
Nick Wellnhofer [Sun, 26 Feb 2017 20:32:58 +0000 (21:32 +0100)] 
Store class array in parcel

Store an array of all classes that belong to a parcel in CFCParcel.

19 months agoAdd CFCClass_in_parcel and CFCClass_in_same_parcel
Nick Wellnhofer [Tue, 28 Feb 2017 15:25:15 +0000 (16:25 +0100)] 
Add CFCClass_in_parcel and CFCClass_in_same_parcel

Simple but useful helper functions.

19 months agoUse WeakPtr in CFCType
Nick Wellnhofer [Mon, 27 Feb 2017 15:58:47 +0000 (16:58 +0100)] 
Use WeakPtr in CFCType

Weaken the parcel pointer, allowing to store a class array in CFCParcel
later.

19 months agoUse WeakPtr in CFCClass
Nick Wellnhofer [Mon, 27 Feb 2017 15:05:54 +0000 (16:05 +0100)] 
Use WeakPtr in CFCClass

Weaken the parcel pointer. This allows to store a class array in
CFCParcel later.

Also weaken the parent pointer, so that the circular reference doesn't
have to be broken manually.

19 months agoImplement CFCWeakPtr
Nick Wellnhofer [Mon, 27 Feb 2017 12:01:16 +0000 (13:01 +0100)] 
Implement CFCWeakPtr

We mostly avoided circular references in CFC so far, although it's
often useful to have pointers to a parent or ancestor in the tree
structures CFC operates on. Weak pointers allow to break circular
references when destroying objects.

Even after the upcoming changes, CFC won't reference objects through
weak pointers after the strong refcount dropped to zero. So we could
just use normal pointers and simply don't incref/decref them. The
WeakPtr mechanism serves mainly as annotation and safety net, making
sure that weak pointers are used as intended.

19 months agoFix memory leak
Nick Wellnhofer [Wed, 1 Mar 2017 16:30:30 +0000 (17:30 +0100)] 
Fix memory leak

19 months agoAdd explanation regarding SUPER::method invocations
Nick Wellnhofer [Sat, 25 Feb 2017 16:22:57 +0000 (17:22 +0100)] 
Add explanation regarding SUPER::method invocations

This will hopefully remind me why we have to use static dispatch in
XSUBs.

19 months agoFix global destruction check
Nick Wellnhofer [Thu, 23 Feb 2017 22:18:33 +0000 (23:18 +0100)] 
Fix global destruction check

PL_dirty is already set during the first phase of global destruction
when it's still safe and even expected to destroy objects. Change the
test to check the refcount.

This fixes destruction of "our" variables like in Lucy's
t/308-simple.t.

19 months agoFix potential memory corruption during Perl global destruction
Nick Wellnhofer [Thu, 23 Feb 2017 15:15:14 +0000 (16:15 +0100)] 
Fix potential memory corruption during Perl global destruction

During global destruction, DESTROY is called in random order on objects
remaining because of refcount leaks or circular references. This can
cause memory corruption with Clownfish objects, so better leak instead
of corrupting memory.

Fixes CLOWNFISH-117.

19 months agoMake DESTROY a no-op for Booleans
Nick Wellnhofer [Thu, 23 Feb 2017 14:02:07 +0000 (15:02 +0100)] 
Make DESTROY a no-op for Booleans

19 months agoFix refcounts for Perl global error objects
Nick Wellnhofer [Thu, 23 Feb 2017 14:00:54 +0000 (15:00 +0100)] 
Fix refcounts for Perl global error objects

Err_set_error takes a decremented argument. Err_get_error returns a
non-incremented object.

20 months agoFix stack string documentation
Nick Wellnhofer [Fri, 17 Feb 2017 12:19:54 +0000 (13:19 +0100)] 
Fix stack string documentation

I forgot that we removed special handling of stack strings in DECREF.

20 months agoOnly write documentation for installed parcels
Nick Wellnhofer [Mon, 13 Feb 2017 15:12:19 +0000 (16:12 +0100)] 
Only write documentation for installed parcels

20 months agoFix URI resolution for methods inherited from other parcels
Nick Wellnhofer [Mon, 13 Feb 2017 15:05:28 +0000 (16:05 +0100)] 
Fix URI resolution for methods inherited from other parcels

20 months agoDon't build fat Perl binaries on macOS
Nick Wellnhofer [Thu, 16 Feb 2017 17:49:48 +0000 (18:49 +0100)] 
Don't build fat Perl binaries on macOS

Stock Perl on macOS builds fat binaries. Charmonizer has always
used the wrong sizes for some types on non-native platforms, but
recent changes broke the detection copmletely.

20 months agoAdd "install" target to C Makefile
Nick Wellnhofer [Wed, 8 Feb 2017 17:39:06 +0000 (18:39 +0100)] 
Add "install" target to C Makefile

Fixes CLOWNFISH-116.

20 months agoAdd support for C11 stdatomic.h
Nick Wellnhofer [Wed, 8 Feb 2017 14:42:30 +0000 (15:42 +0100)] 
Add support for C11 stdatomic.h

20 months agoUse chaz_OS_exe_ext() for executables on the host OS
Nick Wellnhofer [Sat, 4 Feb 2017 15:12:18 +0000 (16:12 +0100)] 
Use chaz_OS_exe_ext() for executables on the host OS

20 months agoTest ARM cross compilation under Travis
Nick Wellnhofer [Fri, 3 Feb 2017 23:46:27 +0000 (00:46 +0100)] 
Test ARM cross compilation under Travis

20 months agoUpdate charmonizer code
Nick Wellnhofer [Fri, 3 Feb 2017 22:36:14 +0000 (23:36 +0100)] 
Update charmonizer code

- CC is now set automatically.
- Simplify runtime valgrind target.
- Remove unused variables.

20 months agoUpdate build instructions
Nick Wellnhofer [Fri, 3 Feb 2017 21:33:09 +0000 (22:33 +0100)] 
Update build instructions

20 months agoAdd cross-compilation support to configure script
Nick Wellnhofer [Fri, 3 Feb 2017 21:22:11 +0000 (22:22 +0100)] 
Add cross-compilation support to configure script

If the environment variable TARGET_CC is set, configure uses the value
as target compiler for cross-compiling. For example:

    TARGET_CC=x86_64-w64-mingw32-gcc ./configure

20 months agoAdd --charmonic option to cfc
Nick Wellnhofer [Fri, 3 Feb 2017 21:15:05 +0000 (22:15 +0100)] 
Add --charmonic option to cfc

With --charmonic, cfc makes cfish_platform.h include charmony.h and
use its CHY_* macros for platform-specific settings. This is needed
when cross-compiling.

Otherwise, the CHY_* values from the CFC configuration are used.
This breaks cross compilation but allows to build Clownfish projects
without Charmonizer.

Run cfc with --charmonic when building the runtime.

20 months agoAdjust Charmonizer code for API changes and regenerate
Nick Wellnhofer [Fri, 3 Feb 2017 18:56:23 +0000 (19:56 +0100)] 
Adjust Charmonizer code for API changes and regenerate

20 months agoRemove CFISH endian macros
Nick Wellnhofer [Fri, 3 Feb 2017 13:55:02 +0000 (14:55 +0100)] 
Remove CFISH endian macros

Lucy's NumberUtils.cfh doesn't need them anymore.

20 months agoRemove U64_TO_DOUBLE macro
Nick Wellnhofer [Fri, 3 Feb 2017 12:28:36 +0000 (13:28 +0100)] 
Remove U64_TO_DOUBLE macro

It was only needed for MSVC6.

20 months agoRemove unused CFISH_SIZEOF_* macros
Nick Wellnhofer [Fri, 3 Feb 2017 12:19:35 +0000 (13:19 +0100)] 
Remove unused CFISH_SIZEOF_* macros

These macros were only needed by the old Perl labeled params
code.

20 months agoMove downcast and certify from Err to Obj
Nick Wellnhofer [Thu, 2 Feb 2017 14:36:40 +0000 (15:36 +0100)] 
Move downcast and certify from Err to Obj

The API break shouldn't be a problem. These functions are always
invoked via the respective macros.

20 months agoMake more functions public and document useful macros
Nick Wellnhofer [Thu, 2 Feb 2017 14:10:57 +0000 (15:10 +0100)] 
Make more functions public and document useful macros

Fixes CLOWNFISH-114.

22 months agoFix svnmucc command in release_commands.pl
Nick Wellnhofer [Tue, 13 Dec 2016 15:18:51 +0000 (16:18 +0100)] 
Fix svnmucc command in release_commands.pl

See LUCY-308.

22 months agoOnly print Makefile contents under automated testing
Nick Wellnhofer [Wed, 30 Nov 2016 19:34:33 +0000 (20:34 +0100)] 
Only print Makefile contents under automated testing

22 months agoPass $Config{cc} to charmonizer verbatim
Nick Wellnhofer [Tue, 29 Nov 2016 10:34:08 +0000 (11:34 +0100)] 
Pass $Config{cc} to charmonizer verbatim

Don't split $Config{cc} into compiler command and arguments when
passing them to charmonizer. Pass the unmodified string as `--cc`
option even if it contains spaces. This makes compiler values like
`ccache cc` work.

Fixes CLOWNFISH-111.

22 months agoDon't regenerate POD when building CPAN distro
Nick Wellnhofer [Tue, 29 Nov 2016 10:08:18 +0000 (11:08 +0100)] 
Don't regenerate POD when building CPAN distro

Overwriting read-only .pod files can result in errors. Simply skip
`write_pod` when building the CPAN distribution.

Fixes LUCY-316.

22 months agoAdd comma after labeled params in sample code
Nick Wellnhofer [Wed, 23 Nov 2016 15:29:15 +0000 (16:29 +0100)] 
Add comma after labeled params in sample code

2 years agoMake Err_win_error return English messages
Nick Wellnhofer [Sat, 8 Oct 2016 14:44:57 +0000 (16:44 +0200)] 
Make Err_win_error return English messages

English messages are hopefully strictly ASCII. Passing 0 as language id
may return a non-English message using the current code page and
resulting in invalid UTF-8.

See LUCY-311.

2 years agoTry to improve CPAN Testers diagnostics
Nick Wellnhofer [Sat, 8 Oct 2016 11:33:36 +0000 (13:33 +0200)] 
Try to improve CPAN Testers diagnostics

Check whether 'use Clownfish::Test' succeeds directly after build.
If this fails, it is probably caused by a failure to find symbols from
Clownfish.so, indicating a build problem. In this case, make the build
fail, so we get the full build log on CPAN Testers.

2 years agoDon't index Clownfish::Test in PAUSE
Nick Wellnhofer [Tue, 4 Oct 2016 13:46:10 +0000 (15:46 +0200)] 
Don't index Clownfish::Test in PAUSE

Since 0.40_11, setting the Module::Build property `no_index` directly
suppresses the `provides` section in `META.json`. This seems to be the
most reliable way to stop PAUSE from indexing packages.

2 years agoSupport X.Y.Z.D Perl versions
Nick Wellnhofer [Tue, 4 Oct 2016 12:03:30 +0000 (14:03 +0200)] 
Support X.Y.Z.D Perl versions

2 years agoDisable thread support under Perl 5.10.0
Nick Wellnhofer [Tue, 4 Oct 2016 11:40:59 +0000 (13:40 +0200)] 
Disable thread support under Perl 5.10.0

At least under modern Linux, thread support of Perl 5.10.0 seems
completely broken. Even the thread tests of Perl itself segfault.

Fixes CLOWNFISH-107.

2 years agoChange tag names in release_commands.pl
Nick Wellnhofer [Mon, 3 Oct 2016 13:01:40 +0000 (15:01 +0200)] 
Change tag names in release_commands.pl

2 years agoRegenerate charmonizer.c for pattern rules fix
Nick Wellnhofer [Thu, 29 Sep 2016 14:14:36 +0000 (16:14 +0200)] 
Regenerate charmonizer.c for pattern rules fix

Fixes CLOWNFISH-104.

2 years agoExclude Clownfish/Test.xs from CPAN tarball
Nick Wellnhofer [Thu, 29 Sep 2016 12:52:47 +0000 (14:52 +0200)] 
Exclude Clownfish/Test.xs from CPAN tarball

Fixes CLOWNFISH-105.

2 years agoShow type of error in CFCUtil_current
Nick Wellnhofer [Thu, 29 Sep 2016 12:07:21 +0000 (14:07 +0200)] 
Show type of error in CFCUtil_current

This might help to debug mysterious CPAN Testers failures like

http://www.cpantesters.org/cpan/report/19fc2484-8583-11e6-aa8e-960c2aa93d25

2 years agoBump Module::Build dependency to 0.3604
Nick Wellnhofer [Thu, 29 Sep 2016 11:58:21 +0000 (13:58 +0200)] 
Bump Module::Build dependency to 0.3604

Setting c_source to an arrayref with multiple directories isn't
supported in previous versions.

Fixes CLOWNFISH-106.

2 years agoUpdate release date for 0.6.0 release rel/v0.6.0
Nick Wellnhofer [Sat, 24 Sep 2016 13:07:09 +0000 (15:07 +0200)] 
Update release date for 0.6.0 release

2 years agoUpdate version number for release 0.6.0
Nick Wellnhofer [Sat, 24 Sep 2016 12:55:49 +0000 (14:55 +0200)] 
Update version number for release 0.6.0

2 years agoUpdate update_version script
Nick Wellnhofer [Sat, 24 Sep 2016 12:52:04 +0000 (14:52 +0200)] 
Update update_version script

2 years agoAdd CHANGES entry for 0.6.0.
Marvin Humphrey [Thu, 15 Sep 2016 00:27:08 +0000 (17:27 -0700)] 
Add CHANGES entry for 0.6.0.

2 years agoDupe CHANGES from 0.5.x.
Marvin Humphrey [Thu, 15 Sep 2016 00:26:16 +0000 (17:26 -0700)] 
Dupe CHANGES from 0.5.x.

2 years agoAdd t/cfinc to CPAN distribution
Nick Wellnhofer [Wed, 7 Sep 2016 17:32:45 +0000 (19:32 +0200)] 
Add t/cfinc to CPAN distribution

2 years agoFix croak_sv usage
Nick Wellnhofer [Wed, 7 Sep 2016 16:01:09 +0000 (18:01 +0200)] 
Fix croak_sv usage

croak_sv is only available since Perl 5.14.

Also switch to FREEMEM to avoid crash under ActivePerl.

2 years agoUpdate rat-excludes
Nick Wellnhofer [Wed, 7 Sep 2016 15:57:06 +0000 (17:57 +0200)] 
Update rat-excludes

2 years agoRegenerate charmonizer.c to fix memory leak
Nick Wellnhofer [Wed, 7 Sep 2016 14:49:15 +0000 (16:49 +0200)] 
Regenerate charmonizer.c to fix memory leak

2 years agoUpdate valgrind suppressions
Nick Wellnhofer [Wed, 7 Sep 2016 14:49:01 +0000 (16:49 +0200)] 
Update valgrind suppressions

2 years agoFix memory leak in runtime tests
Nick Wellnhofer [Wed, 7 Sep 2016 14:48:36 +0000 (16:48 +0200)] 
Fix memory leak in runtime tests

2 years agoFix memory leak in CFC
Nick Wellnhofer [Wed, 7 Sep 2016 14:43:12 +0000 (16:43 +0200)] 
Fix memory leak in CFC

2 years agoFix memory leaks in CFC tests
Nick Wellnhofer [Wed, 7 Sep 2016 14:37:10 +0000 (16:37 +0200)] 
Fix memory leaks in CFC tests

2 years agoFix tests requiring TestUtils
Nick Wellnhofer [Wed, 7 Sep 2016 14:34:25 +0000 (16:34 +0200)] 
Fix tests requiring TestUtils

`buildlib` must be added to @INC.

2 years agoFix Clownfish::Test::run_tests
Nick Wellnhofer [Wed, 7 Sep 2016 13:57:49 +0000 (15:57 +0200)] 
Fix Clownfish::Test::run_tests

Fix a stupid bug that always ran the same test.

2 years agoAdd Python bindings to CI tests
Nick Wellnhofer [Fri, 26 Aug 2016 17:03:40 +0000 (19:03 +0200)] 
Add Python bindings to CI tests

The Travis tests are still disabled. Compiling _clownfish.c fails
because the GCC version doesn't default to C99.

2 years agoExit with error code if Python tests fail
Nick Wellnhofer [Fri, 26 Aug 2016 17:02:38 +0000 (19:02 +0200)] 
Exit with error code if Python tests fail

2 years agoImplement copy-on-incref for Python bindings
Nick Wellnhofer [Fri, 26 Aug 2016 16:29:17 +0000 (18:29 +0200)] 
Implement copy-on-incref for Python bindings

2 years agoFix Python build under MSVC
Nick Wellnhofer [Fri, 26 Aug 2016 16:07:52 +0000 (18:07 +0200)] 
Fix Python build under MSVC

2 years agoFix Python bindings
Nick Wellnhofer [Fri, 26 Aug 2016 11:58:53 +0000 (13:58 +0200)] 
Fix Python bindings

2 years agoFix nullary function declarations
Nick Wellnhofer [Fri, 26 Aug 2016 11:55:24 +0000 (13:55 +0200)] 
Fix nullary function declarations

2 years agoAdd option to use system cmark
Nick Wellnhofer [Sat, 6 Aug 2016 17:58:24 +0000 (19:58 +0200)] 
Add option to use system cmark

For the Perl build:

    perl Build.PL --with_system_cmark=1

For the C build:

    ./configure --with-system-cmark

Fixes CLOWNFISH-87.

2 years agoRun thread tests under Travis Perl
Nick Wellnhofer [Sat, 6 Aug 2016 15:32:16 +0000 (17:32 +0200)] 
Run thread tests under Travis Perl

The "5.x-extras" Perl versions are built with -Duseithreads:

    https://blog.travis-ci.com/2014-09-03-minor-language-update

2 years agoRename libcfish to libclownfish
Nick Wellnhofer [Sat, 6 Aug 2016 15:23:24 +0000 (17:23 +0200)] 
Rename libcfish to libclownfish

Fixes CLOWNFISH-103.

2 years agoDisable threads under Perl < 5.8.7
Nick Wellnhofer [Sat, 6 Aug 2016 14:58:36 +0000 (16:58 +0200)] 
Disable threads under Perl < 5.8.7

Thread safety requires the CLONE_SKIP method introduced in Perl 5.8.7.

Fixes CLOWNFISH-92.

2 years agoMerge branch 'string-helpers'
Nick Wellnhofer [Sat, 6 Aug 2016 14:27:44 +0000 (16:27 +0200)] 
Merge branch 'string-helpers'

Fixes CLOWNFISH-76.

2 years agoMove StringHelper from Clownfish to Lucy
Nick Wellnhofer [Tue, 2 Aug 2016 17:33:32 +0000 (19:33 +0200)] 
Move StringHelper from Clownfish to Lucy

2 years agoMove some functions from StrHelp to Str
Nick Wellnhofer [Tue, 2 Aug 2016 16:46:35 +0000 (18:46 +0200)] 
Move some functions from StrHelp to Str

- utf8_valid
- validate_utf8
- is_whitespace
- encode_utf8_char