diff options
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared/CodeTools/LSL2CSCodeTransformer.cs')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/CodeTools/LSL2CSCodeTransformer.cs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/CodeTools/LSL2CSCodeTransformer.cs b/OpenSim/Region/ScriptEngine/Shared/CodeTools/LSL2CSCodeTransformer.cs index e77b3d2..0fb3574 100644 --- a/OpenSim/Region/ScriptEngine/Shared/CodeTools/LSL2CSCodeTransformer.cs +++ b/OpenSim/Region/ScriptEngine/Shared/CodeTools/LSL2CSCodeTransformer.cs | |||
@@ -27,12 +27,16 @@ | |||
27 | 27 | ||
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Reflection; | ||
31 | using log4net; | ||
30 | using Tools; | 32 | using Tools; |
31 | 33 | ||
32 | namespace OpenSim.Region.ScriptEngine.Shared.CodeTools | 34 | namespace OpenSim.Region.ScriptEngine.Shared.CodeTools |
33 | { | 35 | { |
34 | public class LSL2CSCodeTransformer | 36 | public class LSL2CSCodeTransformer |
35 | { | 37 | { |
38 | // private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | ||
39 | |||
36 | private SYMBOL m_astRoot = null; | 40 | private SYMBOL m_astRoot = null; |
37 | private static Dictionary<string, string> m_datatypeLSL2OpenSim = null; | 41 | private static Dictionary<string, string> m_datatypeLSL2OpenSim = null; |
38 | 42 | ||
@@ -78,6 +82,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools | |||
78 | /// <param name="s">The current node to transform.</param> | 82 | /// <param name="s">The current node to transform.</param> |
79 | private void TransformNode(SYMBOL s) | 83 | private void TransformNode(SYMBOL s) |
80 | { | 84 | { |
85 | // m_log.DebugFormat("[LSL2CSCODETRANSFORMER]: Tranforming node {0}", s); | ||
86 | |||
81 | // make sure to put type lower in the inheritance hierarchy first | 87 | // make sure to put type lower in the inheritance hierarchy first |
82 | // ie: since IdentConstant and StringConstant inherit from Constant, | 88 | // ie: since IdentConstant and StringConstant inherit from Constant, |
83 | // put IdentConstant and StringConstant before Constant | 89 | // put IdentConstant and StringConstant before Constant |
@@ -103,10 +109,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools | |||
103 | // We need to check for that here. | 109 | // We need to check for that here. |
104 | if (null != s.kids[i]) | 110 | if (null != s.kids[i]) |
105 | { | 111 | { |
112 | // m_log.Debug("[LSL2CSCODETRANSFORMER]: Moving down level"); | ||
113 | |||
106 | if (!(s is Assignment || s is ArgumentDeclarationList) && s.kids[i] is Declaration) | 114 | if (!(s is Assignment || s is ArgumentDeclarationList) && s.kids[i] is Declaration) |
107 | AddImplicitInitialization(s, i); | 115 | AddImplicitInitialization(s, i); |
108 | 116 | ||
109 | TransformNode((SYMBOL) s.kids[i]); | 117 | TransformNode((SYMBOL) s.kids[i]); |
118 | |||
119 | // m_log.Debug("[LSL2CSCODETRANSFORMER]: Moving up level"); | ||
110 | } | 120 | } |
111 | } | 121 | } |
112 | } | 122 | } |