Content deleted Content added
Yoric~enwiki (talk | contribs) No edit summary |
Yoric~enwiki (talk | contribs) No edit summary |
||
Line 1:
▲== What exactly is a dynamic programming language ? ==
I believe that everyone agrees that '''dynamic programmig language''' does not have a precise definition. That's including programming language designers/designers wannabe [http://lambda-the-ultimate.org/node/12]. In addition, this term has been greatly misused by journalists and techies (including Gosling) who simply didn't know what they were talking about. If this article provides a precise definition, well, we need to build it first.
I believe that everybody agrees that
* Compiled C is not dynamic.
Line 14 ⟶ 12:
* Self-modifiable assembly language ?
* Dynamic = interpreted ?
* Dynamic = dynamically-typed ?
Line 26 ⟶ 24:
* Dynamic = new and shiny ?
* Is there such a thing as '''a dynamic programming language''' or should we say that one language is '''more dynamic''' than another ? I would vote for the second option.
* Is there such a thing as '''a dynamic programming language''' or should we say that one ''implementation'' of a language is '''dynamic''' ? I would vote for the second option. After all, iirc, there's an interpreted version of C, with a toplevel and the possibility of adding or replacing functions at run-time. Still, it is the same language.▼
== Interpretation ==
▲Is there such a thing as '''a dynamic programming language''' or should we say that one ''implementation'' of a language is '''dynamic''' ? I would vote for the second option. After all, iirc, there's an interpreted version of C, with a toplevel and the possibility of adding or replacing functions at run-time. Still, it is the same language.
Lisp is dynamic. Lisp can be compiled. Is that a good-enough counter-example ? I must admit that I don't know enough about the internals of Lisp compilation. [[User:Yoric|Yoric]] 16:58, 14 June 2006 (UTC)
== Dynamic typing, type annotations ==
===Characteristics of dynamic programming languages===▼
Could anyone give an example of a dynamic programming language which is not dynamically typed, or a dynamically typed programming language which is not dynamic? -- [[User:ciphergoth|ciphergoth]] 20:05, 2005 Apr 5 (UTC)▼
:Maybe. I'm still not sure what exactly this article wants to classify as a dynamic language. [[pike programming language|Pike]] is a statically typed, high level, object oriented, interpreted language. Is it a dynamic language? I can't tell from this article. Its similar to a statically typed python with C-style syntax though. [[User:Generic Player|Generic Player]] 04:09, 6 Apr 2005 (UTC)▼
The term '''dynamic programming language''' does not have a precise definition, but it is nevertheless useful to refer to what distinguishes "dynamic" languages such as [[Perl]] and [[Python programming language|Python]] from more traditional languages such as [[C programming language|C]], [[C Plus Plus|C++]], and [[Java programming language|Java]]. Not all languages considered dynamic will have all of the features below, and some non-dynamic languages will share some of them or have some way to achieve the same effect; the reader should assume that there are exceptions nearly all of the generalizations below.▼
This article is a complete mess, and badly in need of a rewrite. The language is informal and non-standard, and there are no sources to any of the potentially controversial (or at least non-obvious) assertions made. Plus, at least half of the content (the bit about functions and addresses) is simply incorrect. The way "dynamic" languages are described as using indirection rather than running code at a predefined memory address really is completely unimportant as a distinction -- it is possible to modify the contents of a memory address (or use it to point elsewhere) while code is running to change the behavior, and this can be done even in C. In fact, it is done in C quite often in some types of programming, such as emulators, for example.▼
Traditional programming languages require that the program be annotated with extra information (such as [[Datatype#Explicit_or_implicit_declaration_and_inference|type declarations]]) that makes the compile-time checking possible. Dynamic languages dispense with these annotations because they use extra information available at runtime instead. In particular, they are [[dynamic typing|dynamically typed]], and use [[garbage collection (computer science)|automatic memory management]].▼
The single most important distinguishing feature between most "dynamic" languages and "non-dynamic" languages has to do with type systems (and not interactivity, or some other fuzzily defined concept which doesn't hold under careful examination), yet type systems are practically ignored in the article. [[User:70.36.30.117|70.36.30.117]] 06:27, 28 March 2006 (UTC)▼
----▼
I'm not sure about the dynamic typing part. I mean yes, every dynamic language I can think of is dynamically typed. But I believe that this absence of static or semi-static checks is
----▼
▲Could anyone give an example of a dynamic programming language which is not dynamically typed, or a dynamically typed programming language which is not dynamic? -- [[User:ciphergoth|ciphergoth]] 20:05, 2005 Apr 5 (UTC)
To the best of my knowledge, no dynamic language needs type annotations -- although some can use them. Although [[OCaml]] is usually considered static by its fans and detractors, it doesn't need type annotations either. What do we conclude of this ? [[User:Yoric|Yoric]] 16:58, 14 June 2006 (UTC)
▲:Maybe. I'm still not sure what exactly this article wants to classify as a dynamic language. [[pike programming language|Pike]] is a statically typed, high level, object oriented, interpreted language. Is it a dynamic language? I can't tell from this article. Its similar to a statically typed python with C-style syntax though. [[User:Generic Player|Generic Player]] 04:09, 6 Apr 2005 (UTC)
===Rewrite===▼
I just started this rewrite, but didn't have time to finish it. I leave the text here in the hope it's useful in a future version -- [[User:ciphergoth|ciphergoth]] 20:05, 2005 Apr 5 (UTC)▼
In [[computer science]], a '''dynamic programming language''' is a kind of [[programming language]] in which many tests to ensure that each computational step is valid are deferred until the operation is actually performed (at [[runtime]]) rather than taking place when the program is first prepared for execution (at [[compile time]]). They allow programs to change their structure as they run: functions may be introduced or removed, new classes of objects may be created, new modules may appear.▼
▲The term '''dynamic programming language''' does not have a precise definition, but it is nevertheless useful to refer to what distinguishes "dynamic" languages such as [[Perl]] and [[Python programming language|Python]] from more traditional languages such as [[C programming language|C]], [[C Plus Plus|C++]], and [[Java programming language|Java]]. Not all languages considered dynamic will have all of the features below, and some non-dynamic languages will share some of them or have some way to achieve the same effect; the reader should assume that there are exceptions nearly all of the generalizations below.
==Discussions on Dynamic languages==▼
===Advantages===▼
▲Traditional programming languages require that the program be annotated with extra information (such as [[Datatype#Explicit_or_implicit_declaration_and_inference|type declarations]]) that makes the compile-time checking possible. Dynamic languages dispense with these annotations because they use extra information available at runtime instead. In particular, they are [[dynamic typing|dynamically typed]], and use [[garbage collection (computer science)|automatic memory management]].
* Dynamic programming languages are generally somewhat easier for newcomers to programming, in large part because they need not understand the system of annotations referred to above in order to write programs▼
▲----
▲This article is a complete mess, and badly in need of a rewrite. The language is informal and non-standard, and there are no sources to any of the potentially controversial (or at least non-obvious) assertions made. Plus, at least half of the content (the bit about functions and addresses) is simply incorrect. The way "dynamic" languages are described as using indirection rather than running code at a predefined memory address really is completely unimportant as a distinction -- it is possible to modify the contents of a memory address (or use it to point elsewhere) while code is running to change the behavior, and this can be done even in C. In fact, it is done in C quite often in some types of programming, such as emulators, for example.
▲The single most important distinguishing feature between most "dynamic" languages and "non-dynamic" languages has to do with type systems (and not interactivity, or some other fuzzily defined concept which doesn't hold under careful examination), yet type systems are practically ignored in the article. [[User:70.36.30.117|70.36.30.117]] 06:27, 28 March 2006 (UTC)
▲----
▲* Dynamic programming languages are generally somewhat easier for newcomers to programming, in large part because they need not understand the system of annotations referred to above in order to write programs
▲I'm not sure about the dynamic typing part. I mean yes, every dynamic language I can think of is dynamically typed. But I believe that this absence of static or semi-static checks is a consequence of other features, rather than a feature/drawback by itself. [[User:Yoric|Yoric]] 14:25, 14 June 2006 (UTC)
* This delay can be dramatically reduced almost to zero in practice however, for instance, the Objective-C programming language used a pre-loaded cache and a small bit of assembler code in order to reduce this overhead to a single operation.
Line 76 ⟶ 72:
[[User:Yoric|Yoric]] 14:25, 14 June 2006 (UTC)
▲I just started this rewrite, but didn't have time to finish it. I leave the text here in the hope it's useful in a future version -- [[User:ciphergoth|ciphergoth]] 20:05, 2005 Apr 5 (UTC)
▲In [[computer science]], a '''dynamic programming language''' is a kind of [[programming language]] in which many tests to ensure that each computational step is valid are deferred until the operation is actually performed (at [[runtime]]) rather than taking place when the program is first prepared for execution (at [[compile time]]). They allow programs to change their structure as they run: functions may be introduced or removed, new classes of objects may be created, new modules may appear.
|