Search code examples
c#c#-4.0dynamicscriptingdynamic-language-runtime

Why to use the entire DLR in own Script-Engine


I've build my own script engine and im an at the point, that the code is parsed into a nice tree. Now i am facing the problem, that i need to "execute" the tree in my own runtime. That is no problem at all, but i am not sure how and which tools i should use.

I have read a lot of the DLR-Specs but i am not sure, why to use it. I think that i can handle every thing with the DynamicObject.

Why should i use things like ScriptRuntime, ScriptEngine, ScriptScope from the DLR? I have implemented my completely own parsing and executing algorithm.

Here is my current project-structure: enter image description here


Solution

  • Using the dlr for that was a good choise, because it's provide all functionality neeed. First started with writing my own stuff, but ended up with using the dlr.