1 |
monsieurp 15/07/05 08:16:30 |
2 |
|
3 |
Added: freemarker-2.3.13-PyJavaInstance.patch |
4 |
Log: |
5 |
EAPI 5 bump. dev-java/jython SLOT bump from :0 to :2.7. Patch to add missing imports due to jython:2.7 move. Drop ppc. Fix bug 553900. |
6 |
|
7 |
Signed-off-by: Patrice Clement <monsieurp@g.o> |
8 |
(Portage version: 2.2.18/cvs/Linux x86_64, signed Manifest commit with key 93491BB8) |
9 |
|
10 |
Revision Changes Path |
11 |
1.1 dev-java/freemarker/files/freemarker-2.3.13-PyJavaInstance.patch |
12 |
|
13 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/freemarker/files/freemarker-2.3.13-PyJavaInstance.patch?rev=1.1&view=markup |
14 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/freemarker/files/freemarker-2.3.13-PyJavaInstance.patch?rev=1.1&content-type=text/plain |
15 |
|
16 |
Index: freemarker-2.3.13-PyJavaInstance.patch |
17 |
=================================================================== |
18 |
--- src/freemarker/ext/jython/JythonModelCache.java.orig 2015-07-05 08:47:07.035000000 +0000 |
19 |
+++ src/freemarker/ext/jython/JythonModelCache.java 2015-07-05 08:49:31.157000000 +0000 |
20 |
@@ -10,7 +10,7 @@ |
21 |
import org.python.core.PyDictionary; |
22 |
import org.python.core.PyFloat; |
23 |
import org.python.core.PyInteger; |
24 |
-import org.python.core.PyJavaInstance; |
25 |
+import org.python.core.PyJavaType; |
26 |
import org.python.core.PyLong; |
27 |
import org.python.core.PyNone; |
28 |
import org.python.core.PyObject; |
29 |
@@ -37,8 +37,8 @@ |
30 |
protected TemplateModel create(Object obj) { |
31 |
boolean asHash = false; |
32 |
boolean asSequence = false; |
33 |
- if(obj instanceof PyJavaInstance) { |
34 |
- Object jobj = ((PyJavaInstance)obj).__tojava__(java.lang.Object.class); |
35 |
+ if(obj instanceof PyJavaType) { |
36 |
+ Object jobj = PyJavaType.wrapJavaObject(obj).__tojava__(Object.class); |
37 |
// FreeMarker-aware, Jython-wrapped Java objects are left intact |
38 |
if(jobj instanceof TemplateModel) { |
39 |
return (TemplateModel)jobj; |