We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexDiscussionGeneral Discussion,  Status › Processing a language
Page Index Toggle Pages: 1
Processing a language? (Read 1225 times)
Processing a language?
May 21st, 2007, 12:01am
 
Hi,

I'm writing an essay on Processing as part of my university exam for this semester. By now I think I have a pretty clear picture on what Processing is about and how it works. I'm just wondering why Processing is always refered to as a programming language when in fact it seems to be more of an API for Java with special, behind-the-scenes code generation and automatic handling of deployment issues, like Java classpaths and Jar-File creation.

So, why is it called a programming language? Is it just for lack of a better word or am I missing out on some bigger picture?

Thanks
Re: Processing a language?
Reply #1 - May 21st, 2007, 12:11am
 
All languages are really just front-ends for something more complex.. C is just a nice set of libraries, and some simplification for assembler for insance

Yes processing is on-top-of java, and there's behind the scenes magic that translates it into java, but it's not "Java" since you can't paste your code into eclipse and just hit compile.

Basically, you've got to ask the question, what make a programming language, and what makes a library...

For example at some level the java interpreter has to be compiled to native code so it can actually run. And parts of it may be writtn in C or C++ (or at least the first ever version must have been, and you can probably bootstrap from there should you have the source).. so does that make it just a really really big abstraction from C?
Re: Processing a language?
Reply #2 - May 21st, 2007, 1:51am
 
mercurio,

Maybe it's worth considering context with regard to the semantics of "what is a language". When you're within the Processing environment, the built-in commands seem to function as a distinct language. Of course you can deconstruct the context and consider the procedural commands as simply convenience calls to Java–the same way, in the spirit of JohnG's comment, you could consider Java garbage collection as simply front-end memory managment. I'm just not sure a reductionist approach is productive, especially independent of context.

I think it might also be interesting to consider the question in relation to a natural language. For example consider the transition from Latin(vulgar) to Italian, generally considered 2 distinct languages: there are hundreds of variations that, based on context, are either considered independent languages or Italian dialects. (Of course politics certainly had a hand in defining the so called "pure" version.)

Good luck on your exam.

ira

Re: Processing a language?
Reply #3 - May 21st, 2007, 2:02am
 
My definition of a "programming language" may be wrong, but I would put my finger on the syntax. If the syntax is the same, the language is the same. If there was a Python implementation that compiled into Java bytecode, then the "platform" the code runs on would be Java, yet the language it was coded in remains Python. There is a difference between the Java Platform and the Java "Programming Language" and I believe that the latter only refers to the syntax.

You might argue that Processing has different syntax because it doesn't need classes or even methods, thereby making it a PL. On the other hand, isn't that rather a simplification or maybe even more of a "framework" for Java-based graphics programming? I just don't think that the way Processing works makes it qualify as a PL. I think that for Processing, that description seems misleading and may cause a little confusion. For example, after reading about the "Processing Programming Language" I searched through all the "learning" articles looking for subtle changes in syntax to Java until I finally gave up and decided that Processing is Java running in a sort-of "pre-designed" environment.
Re: Processing a language?
Reply #4 - May 21st, 2007, 5:18am
 
That's a fair assessment and when I describe Processing to people I usually try to mention that it's actually written in Java because I'm not completely comfortable with calling it a programming language. However, the target audience (correct me if I'm wrong, people) is artists who have little to no experience programming. So, in that context, I think it makes more sense to just call Processing a programming language that you write in the PDE, rather than trying to explain to them how it's actually just a Java graphics framework that also happens to have a really simple IDE (if they even know what an IDE is) that lets you leave out some of the syntax/structure that is required by Java.
Re: Processing a language?
Reply #5 - May 21st, 2007, 5:52pm
 
>> My definition of a "programming language" may be wrong,
>> but I would put my finger on the syntax. If the syntax
>> is the same, the language is the same.

Seems like you're making this too dificult.  Your definition requires them to be the "same" to be considered the same.  Processing's syntax is not the *same* as Java, so by your own definition must be a separate language.  Doesn't that solve it?

>> You might argue that Processing has different syntax
>> because it doesn't need classes or even methods

All you need to do is settle on your preferred definition.  "Same" is one of those absolute words - it either is, or isn't.  Processing may be "very much like" Java, but is not "same as" Java.  (download the lexer source as a way to prove it)  And since Java has a formal specification, technically you shouldn't call Processing Java if it deviates from that spec.

The Processing environment effectively includes a cross-compiler, compiling one language as another - perhaps that's an alternate way of describing what it is/does?
Re: Processing a language?
Reply #6 - May 22nd, 2007, 10:41am
 
I would describe Processing as a rather complicated Java library with accompanying API. Especially seeing as you can build Processing projects in things like Eclipse or from the command line I guess.
Re: Processing a language?
Reply #7 - Jun 1st, 2007, 4:12am
 
What about "dialect of Java"? Smiley
Page Index Toggle Pages: 1