Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

HiRez

macrumors 603
Jan 6, 2004
6,251
2,576
Western US
I think Swift is going to be my favorite language in 1-2 years. In general I love it, but the tools (Xcode) are still so bad that sometimes it's still frustrating to make it do what you want, or figure out why the compiler doesn't like something you did. And compile times are soon slow. Plus, it's still somewhat incomplete and a little buggy, but in general has gotten better in the last 6 months.

For now, I still pick Objective-C (UI apps) and Python (scripting).
 

ArtOfWarfare

macrumors G3
Nov 26, 2007
9,570
6,079
Every programming language designer ends up reinventing a funny looking Lisp. Why not just use Lisp?

What does Lisp even mean? There's how many dozens of dialects of Lisp? The files will contain some metadata that isn't important for actually running the code, but is important for facilitating collaboration. Apart from that, you can just call it a dialect of Lisp.
 

rydewnd2

macrumors regular
Apr 3, 2007
176
11
New York City
Certainly, there can be less code involved in Python than in Objective-C. In Python, I can create a property and assign it a value, all in 1 line of code. In Obj-C, I have to declare the property, synthesize it or override the getter method, then set it.

The other thing with Python is you don't have to declare variables. I can run
Code:
print anobject.x
and Python won't care what anobject is, as long as it has a property named "x." In that way, Python makes up for its lack of protocols - I can create a delegate property that is told to run a function, and Python only cares that that function is defined.

AutoSynthesis Mate.. been around since Xcode 4
 

moonman239

Cancelled
Original poster
Mar 27, 2009
1,541
32
I think you're hitting at one of the key features of my language:

The syntax and style is whatever you want it to be. No more complaining about people who don't follow your style rule, or about having to follow someone else's style rule. If you want camel case and your coworker wants snake case, you can each use your own style. Somebody wants no braces around one line ifs and another wants them required, while a third wants significant whitespace like Python, a fourth wants to get lost in Lisp's parentheses, and somebody else thinks a graphical diagram is best for programming? Everyone can be happy.

The files themselves look like lisp (because it's trivial to write a parser for) in a plain text editor without a plugin, but I intend to have plugins for browsers and text editors to properly convert between that syntax and whatever your preferred syntax is (stored in a system wide file). Names and comments can be localized to multiple languages, so sharing code can be easier (granted, someone will need to make a translation.)

The programs that open/save the files are themselves written in the language, so you can write a new syntax using an old one.

Except that's not really close. Let me illustrate:

Let's say you're working on an app that uses an SQL database. For some reason, you'd rather use Java's JDBC interface than any other database connection thing. However, you also like the ease with which you can create loops in Ruby. To further complicate things, there's a portion of the app that you'd like to code in Python. But, your app also does something that's best done in C++. It would be most ideal, then, to be able to use all four languages in the same project.

It could happen.
 

cyb3rdud3

macrumors 68040
Jun 22, 2014
3,341
2,088
UK
Sounds like a right mess for me. A bit like how a tinkerer would design an RV on the cheap. Lots of parts from the bin gobbled together, but nothing working nicely together. Good luck with that.
 

kamy

macrumors member
Jul 27, 2011
44
0
Good old 'C' style languages works for me.

Why combine 5 lines of perfectly readable code into a single line - like some of these new languages do (Python, Swift etc). Hard to maintain, hard to read.
 

ArtOfWarfare

macrumors G3
Nov 26, 2007
9,570
6,079
Those who don't study the history of programming languages (there are many textbooks on the topic) are condemned to repeat its mistakes.

What makes you think I haven't studied the history of programming languages? The fact you seem to think Lisp means something implies you don't know how much of a mess the standards are for it. The chaos of the standards have rise to many incompatible implementations, of which Scheme and Racket seem to be the dominant two.
 

foobarbazqux

macrumors regular
Apr 17, 2014
124
60
Let's say you're working on an app that uses an SQL database. For some reason, you'd rather use Java's JDBC interface than any other database connection thing. However, you also like the ease with which you can create loops in Ruby. To further complicate things, there's a portion of the app that you'd like to code in Python. But, your app also does something that's best done in C++. It would be most ideal, then, to be able to use all four languages in the same project.

Sounds like a disaster
 

mamcx

macrumors regular
Mar 13, 2008
210
28
If you were allowed to use any of the currently-existing programming languages, and you could easily obtain whatever modules/packages/gems you need/want to use for any language, which language would you use and why?

Let's answer the question, before to divert:

I love python, pascal/delphi. IMHO the best *mainstream* lovable syntax+else as you get. "Else" is not just available libraries and tools, but the aproach/philosophy/style you see in the whole package. The python/pascal community share the idea of readability and quality of the libraries. In the dozens of languages I have use, in this are where I get less "I hate you" moments.

I like the direction of Julia (http://julialang.org/) and Nim (http://nim-lang.org/).

You will see I'm on the camp of readable syntax (in contrast to the "compact" syntax like in the C-family AND the "meta" syntax like in Lisp/Forth), because clarity on reading is more important. Take note, than for some people, have a more "compact" syntax is considerable readable too!

So, swift is also more lovable than obj-c to me.

My first is FoxPro. Underrated like hell, just like with the pascal family that, like other languages, lost the popularity contest with the C family. This have cause millons/hours of money lost, the full definition of "worse is better" (this apply to Javascript too). Hapily, rust (rust-lang.org) look like have a chance to get more popular, and take the lead in the C-family. GO (https://golang.org/) look a bit nicer too.

To take a easy shoot, is still weird that people "love" a language like C/C++ where compilation is still, 2015, slow like hell, when pascal, for example, fly.

----
Probably most developers are just fluent in less than 1-2 languages, and RARELY have a true poliglot background in diferent PARADIGMS. Plus, the first one is normaly your true love ;)

This cause a *very* strong perception, of mythical proportions, with cliches like "language not matter", "use the best tool for the job", "syntax is just sugar" "I know java|perl|BLA so what bother?" and similars, that ARE true -sometimes-, but most times is just a vague, cliche term. I know, because I'm one of them... like everyone else (you see: No matter how much you know or how poliglot, you still will fall in on side or other, and requiere more mental energy to learn to love the other side)

So, the best way is just be aware and learn as diverse as you could. Not just "Java, then C#" but also "OO then Functional then Logic then Prototype then Actor then ...."

This look like a ton of time. Not need to be. Have a quick glance here and there, just to be aware of how big is the world and know you can later visit again when you need too.

More important, learn what are the fundations behind them. For example, in functional languages you will heard a lot about "inmutable data-structures". That is valuable tool to be aware of.


If you are on python "simple is better". If you are in Haskell "Types are powerfull, and no, C++/Java types are not", If you are in Pascal "Structure your programs. C is not the only game in town for low-level", and so on. Not just learn the "mantra", to not fall in the cliche. Apply it, learn how. Try a language that force you to do that, then see if and how you can extract the meat of it to everything else.

I still apply what I have learn in FoxPro, and boy, this give "superpowers" with databases. For some weird reason, look like a lot of people consider databases complicated and scaried. I still think that the lack of more database-relational-alike programing is a ton of waste potential (I'm not the only one:https://github.com/papers-we-love/papers-we-love/blob/master/design/out-of-the-tar-pit.pdf).

----------

Sounds like a disaster

Not dismmis the idea that fast. In fact, sound like the direction behind all the push on programming!

You will love a more deep (but short) explanation:

http://tratt.net/laurie/blog/entries/programming_languages_and_the_speed_of_light

TLDR: All languages are converging is more or less the same thing, programing have prove to be harder than expected, more power not equal easier use
 

mamcx

macrumors regular
Mar 13, 2008
210
28
I am writing a new language....

I join this crazy idea of build a language too!.

Join https://www.reddit.com/r/compilers to talk about this. I'm at https://www.reddit.com/user/mamcx/ and talk more about related stuff...

I'm doing also in a different direction, looking at a relational language (+python-like syntax with julia-like multimethods or Go-like interfaces +Actors OR CSP). Something close is http://www.try-alf.org/blog/2013-10-21-relations-as-first-class-citizen.

It's not compiled right now. It has an interpreter written in C. Two reasons:
1 - I've written interpreters before, but never compilers.
2 - The speed increase would just be linear - similar speed gains could be gotten by just increasing the CPU.

Not dismiss a interpreter as easily. I think is possible to have a very performant one, see my question at http://lambda-the-ultimate.org/node/5075, plus Luajit show is possible to quick-ass.

why are languages being created this decade hardly any better than them? I had been just sitting on my ideas with the assumption someone else would do it first, until I realized that they won't.

Check http://tratt.net/laurie/blog/entries/programming_languages_and_the_speed_of_light. You can bet the pieces of a "better language" than the most mainstream (ie: C, C++, Java) have been truly done, but get overshadow by the big ones. Reading about this stuff to build my language I have learn a lot about this, and how much we (as industry) have missed because the C-family won.
 

moonman239

Cancelled
Original poster
Mar 27, 2009
1,541
32
Sounds like a disaster

Maybe. I'm thinking something like this: use a preface to tell the program maker/interpreter what language you are using. For example, you could preface your Python code with "python::," your C code with "c::," your Ruby code with "ruby::," etc.
 

Nosferax

macrumors regular
Nov 11, 2014
164
7
Maybe. I'm thinking something like this: use a preface to tell the program maker/interpreter what language you are using. For example, you could preface your Python code with "python::," your C code with "c::," your Ruby code with "ruby::," etc.

Or you could put your code in librairies and just call them from a container application...
 

czeluff

macrumors 6502
Oct 23, 2006
272
2
(This response is tailored to people reading this thread in search for a language they should learn, based on the feedback everyone here is giving)

I've been an ObjC developer for the past 3 years, and I've switched to Swift full-time. I enjoy it a lot.

If you're just starting out, don't waste your time getting into these battles over "the best language". Everyone likes different things. Instead, figure out what *you* would like to write!

If you want to make apps:
Swift for iOS
Java for Android
C# for Windows Phone

If you want to make websites:
HTML/CSS/(some) Javascript are essential for front-end
Ruby on Rails for back-end
Python + Django is another back-end possibility
Javascript + NodeJS is another back-end possibility
Elixir + Phoenix is another back-end possibility (pretty hipster)

The main point is to have fun! I enjoyed Objective-C for the past 3 years, where others despise the language. And Swift is Apple's latest, and I really love it. I never enjoyed Java when I used it in college, and I don't enjoy developing for Android as much as iOS. But if you like Android, and you start picking up Java quickly, then have at it!

It's all up to you - don't let anyone in a forum tell you your preferred language is stupid, because there's a community of millions of developers who enjoy the same language you do.
 

ArtOfWarfare

macrumors G3
Nov 26, 2007
9,570
6,079
(This response is tailored to people reading this thread in search for a language they should learn, based on the feedback everyone here is giving)

I've been an ObjC developer for the past 3 years, and I've switched to Swift full-time. I enjoy it a lot.

If you're just starting out, don't waste your time getting into these battles over "the best language". Everyone likes different things. Instead, figure out what *you* would like to write!

If you want to make apps:
Swift for iOS
Java for Android
C# for Windows Phone

If you want to make websites:
HTML/CSS/(some) Javascript are essential for front-end
Ruby on Rails for back-end
Python + Django is another back-end possibility
Javascript + NodeJS is another back-end possibility
Elixir + Phoenix is another back-end possibility (pretty hipster)

The main point is to have fun! I enjoyed Objective-C for the past 3 years, where others despise the language. And Swift is Apple's latest, and I really love it. I never enjoyed Java when I used it in college, and I don't enjoy developing for Android as much as iOS. But if you like Android, and you start picking up Java quickly, then have at it!

It's all up to you - don't let anyone in a forum tell you your preferred language is stupid, because there's a community of millions of developers who enjoy the same language you do.

You missed something. If you're making games, for any platform, Unity is the way to go.

Also, there are many alternatives you can use for the front-end of your website, although those alternatives all compile down to JavaScript.
 

iSee

macrumors 68040
Oct 25, 2004
3,539
272
You missed something. If you're making games, for any platform, Unity is the way to go.

Also, there are many alternatives you can use for the front-end of your website, although those alternatives all compile down to JavaScript.

Unity licensing can be quite expensive.
 

ArtOfWarfare

macrumors G3
Nov 26, 2007
9,570
6,079
Unity licensing can be quite expensive.

You only need to license if you're making over $100K/year from your games. If you're making that much money, I don't think you're allowed to complain about the one time fee of $1500 for the tool that makes it all possible - it's almost certainly less than half what you paid for the hardware you're developing on.
 

iSee

macrumors 68040
Oct 25, 2004
3,539
272
You only need to license if you're making over $100K/year from your games. If you're making that much money, I don't think you're allowed to complain about the one time fee of $1500 for the tool that makes it all possible - it's almost certainly less than half what you paid for the hardware you're developing on.

Well, it's only the SDK with a limited feature set that's free. And I think it's more like $4500 if you want to release for iOS and Android. And that's $100K gross. If you're doing a game as anything beyond a hobby there's going to be a lot of expenses coming out of any gross amount before you see much money.
 

ArtOfWarfare

macrumors G3
Nov 26, 2007
9,570
6,079
Well, it's only the SDK with a limited feature set that's free.

The limited feature set seems to cover around 99% of all of Unity's features. The only two I've seen that require you to pay are the realistic water and render targets (I wanted to put a 3D model on a HUD element, but couldn't with the free version since that would require render targets. So I'm settling for just text and images in my HUD for now. If it ends up successful enough that I need to buy Pro anyways, I'll have an update where I put the model in the HUD like I wanted.)

This is getting waaaaay off topic now.
 

DaveP

macrumors 6502a
Mar 18, 2005
506
433
The syntax and style is whatever you want it to be. No more complaining about people who don't follow your style rule, or about having to follow someone else's style rule. If you want camel case and your coworker wants snake case, you can each use your own style. Somebody wants no braces around one line ifs and another wants them required, while a third wants significant whitespace like Python, a fourth wants to get lost in Lisp's parentheses, and somebody else thinks a graphical diagram is best for programming? Everyone can be happy.

I think you just defined debugging hell.
 

ArtOfWarfare

macrumors G3
Nov 26, 2007
9,570
6,079
I think you just defined debugging hell.

How so? I feel you've misunderstood. Everyone sees and writes the code however they prefer - it translates between the forms for you. They're all equivalent.

Way too much time is wasted on debating over the pros/cons of different syntaxes. It doesn't matter. It's all preference.
 

ghellquist

macrumors regular
Aug 21, 2011
146
5
Stockholm Sweden
Quite different

I believe there is a lot to gain by understanding several different "universes", or paradigm for programming languages. It might not be immediately useful, but does enlarge the world. I come from a heavy procedural background: assembly language, c and so on. With a bit of object orientation, such c++. Add Python, Perl, java, javascript, basic and simliar stuff, and we have one continent in the language universe. But there are others.

I have a few favourites right now. Not sure if I will ever program anything useful using those languages.

Erlang with libraries for solving a number of difficult problems in a very elegant way. To me, being able to update a running program to a new version while it is running is nothing short of great.

Haskell because it turns most of my experiences as programmer upside down. Functional programming makes you think about some problems quite differently.

Coq because, again, this is something completely different. Not sure I really understand it, but it sure is something completely different.

// Gunnar
 

DaveP

macrumors 6502a
Mar 18, 2005
506
433
How so? I feel you've misunderstood. Everyone sees and writes the code however they prefer - it translates between the forms for you. They're all equivalent.

Way too much time is wasted on debating over the pros/cons of different syntaxes. It doesn't matter. It's all preference.

Now it makes more sense. Though there are a lot of constructs that exist in some languages but not others or would require a lot of complexity.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.