GitHub user rectang opened a pull request:
https://github.com/apache/lucy-clownfish/pull/20
CLOWNFISH-47 Fix final methods
Final methods should be implemented using static inline functions rather
than macros, improving type safety. Final methods are also being optimized too
eagerly, though limited use of final classes and methods in earlier releases
means that this compilation bug has not manifested in live code to my knowledge.
This branch also re-enables the Go build in Travis.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/rectang/lucy-clownfish
CLOWNFISH-47-fix-final-methods
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/lucy-clownfish/pull/20.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #20
----
commit 5bb75c9dd63aab1d772bd2b7c68d2e25253fc42c
Author: Marvin Humphrey <[email protected]>
Date: 2015-05-20T22:35:14Z
Stop forcing invocant to "self" in codegen.
Use the original invocant name in generated method invocation function
and method typedef.
commit f1e69a0fcbf62008bfd2ce8e0235243d6b138e58
Author: Marvin Humphrey <[email protected]>
Date: 2015-05-20T23:23:37Z
Use static inline funcs for final methods.
Instead of a macro which aliases to a specific implementing function,
wrap a call to the implementing function in a static inline function.
This encapsulates casting of the invocant, improving type safety. It is
also more compatible with CGO, which did not understand the macros.
commit 596d282770eb92281190ff7a9158a478ef8cf55a
Author: Marvin Humphrey <[email protected]>
Date: 2015-05-20T23:40:56Z
Don't over-optimize final methods.
It is only valid to resolve a final method to a specific implementing
function when that function resides in the same parcel as the invocant.
A ancestor class in another parcel has the option of adding or removing
an implementation, so the descendant class cannot know for sure what
function it should resolve to.
commit 0daeb0d7893eec2b7763a53289a2c876ac65a427
Author: Marvin Humphrey <[email protected]>
Date: 2015-05-21T00:01:15Z
Fix invalid NULL argument.
commit 54373b61aad37c16ffdd124f244ad03e6a8a01cb
Author: Marvin Humphrey <[email protected]>
Date: 2015-05-21T00:02:43Z
Re-enable Go Travis build.
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---