Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > STRONG dynamic typing favors tools..?

Reply
Thread Tools

STRONG dynamic typing favors tools..?

 
 
John Papas
Guest
Posts: n/a
 
      01-07-2008
One of the things I like about languages like Java is that since it is
statically typed I get tools that assist me when I write code, for
example if I misspell a function name.

What I really hate about dynamic languages is that, for example in
JavaScript if I misspell something there is no tool to find it and no
(deterministic) test locate this bug. I could actually deploy and find
the mispelled name only when I get its use case.

Does the fact that Ruby is STRONG dynaically typed, assist tool
developers? Can I have tools with minimal analysis capabilities?

 
Reply With Quote
 
 
 
 
Jari Williamsson
Guest
Posts: n/a
 
      01-07-2008
John Papas wrote:
> One of the things I like about languages like Java is that since it is
> statically typed I get tools that assist me when I write code, for
> example if I misspell a function name.
>
> What I really hate about dynamic languages is that, for example in
> JavaScript if I misspell something there is no tool to find it and no
> (deterministic) test locate this bug. I could actually deploy and find
> the mispelled name only when I get its use case.
>
> Does the fact that Ruby is STRONG dynaically typed, assist tool
> developers? Can I have tools with minimal analysis capabilities?


NetBeans warns you about many of the "usual" cases of misspelling and
coding errors in Ruby. (Be aware that all types of checks are not
enabled out of the box. Look at the tutorials to get a feeling of what's
available.) There seems to be other editors around with intelligent code
parsing as well.


Best regards,

Jari Williamsson

 
Reply With Quote
 
 
 
 
Huw Collingbourne
Guest
Posts: n/a
 
      01-07-2008
Ruby In Steel Developer analyzes code as it is written to provide
correct code completion (IntelliSense). You can also add optional 'type
assertions' in comment blocks to provide extra typing information for
parameter completion. More info here:

http://www.sapphiresteel.com/Ruby-In...loper-Overview

best wishes
Huw

SapphireSteel Software
Ruby and Rails In Visual Studio
http://www.sapphiresteel.com
--
Posted via http://www.ruby-forum.com/.

 
Reply With Quote
 
ara howard
Guest
Posts: n/a
 
      01-07-2008

On Jan 7, 2008, at 10:03 AM, Shot (Piotr Szotkowski) wrote:

>> What I really hate about dynamic languages is that, for example in
>> JavaScript if I misspell something there is no tool to find it and
>> no (deterministic) test locate this bug.


it's a bit tangental, but you really shouldn't be spelling anything if
you are comfortable with your editor - at least not more than once.
for instance, in vim, after i say something like

foobar = 42

i would just type

fo <ctrl-N> and the foobar var is auto completed in much the same
way as the shell auto completes.

it's extremely rare that i would actually spell out any var longer
than two chars. using this technique i find that i rarely, perhaps
once per month, make a spelling error that causes me an issue.

regards.

 
Reply With Quote
 
M. Edward (Ed) Borasky
Guest
Posts: n/a
 
      01-08-2008
Shot (Piotr Szotkowski) wrote:
> John Papas:
>
>> What I really hate about dynamic languages is that, for example in
>> JavaScript if I misspell something there is no tool to find it and
>> no (deterministic) test locate this bug.

>
> The idea behind unit testing is that they catch such things for you.
> Better yet, Test- (or Behaviour-) Driven Development means your code
> does what it’s asked to do, so it doesn’t really matter if there are
> any misspellings inside or not.


Ah, but then there's "heckle". Heckle inserts random bugs in your code,
and if your tests don't catch them, then the tests aren't sufficient.


 
Reply With Quote
 
Jrg W Mittag
Guest
Posts: n/a
 
      01-08-2008
John Papas wrote:
> One of the things I like about languages like Java is that since it is
> statically typed I get tools that assist me when I write code, for
> example if I misspell a function name.


This doesn't actually have anything to do with Java being statically
typed.

> What I really hate about dynamic languages is that, for example in
> JavaScript if I misspell something there is no tool to find it [...]


Again, this doesn't actually have anything to do with the dynamic
nature of those languages.

In fact, pretty much all of the features that are now associated with
IDEs for static languages, were invented in Smalltalk IDEs: code
completion, class browsers, automated refactoring tools, automated
unit testing.

The *only* reason for the differences between IDEs for static and
dynamic languages is money: the Eclipse Java Development Tools are
developed by dozens of highly paid full-time engineers with million
dollar research budgets by IBM, Oracle, BEA etc.

The Eclipse Ruby Development Tools were developed by a couple of
hobbyists in their spare time, without getting paid, with no research
budget at all, and even without knowing Eclipse programming.

> Does the fact that Ruby is STRONG dynaically typed, assist tool
> developers? Can I have tools with minimal analysis capabilities?


Pretty much all current Ruby IDEs (RDT, DLTK, 3rd Rail, NetBeans, Ruby
in Steel) have code completion, type inference, automated refactoring
tools and a lot of the things you would expect from a modern IDE. But,
again, this doesn't have anything to do with Ruby being "strongly
typed", it has to do with Ruby being high on the hype curve and
companies like Sun, CodeGear, Sapphire Steel and Aptana investing
money in Ruby IDEs.

jwm
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: "Strong typing vs. strong testing" namekuseijin Python 229 10-29-2010 09:02 AM
Re: "Strong typing vs. strong testing" namekuseijin C Programming 214 10-17-2010 01:12 PM
pop smtp dell restored me and dont know if they did any favors Linda Entler Microsoft Certification 0 04-18-2008 09:46 AM
Static Typing Where Possible and Dynamic Typing When Needed vladare Ruby 0 07-11-2005 11:54 AM
Compilation fails when a windows form user control is assigned a strong name but it refers to an activex control which does not have strong name ashish_gokhale ASP .Net Web Controls 0 05-05-2005 01:38 PM



Advertisments