[Bf-extensions-cvs] SVN commit: /data/svn/bf-extensions [2411] branches/geodesic_domes/T1.py: Why does this work in Python 2.6 and not in Python 3.2

Peter K.H. Gragert pkhgragert at gmail.com
Mon Oct 10 07:26:52 CEST 2011


Revision: 2411
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-extensions&revision=2411
Author:   pkhg
Date:     2011-10-10 05:26:52 +0000 (Mon, 10 Oct 2011)
Log Message:
-----------
Why does this work in Python 2.6 and not in Python 3.2
The problem arises in vefm259 for
vertex / number 
this is the reason of this test

Added Paths:
-----------
    branches/geodesic_domes/T1.py

Added: branches/geodesic_domes/T1.py
===================================================================
--- branches/geodesic_domes/T1.py	                        (rev 0)
+++ branches/geodesic_domes/T1.py	2011-10-10 05:26:52 UTC (rev 2411)
@@ -0,0 +1,13 @@
+class T1:
+	def __init__(self,x,y):
+		self.value = [x,y]
+	def __mul__(self,other):
+		tmp = [el * other for el in self.value]
+		return tmp
+	def __div__(self,other):
+		tmp = [el / other for el in self.value]
+		return tmp
+
+l1 = T1(4,5)
+print (l1 * 3)
+print (l1 / 3)



More information about the Bf-extensions-cvs mailing list