8

I am working on a new language, targeted for web development, embeding into applications, distributed applications, high-reliability software (but this is for distant future).

Also, it's target to reduce development expenses in long term - more time to write safer code and less support later. And finally, it enforces many things that real teams have to enforce - like one crossplatform IDE, one codestyle, one web framework.

In short, the key syntax/language features are:

  1. Open source, non-restrictive licensing. Surely crossplatform.

  2. Tastes like C++ but simpler, Pythonic syntax with strict & static type checking. Easier to learn, no multiple inheritance and other things which nobody know anyway :-)

  3. LLVM bytecode/compilation backend gives near-C speed.

  4. Is has both garbage collection & explicit object destruction.

  5. Real OS threads, native support of multicore computers. Multithreading is part of language, not a library.

  6. Types have the same width on any platform. int(32), long(64) e.t.c

  7. Built in post and preconditions, asserts, tiny unit tests. You write a method - you can write all these things in 1 place, so you have related things in one place. If you worry that your class sourcecode will be bloated with this - it's IDEs work to hide what you don't need now.

  8. Java-like exception handling (i.e. you have to handle all exceptions)

I guess I'll leave web & cluster features for now...

What you think? Are there any existing similar languages which I missed?

nobody
  • 19,814
  • 17
  • 56
  • 77
BarsMonster
  • 6,483
  • 2
  • 34
  • 47
  • 4
    My first impression: you need somebody who can write correct English for this to be popular. Unless you can demonstrably deliver on your list of promises *and* come up with a killer use, people will go by their first impressions. Incorrect English will really hurt a first impression. – David Thornley Sep 07 '10 at 15:29
  • 3
    If you enjoy doing it, then keep at it, but don't quit your day job. The world has enough programming languages. Ever heard of [esperanto](http://en.wikipedia.org/wiki/Esperanto)? – Humphrey Bogart Sep 07 '10 at 16:26
  • @David Thornley: I totally agree with you. I am not native English speaker, so I will never write error-free :-) – BarsMonster Sep 07 '10 at 20:38
  • 1
    @Beau Martínez: Surely I won't quit, as it gives me the money to pay guys I hired. I've heard about Esperanto and even tried to learn it :-D – BarsMonster Sep 07 '10 at 20:57

10 Answers10

10

To summarize: You language has no real selling points. It just does what a dozen other languages already did, with syntax and semantics just slightly off, depending on where the programmer comes from. This may be a good thing, as it makes the language easier to adapt, but you also have to convince people to trouble to switch. All this stuff has to be built and debugged and documented again, tools have to be programmed, people have to learn it and convince their pointy-haired bosses to use it, etc. "So it's language X with a few features from Y and nicer syntax? But it won't make my application's code 15% shorter and cleaner, it won't free me from boilerplate X, etc - and it won't work with my IDE." The last one is important. Tools matter. If there are no good tools for a language, few people will shy away, rightfully so.

And finally, it enforces many things that real teams have to enforce - like one crossplatform IDE, one codestyle, one web framework.

Sounds like a downside! How does the language "enforce one X"? How do you convince programmers this coding style is the one true style? Why shouldn't somebody go and replace the dog slow, hardly maintained, severly limited IDE you "enforce" with something better? How could one web framework possibly fit all applications? Programmers rarely like to be forced into X, and they are sometimes right.

Also, you language will have to talk to others. So you have ready-made standard solutions for multithreading and web development in mind? Maybe you should start with a FFI instead. Python can use extensions written in C or C++, use dynamic libraries through ctypes, and with Cython it's amazingly simple to wrap any given C library with a Python interface. Do you have any idea how many important libraries are written in C? Unless your language can use these, people can hardly get (real-world) stuff done with it. Just think of GUI. Most mayor GUI toolkits are C or C++. And Java has hundreds of libraries (the other JVM languages profit much from Java interop) for many many purposes.

Finally, on performance: LLVM can give you native code generation, which is a huge plus (performance-wise, but also because the result is standalone), but the LLVM optimizers are limited, too. Don't expect it to beat C. Especially not hand-tuned C compiled via icc on Intel CPUs ;)

  • `You language has no real selling points. It just does what a dozen other languages already did, with syntax and semantics just slightly off, depending on where the programmer comes from.` That never hurt C#. – Humphrey Bogart Sep 07 '10 at 16:25
  • @Beau: But the OP won't make one of the world's biggest corporations push his language ;) –  Sep 07 '10 at 17:21
  • @Beau: C# started off with a killer function: writing .NET programs, particularly for people who'd be embarrassed to be writing VB.NET. Java started off with a killer function: writing applets, since it was write once, run anywhere. The fact that almost nobody does that anymore and it never did work as advertized doesn't mean it wasn't important in getting Java started. – David Thornley Sep 07 '10 at 18:25
  • Code style: It is easily enforcible Python way :-) Make violation a syntax mistake :-) I am not going to write crappy IDE from scratch, this is going to be Eclipse plugin. In many (sucesfull) companies developers are already enforced to follow codestyle & IDE requirement. You just cannot install and use different IDE or format file the way you like. You just do like others do or get fired. If everyone would start following that (with realtime help from IDE) everyone would benefit from unification. – BarsMonster Sep 07 '10 at 20:45
  • There definitely will be a possibility to integrate with 3rd party binary libraries, it's not a big deal, as the language is kinda C friendly. Clang(LLVM based) already competes with GCC, I don't see why I can't do the same. Well, being 20% slower is not a big deal at the beginning while Python/PHP/many other langs are dozens and hundreds of times slower. – BarsMonster Sep 07 '10 at 20:48
8

"Are there any existing similar languages which I missed?"

D? Compared to your features:

  1. The compiler has a dual license - GPL and Artistic
  2. See example code here.
  3. LDC targets LLVM. Support for D version 2 is under development.
  4. Built-in garbage collection or explicit memory management.
  5. core.thread
  6. Types
  7. Unit tests / Pre and Post Contracts
  8. try/catch/finally exception handling plus scope guarantees
Corbin March
  • 25,526
  • 6
  • 73
  • 100
  • Yeah, at first I didn't notice that he's talking about making his own language, and I thought he was trying to gauge the appeal of D w/o mentioning it by name. – dsimcha Sep 07 '10 at 21:29
5

What you've given us is a list of features, with no coherent philosophy, or explanation as to how they will work together. None of the features are unique. At best, you're offering incremental improvements over what's already there. I'd expect there's already languages kicking around with what you've said, it's just that they're still fairly obscure, because they didn't make it.

Languages have inertia. People have to learn new languages, and sometimes new tools. They need incentive to do so, and 20% improvement in a few features doesn't cut it.

What you need, at a minimum, is a killer app and a form of elevator pitch. (The "elevator pitch" is what you tell the higher-ups about your project when you're in the elevator with them, in current US business parlance.) You need to have your language be obviously worth learning for some purpose, and you need to be able to tell people why it's worth learning before they think "just another language by somebody who wanted to write a language" and go away.

You need to form a language community. That community needs to have some localization at first: people who work in X big company, people who want to do Y, whatever. Decide on what that community is likely to be, and come up with one big reason to switch and some reasons to believe that your language can deliver what it promises.

David Thornley
  • 56,304
  • 9
  • 91
  • 158
  • Very true. All this most of the times require planning. But sometimes, things just happen and fall in place. – pavanlimo Sep 07 '10 at 17:41
  • There is a philosophy: Sacrifice some convenience to get unification & safety. This will make it attractable for project managers, not developers. Developers might like these incremental improvements and performance. – BarsMonster Sep 07 '10 at 20:52
  • @BarsMonster: In which case you need to explain the philosophy, as part of the description. On the other hand, in another comment you say you're not trying to conquer the enterprise market, which seems odd for a language designed to be attractive to project managers. – David Thornley Sep 08 '10 at 14:13
  • There are stuff for large Enterprise applications with heavy DBs and ultraheavy frameworks (like Java+EJB). I am not going there. Target is small and mid. business. – BarsMonster Sep 08 '10 at 16:34
5

Responding to a few of your points individually (I've omitted what I consider either unimportant or good):

targeted for web development

Most people use php. Not because it's the best language available, that's for sure.

embeding into applications

Lua.

distributed applications, high-reliability software (but this is for distant future).

Have you carefully studied Erlang, both its design and its reference implementation?

it enforces many things that real teams have to enforce - like one crossplatform IDE, one codestyle, one web framework.

If your language becomes successful, people will make other IDEs, other code styles, other web frameworks.

Multithreading is part of language, not a library.

Really good languages for multithreading forbid side effects inside threads. Yes, in practice that pretty much means Erlang only.

Types have the same width on any platform. int(32), long(64) e.t.c

Sigh... There's only one reasonable width for integers outside of machine-level languages like C: infinite.


Designing your own language will undoubtedly teach you someting. But designing a good language is like designing a good cryptosystem: lots of amateurs try, but it takes an expert to do it well.

I suggest you read some of Norman Ramsey's answers here on programming language design, starting with this thread.

Given your interest in distributed applications, knowing Erlang is a must. As for sequential programming, the minimum is one imperative language and one functional language (ideally both Lisp/Scheme and Haskell, but F# is a good start). I also recommend knowing at least one high-level language that doesn't have objects, just so you understand that not having objects can often make the programmer's life easier (because objects are complex).

As for what could drive other people to learn your language... Good tools/libraries/frameworks can't hurt (FORTRAN, php), and a big company setting the example can't hurt (Java, C#). Good design doesn't seem to be much of a factor (a ha-ha-only-serious joke has it that what makes a language successful is using {braces} to delimit blocks: C, C++, Java, C#, php)...

Community
  • 1
  • 1
Gilles 'SO- stop being evil'
  • 104,111
  • 38
  • 209
  • 254
4

No.

Every buzzword you have included in your feature list is an enormous amount of work to be spec'd, implemented, documented, and tested.

How many people will be actively developing the language? I guess the web is full of failed programming language projects. (Same is true for non-mainstream OSes)

Have a look at what .Net/Visual Studio or Java/Eclipse have accomplished. That's 1000s of years of specification, development, tests, documentation, feedback, bug fixes, service packs.

During my last job I heard about somebody who wrote his own programming framework, because it was "better". The resulting program code (both in the framework and in the applications) is certainly unmaintainable once the original programmer quits, or is "hit by a bus", as the saying goes.

As the list sounds like Java++ or Mono++, you'd probably be more successful in engaging in an existing project, even if it won't have your name tag on it.

devio
  • 36,858
  • 7
  • 80
  • 143
  • 1
    Well, both Java and Mono are cool, but bulky for many uses and too hard to master & become an expert. I am not trying to conqure enterprise market. Currently there are me, 2 part-time volonters working fixed 20 hours/week and 1 full-time payd developer. – BarsMonster Sep 07 '10 at 15:02
  • Also, If It would be just a set of buzzwords, I would place Lambdas and Closures on #1 and #2, but they are not here at all :-) – BarsMonster Sep 07 '10 at 20:54
4

Perhaps you missed one key term. Performance.

In any case, unless this new language has some really out-of-this-world features(ex: 100% increase in performance over other web development languages), I think it will be yet another fish in the pond.

Currently I'm responsible for maintaining a framework developed/owned by my company. It's a nightmare. Unless there is a mainstream community, working on this full time, it's really an elephant. I do not appreciate my company's decision to develop its own framework(because it's supposed to be "faster") day 'n night.

pavanlimo
  • 4,122
  • 3
  • 32
  • 47
1

The language tastes good in my opinion, I don't want use java for a simple website but I would like to have types and things like that. ASP .NET is a problem because of licensing and I can't afford those licenses for a single website... Also features looks good

Remember a lot of operator overloading: I think is the biggest thing that PHP is actually missing. It allows classes to behave much more like basic types :)

When you have something to test I'll love to help you with it! Thanks

Francesco Belladonna
  • 11,361
  • 12
  • 77
  • 147
1

Well, if you have to reinvent the wheel, you can go for it :)

I am not going to give you any examples of languages or language features, but I will give you one advice instead:

Supporting framework is what is the most important thing. People will tend to love it or hate it, depending on how easy is to write good code that get job done. Therefore, please do usability test before releasing it. I mean ask several people how they will do certain task and create API accordingly. Then test beta API on other coders and listen carefully to their comments.

Regards and good luck :)

Paweł Dyda
  • 18,366
  • 7
  • 57
  • 79
1

There's always space for another programming language. Apart from getting the design right, I think the biggest problem is coming across as just another wannabe language. So you may want to look at your marketing, you need a big sponsor who can integrate your language into their products, or you need to generate a buzz around it, easiest way is astroturfing. Good luck.

http://en.wikipedia.org/wiki/List_of_programming_languages

NB the names G and G++ aren't taken. Oh and watch out for the patent trolls.

Edit

Oops G / G++ are taken... still there are plenty more letters left.

Jaydee
  • 4,138
  • 1
  • 19
  • 20
  • 1
    g++ is the Gnu C++ compiler. While it may not technically be taken, using it for anything else will cause a great deal of confusion. – David Thornley Sep 07 '10 at 15:32
1

This sounds more like a "systems" language rather than a "web development language". The major languages in this category (other than C++/C) are D and Go.

My advice to you would be to not start from scratch but examine the possibility of creating tools or libraries for those languages, and seeing just how far you can push them.

cdiggins
  • 17,602
  • 7
  • 105
  • 102
  • Ofcourse going from scratch is not an option. I am only thinking about making LLVM frontend for it, so lots of stuff would be done automagically. – BarsMonster Oct 11 '11 at 08:43