nextwebgen.com

The Next Generation Web Now

JavaScript Type Inference in IDEs

Filed under: Web 2.0 News — Dion Almaer at 6:57 am on Wednesday, April 30, 2008

Tor Norbye has posted about the type inference that NetBeans has with JavaScript:

Roman Strobl has just published a screencast of the new JavaScript editor in NetBeans 6.1. The demo is around 5 minutes and highlights many of the editing features.

I’d like to dwell on the type inference part a bit. Around four minutes into the demo, Roman shows that NetBeans figures out the types of expressions, including those involving function calls. In his example, all the types happened to be Strings so it may look like a lucky coincidence. It’s not! Here’s some code fragments showing in more detail what’s going on.

He goes on to walk step by step through the completion points discussing how the IDE can get the information that it does.

It is great to see this great support for dynamic languages, as we are accustomed too on the static side.

Netbeans Type Inference

Share and Enjoy:These icons link to social bookmarking sites where readers can share and discover new web pages.
  • blogmarks
  • del.icio.us
  • De.lirio.us
  • digg
  • NewsVine
  • YahooMyWeb

No Comments »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a comment

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>