Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c > #63045

Re: one type less language

From Bartc <bc@freeuk.com>
Newsgroups comp.lang.c
Subject Re: one type less language
Date 2015-06-07 20:20 +0100
Organization A noiseless patient Spider
Message-ID <ml25fu$ebr$1@dont-email.me> (permalink)
References <ee5b4ddd-7a35-4bff-bc23-b04ec5abf25a@googlegroups.com> <4fc72288-16e5-41cc-a814-7b598cbc2c13@googlegroups.com> <cthdk0Fnjb7U2@mid.uni-berlin.de> <0132eb60-ad1e-45ca-8284-947863adb446@googlegroups.com>

Show all headers | View raw


On 07/06/2015 17:59, Malcolm McLean wrote:
> On Sunday, June 7, 2015 at 12:21:46 AM UTC+1, Jens Thoms Toerring wrote:
>>
>> There are lots of languages that don't care much about types,
>> Python is probably one of the most commonly used at the moment.
>> But, while a more-or-less type-agnostic language can be very
>> nice for rapid prototyping, it has also its disadvantages:
>> not having to define new variables or "cast" in assignments,
>> it allows for bugs that, in strongly-typed language would
>> have been caught at some stage (either by the compiler or
>> the interpreter).
>>
> The motive is to make the script interpreter easier to write.
> You just bung in a hash table to allow indexing of dynamic type
> elements by string identifier, and you don't care if "name"
> returns a string, a structure with title, forename and surname
> members, or a function that sets a name.

Actually, it makes it a bit harder to write, and the bytecode compiler, 
if there is one, a bit easier. But writing source code becomes quicker 
and easier too, which is the advantage.

The interpreter still needs to do type dispatching at runtime (you do 
need to care when about to multiply a list by a string for example), 
unlike one for a language with static types.

-- 
Bartc

Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

one type less language asetofsymbols@gmail.com - 2015-06-05 22:08 -0700
  Re: one type less language David Kleinecke <dkleinecke@gmail.com> - 2015-06-06 09:35 -0700
  Re: one type less language Richard Damon <Richard@Damon-Family.org> - 2015-06-06 13:10 -0400
    Re: one type less language Les Cargill <lcargill99@comcast.com> - 2015-06-06 13:01 -0500
    Re: one type less language Michael Angelo Ravera <maravera@prodigy.net> - 2015-06-07 13:03 -0700
  Re: one type less language Les Cargill <lcargill99@comcast.com> - 2015-06-06 12:55 -0500
  one type less language asetofsymbols@gmail.com - 2015-06-06 12:15 -0700
    Re: one type less language Bartc <bc@freeuk.com> - 2015-06-06 20:23 +0100
    Re: one type less language Ben Bacarisse <ben.usenet@bsb.me.uk> - 2015-06-06 20:28 +0100
    Re: one type less language jt@toerring.de (Jens Thoms Toerring) - 2015-06-06 23:21 +0000
      Re: one type less language Malcolm McLean <malcolm.mclean5@btinternet.com> - 2015-06-07 09:59 -0700
        Re: one type less language Bartc <bc@freeuk.com> - 2015-06-07 20:20 +0100
          Re: one type less language jt@toerring.de (Jens Thoms Toerring) - 2015-06-08 09:42 +0000
            Re: one type less language Bartc <bc@freeuk.com> - 2015-06-08 11:28 +0100
              Re: one type less language Malcolm McLean <malcolm.mclean5@btinternet.com> - 2015-06-08 05:10 -0700
                Re: one type less language Mel <mel@zzzzz.com> - 2015-06-08 15:39 +0300
      Re: one type less language "J. Clarke" <j.clarke.873638@gmail.com> - 2015-09-08 05:23 -0400
        Re: one type less language Robert Wessel <robertwessel2@yahoo.com> - 2015-09-08 10:20 -0500
  Re: one type less language Keith Thompson <kst-u@mib.org> - 2015-06-06 13:56 -0700
    Re: one type less language luser droog <luser.droog@gmail.com> - 2015-06-07 23:20 -0700
      Re: one type less language asetofsymbols@gmail.com - 2015-06-08 02:50 -0700

csiph-web