Talk:Typed and untyped languages
This article needs to either be merged with strongly-typed programming languages or make clear two things: (1) that "strongly-typed" has many, many meanings (see strongly-typed programming languages for info) and that (2) exactly under what definition each of these languages is strongly- or weakly-typed. —Lowellian (talk)[] 22:19, Nov 20, 2004 (UTC)
- Can't we merge strongly-typed programming languages into this? Not sure why we want to talk about any typed and untyped languages over there. -- Taku 00:35, Nov 21, 2004 (UTC)
- Definitely don't merge strongly-typed programming language into this article (the other way around, maybe, though there are other solutions if people object to merging typed and untyped languages into strongly-typed programming language). "Strongly-typed programming language" is an actual term, and the article explains what strongly-typed is, whereas "typed and untyped languages" is not an actual term (in the sense that, while you can talk about the two together, "television and radio" is not an actual term), and it is also vague. "Typed and untyped languages" makes this article sound like basically a list—and in its current form, this article is essentially a list.
- On a side note, "typed" does not mean the same thing as "strongly-typed"; a "typed language" is anyone that uses explicit data types, so a "strongly-typed language" and a "weakly-typed language" are both still "typed languages".
I am not so concerned about the title. I was thinking we should have some central article that overviews what people mean when they say a language is typed and if so, how. Datatype discuss what is a type and how it is used in programming language, but the discussion on making a programming language typed may be beyond the scope of that article. Also, it is not important that the title of an article is actual term used in cs, as this is an encylcopedia. Take names like negative and non-negative numbers, binary and text files or Dispute over the name Sea of Japan. In here, it is not uncommon to name an article like television and radio. Terms like strongly-typed language, weakly ones and anything will be, of course, explained in this article as well. I think having a list, as it is the case in this article, is very important for this issue. Without showing confusions like C is strongly-typed or not, it would be pointless to discuss how people says a language is strongly-typed or not. Maybe the article can simpy be named like typed language since untyped just means not being typed, or even more put generally datatype in programming language or such. I am just not sure what would be the best name. -- Taku 14:01, Nov 21, 2004 (UTC)
I dont think this article adds much to anybody. Probably only on confusion. Saying that C and C++ isnt strongly-typed because it doenst obey every little "rule" about strongly-typing makes weak-typed means nothing. Since every language, except very fews, will be weakly-typed. Maybe the article shouldnt label the language as strongly-typed or weakly-typed. Only say in which things it makes each language strongly/weakly-typed (meaning various languages will be both in a way) and static/dynamic-typed (here too, like Java, I think). (Felipe Magno de Almeida)
Perl is a strongly typed language
Dan Sugalski:What the heck is: A type "Perl, oddly enough, is a good example of a strongly typed language. (The rich--and arguably excessive--behaviour of its base types tends to confuse folks on that account) A scalar is a scalar is a scalar--no matter what you do you'll never convince perl to treat it as an array, and when you have a reference to an array you can't, unlike in C, treat it as a reference to a hash or scalar or filehandle. There's no casting possible, either directly or through references." --Michal Jurosz 22:44, 1 Dec 2004 (UTC)
- The problem is that the term "strongly typed" is completely meaningless. Perl fits into maybe a couple of the definitions. Probably only a language like ML would fit most of them. The Strongly typed article shows all of the definitions; clearly Perl does not meet some of them (which is not a bad thing, but the continued use of the term as if it had meaning isn't very helpful). MShonle 05:11, 15 July 2005 (UTC)
Basic Perl example
$str = "3dfsd"; $int = 4; print $str + $int; print "\n"; print $str . $int; print "\n"; use strict; use warnings; my $str = "3dfsd"; my $int = 4; print $str + $int; print "\n"; print $str . $int; print "\n";
Output will be:
7 3dfsd4 Argument "3dfsd" isn't numeric in addition (+) at F:\p.pl line 13. 7 3dfsd4
--Michal Jurosz 22:44, 1 Dec 2004 (UTC)
untyped language means the language does not have any type declaration. Untyped is where operations are valid on everything because it's all a sequence of bits. Dynamic is completely different and refers to when the type is discovered. — Preceding unsigned comment added by 220.127.116.11 (talk) 17:51, 21 June 2015 (UTC) The term Untyped Language is not equivalent to weak typing or to dynamic typing. It implies a language in which values are simply chunks of bits, such as low-level assembler languages. PHP isn't untyped, Ruby isn't untyped, and isn't untyped either. The article does not reflect this definition. Wouter Lievens 10:18, 18 July 2005 (UTC)
- Effectively no modern programming languages, above the level of assembly, are untyped. --FOo 15:53, 21 September 2005 (UTC)
Strongly typed semantic
The problem is semantic and devolves from the overwhelming inclination amongst all IT folk to label things.
I would suggest Perl is strongly typable, C is less typable. This is more interpretive.
Strong vs. weak-typed languages
I suggest that this disinction be eliminated from the article. Several people have suggested this in the discussion above ("the term "strongly typed" is completely meaningless", "This article needs to ... make clear ... exactly under what definition each of these languages is strongly- or weakly-typed. ") and the similar point is made at Strongly-typed that the term "strongly-typed programming language" has no generally accepted meaning; accordingly, the division of languages into "strongly typed" and "weakly typed" will always be either arbitrary or inconsistent---or both, as it is in this article. The simple fact is that (for example) Python is strongly typed by some definitions and weakly typed by other definitions, and that all of these definitions are in common use.
The distinction between static and dynamic typing seems clearer to me, but I eagerly await arguments demonstrating that it is as meaningless as the distinction between "strong" and "weak" typing. -- Dominus 14:26, 23 June 2006 (UTC)