• Hosting A JavaScript Engine In .NET

    Updated: 2013-09-30 06:40:19
    Articles Blog About Hosting A JavaScript Engine In NET Tuesday , September 10, 2013 10 comments Tweet ClearScript is simple to use and allows me to host either V8 or Chakra The samples on the home page show just how easy is the interop from C to JavaScript and vice versa . I use a simple wrapper because the only API I need is one to Evaluate small script expressions . public interface IJavaScriptMachine IDisposable dynamic Evaluate(string expression The following implementation sets up a default environment for script execution by loading up some required scripts , like underscore.js . The scripts are embedded resources in the current assembly . public class JavaScriptMachine JScriptEngine , IJavaScriptMachine public JavaScriptMachine( LoadDefaultScripts( void LoadDefaultScripts( var

  • Metaprogramming Fun In JavaScript

    Updated: 2013-09-30 06:40:19
    Articles Blog About Metaprogramming Fun In JavaScript Tuesday , September 3, 2013 3 comments Tweet The idea is to take a JavaScript statement like the : following c.find({ x : 1, y : 3, name : foo id : 0 limit(1 and turn the statement into a data structure that describes the methods being invoked and the arguments for each method call . There are multiple method names to capture not just find and limit but also findOne orderBy and more This sounds like a job for a mock object library , but let†s explore a few simple approaches that use One approach that doesn†t work is try to to build a function for each possible method call and forget how closures work . The following code has a bug . var CommandCapture function var commands find findOne limit orderBy for var i 0 i By the time the

  • My Top 10 Programming Languages of Interest for 2013-2014

    Updated: 2013-09-27 03:21:19
    The End of Moore’s Law For the last few years (since 2009), I’ve been pitching the idea to my peers that language speed & concurrency/parallel capabilities will become more important as CPU clock speeds plateau and manufacturers add more CPU cores instead of advancing clock rates. My 2+ year old Macbook Pro has 4 cores […]

  • Programming Language Popularity – Part Seven

    Updated: 2013-09-12 03:30:40
    I compiled some programming language popularity statistics in April 2009, October 2009, October 2010, September 2011, August 2012 and Februrary 2013. Here’s an update for September 2013: I made a number of Google searches of the forms below and summed the results: "implemented in <language>" "written in <language>" "developed in <language>" "programmed in <language>" I’ve divided the table into sections based […]

Current Feed Items | Previous Months Items

Aug 2013 | Jul 2013 | Jun 2013 | May 2013 | Apr 2013 | Mar 2013