On Tue, 2011-11-08 at 10:56 +0000, Ricky Clarkson wrote: [ . . . ] > > Did the programmer mean to write int x = 123 or String x = "123"? For > that case you should be able to tell frm the context but in more > involved cases it might be difficult, or worse, some parts of code > assume the value is one type and some another. > > At this point this isn't specific to Groovy, for a dynamic language > Groovy at least does something at runtime with type annotations, which > is more than most do. > > The real issue is that mediocre programmers can create a worse mess in > a language that doesn't enforce types and maybe other restrictions > than one that does.
The real question here has nothing to do with Java, Groovy, static or dynamic, it is to do with why organization continue to employ sub-standard software developers, fail to train them to be competent, and then expect to get top-quality software. I agree that programming language is a tool and we should create and use the best tools available. Static languages and dynamic languages are different tools. We have to use them appropriately in the right context. I think demanding that programming language should hamstring the capable to protect against the incompetent is to solve the wrong problem in the wrong way. [ . . . stuff on GUIs and event loops elided due to unqualified agreement . . . ] > I hope the static mode catches on, and if it does I expect I'll look > at Groovy again if Oracle repeats Sun's to-ing and fro-ing on lambdas. I am looking forward to Grumpy Mode in Groovy as well, not as a protection mechanism, but as a new tool to expand capability. If Oracle do not get lambdas into Java at the next main release then Java really is headed for the scrap pile. Even C++ now has lambdas and a data structures and threading system that can use them. Though it is woefully lacking in actor and dataflow frameworks; asynchronous function call and futures are great tools, but actors and dataflow make for less complex and generally more correct and less buggy code. Fortunately Anthony Williams is working on this -- but as this is a Java list... -- Russel. ============================================================================= Dr Russel Winder t: +44 20 7585 2200 voip: sip:[email protected] 41 Buckmaster Road m: +44 7770 465 077 xmpp: [email protected] London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
signature.asc
Description: This is a digitally signed message part
