Domain: nemerle.org
Stories and comments across the archive that link to nemerle.org.
Comments · 18
-
Re:An brief introduction to functional programming
OK, so why is it so hard to create a hybrid language?
It's not hard, and there are plenty of them:
From the list above, OCaml is presently production-quality, and used rather widely. It also has a good performance profile, rivalring C/C++ with carefully written code. Of the others, the fastest-growing seems to be F# (mostly because Microsoft announced that they're making it into "Visual F#" and likely including it into Visual Studio 2010 alongside C# and VB as the third out-of-the-box
.NET development language). Scala has a pretty large following in the Java land, so much so that some call for freeze of Java language spec for the sake of stability, and moving onto Scala for further language development.Also, most modern dynamic languages (Perl, Python, Ruby, JavaScript) have many functional traits, and so do quite a few mainstream static ones (C#, VB).
-
Some of my picks
C#/.NET - http://msdn.microsoft.com/
Haskell - http://haskell.org/
Nemerle - http://nemerle.org/
OCaml - http://caml.inria.fr/
PHP - http://php.net/
Python - http://python.org/
Ruby - http://ruby-doc.org/ (API docs), http://ruby-lang.org/ (for more links and info)
SML - http://smlnj.org/ (the most popular implementation), http://standardml.org/Basis/ (standard library)(X)HTML/CSS/DOM/XSL/etc. - http://w3.org/
Hm. Now that I've written it down, I see most of these are obvious, but then it makes sense, that the "official" sites tend to be the best reference.
-
Re:Now we only need a nameLinux is, and should be, so much more than a poor man's clone of either of these systems. The people who use Linux do so because they like it, not because it's free. If it were just about price any of us could have a "free" copy of windows too.
...
PS We all hate gnome, too. If we wanted the worst of mac combined with the worst of windows we'd just run vista! Thing is, we don't all hate GNOME. GNOME has some very innovative features, such as Beagle and the new GNOME File Chooser dialog, which make it ideal for some kinds of users. I personally prefer KDE for its superior customizability, but GNOME is by no means worthless. In the same way, I think that Mono has some very innovative features that are unique to it: Mono.Addins comes quickly to mind. Even outside of Mono, the Nemerle language is another great open-source addition to the .NET framework. The Gtk# engine is one of the most easy to use and powerful GUI frameworks yet made, and is only possible due to Mono. In short, please don't claim to represent all of Linux userdom when you spout off your hatred of GNOME and Mono. You don't. -
Re:deservedly
If you want REAL concurrency then look at Erlang (and it was created back in 1993).
If you want a feature-rich language supporting metaprogramming and functional programming style - then look at http://nemerle.org/Main_Page (I hope nobody from RSDN reads this...).
Spec# is yet-another-theorem-prover built in in language. NASA did this for Java years ago and I've read that a similar approach was used with Lisp back in 70-s.
I don't see much real innovations from MS Research. It seems that they just try to adapt existing ideas to Windows software stack. -
Re:Stroustrup is the problem
ML (or Haskell, Lisp, etc) for that matter would never be popular. They've had enough time and failed to gain popularity. The reason is simple - they dump too much on a poor brain of an average coder, who gets lost too fast to keep interest. The way forward is to get something well-understood and Algol/C-like and extend it into the right direction incorporating ideas from functional world. A good examples of this approach are C# 3.0 and Nemerle.
-
No bondage hereAnybody who dismisses
.Net as "bondage and discipline" isn't keeping up. Check out Boo, Nemerle, and IronPython. IronPython is compatible with CPython but actually runs faster. The author of Boo appeared on a panel discussion at the last PDC (Microsoft developers event). Of course it's not just a Microsoft playground with Mono out there.Also at PDC, there was a presentation about new features being added to the next version of the
.Net runtime, to better support dynamic languages. And back to C#, the new 2.0 supports closures, and 3.0 will have type inferencing. Plus there are rumors of some sort of macro facility coming. -
Re:Dynamic typingProblem is, languages like Java really do get static typing wrong. It's good to have it, but I shouldn't need to write the type for each and every local variable and private field that I declare - the compiler can be made smart enough to figure it out on its own and not bother me with that (aka type inference). Public class interface, of course, has to be defined explicitly to prevent subtle changes creeping in. For a good example of a language that works like that, have a look at Nemerle. In it you can, for example, write:
def list = List();
where in C#, you'd have to do:
list.Add(123);List<int> list = new List<int>();
Nemerle compiler is smart enough to deduce the specific version of generic class List from the way I use the object. I still get all the benefits of static typing, but none of the hassle of actually having to spell all the type names in full.
list.Add(123); -
Re:Eh... no
And don't forget about the ability to use a nice, modern programming language such as Nemerle, with all the FP, pattern-matching and macros goodness, while still retaining access to all the CLR libraries (and most importantly, Gtk#).
-
Re:Is Java falling behind?
Note that Generic Java has been around since 1999 or before, and you could use it if you wanted to have generics in your java code before 1.5 came out.
Sun took their time with Generics for a reason, they're very powerful but easy to get wrong. Maybe they dragged their heels a bit as well - I'm sure that a few people within the Java community didn't like the idea of 'messy code' because of all those angle brackets.
I'm hoping that the C# competition will be a mutually advantageous one, with the existence of the other driving innovation. The biggest threat to Java would be ignoring C#.
I don't like the LINQ syntax, and at some level would it be neater to merely have a neat data access abstraction system than to alter the language?
SQL:
SELECT name, age FROM customers WHERE city='London';
Java (I haven't used JDO or whatever it is called, but a quick implementation of an abstraction would probably come out with something like):
DataSource ds; ... // Returns an ArrayList of results, each result is a HashMap. // Alternatively we could create some form of Table datatype!
ArrayList results = Query(ds, "customers", new Fields("Name", "Age"), new HashMap().put("City", "London"));
I think that enough forms of data access abstraction exist already, and that they are a nicer way of extending a language than actually altering the language itself.
I was just reading http://nemerle.org/Features and I think that these new C# features are merely there to fix things that aren't very nice in the C# language at the moment. I truly hope that SQL on that page isn't how you have to do SQL in C# currently! -
Re:Why implicitly typed locals?
Can someone explain the point of this? C# is not JavaScript; these aren't true dynamically typed variables, the compiler just assigns a type for you instead of making you do it yourself. I can easily take half a second out of my day to figure out what type a variable should be, and end up with more readable code.
It's about saving time and typing effort. This C# 3.0 is honestly just a trivial hack though. Why bother with C# 3.0, when there's a .NET language that can be considered advanced enough to be C# 4.0; it's called Nemerle.
"Nemerle is a high-level statically-typed programming language for the .NET platform. It offers functional, object-oriented and imperative features. It has a simple C#-like syntax and a powerful meta-programming system."
With full type inference, not just "local" like in C# 3.0, Nemerle permits you to avoid specifying types practically anywhere. They also provide a C# to Nemerle code converter. Pretty cool. I'm definitely considering converting a major software product to Nemerle for the enhancements it provides. -
Re:Looks more like Delphi every release
Er, Delphi never supported type inference, closures, or metaprogramming of the sort that Microsoft are introducing to
.NET in C# 3 and VB 9. These features are coming from the functional programming world, from languages like Lisp and ML.
For existing languages that offer similar features in a braces syntax, see Nemerle or Scala.
(Languages like Ruby offer related features, but their lack of static typing means they're more distant cousins.) -
Re:This is not a troll, but a query...
http://www.nemerle.org/ is a functional language featuring macros. Actually, a good part of the language itself is defined as macros (if, for, while, some SQL stuff, etc.).
-
Re:Anyone Have Actual Experience With Mono?
Visual Basic and Java and Python and Oberon and Object Pascal and Boo and Nemerle and Component Pascal and Forth and Lisp and Smalltalk and Logo and Tachy.
Some of the packages are still in the larval stages, but they're out there, and more are on the horizon. -
Not just C#Check out Nemerle. It's a beautiful thing, really: a (largely) functional language, semantically somewhat close to O'Caml, yet syntactically very similar to C# (to ease learning for ye who haven't seen the light before), and designed from grounds up to integrate with the rest of CLR (unlike, say, F#) and CLS class libraries. What more, MonoDevelop has decent support for it, as well - you won't get code completion, but syntax highlighting and project management work.
If you have been thinking the language to pick for your next Gtk project, I highly recommend to take a look.
-
Re:Anyone Have Actual Experience With Mono?
Very true, I wasn't thinking about it that way. As an asside there is actually another programming language being worked on which compiles for the CLR. Nemerle - I haven't taken the time to evaluate it yet, but this is another interesting project resulting from the creation of mono. The other thing worth mentioning is that C++ vs C# both running in the managed runtime where C# is compiled for the CLR should have extremely similar performance numbers.
-
Re:Intrigued?
Don't forget about nemerle. It's built on
.net (and developed on mono). Its design clearly owes a lot to ml, but its syntax is much easier to wrap your head around than that of ml and derivatives, especially if you're coming from a C/C++/Java/C#/Perl/whatever background. -
Push popularity using .net/mono
This is where
.net and mono could do a difference. They allow any language to be used with each other. So get your favorite functional language compiled for .net and you instantly have the whole library.
But despite this and this, as far as I can see there have not been any massive worldwide shifts toward functional programming recently.
I guess it's hard to change. -
Re:Functional programming languages dying? F# XSLT
I don't see functional programming languages as dying at all. Caml has already been pointed out as a modern and viable language, and although F# is pointed to as an example of a functional language for
.NET, I think Nemerle is every bit as cool.
Also, although purely or almost-purely functional languages aren't that common or popular with the coding masses, the ideas and principles of the paradigm are slowly trickling down to the common languages. Things like algebraic datatype construction/deconstruction, as well as functions as first-class citizens aren't that uncommon any more.