Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
| From | Bartc <bc@freeuk.com> |
|---|---|
| Newsgroups | comp.lang.c |
| Subject | Re: a style question: |
| Date | 2015-09-01 22:53 +0100 |
| Organization | A noiseless patient Spider |
| Message-ID | <ms56ld$lsf$1@dont-email.me> (permalink) |
| References | (5 earlier) <d4k6i5Ff37rU1@mid.uni-berlin.de> <ms2qfd$v8c$1@dont-email.me> <d4lu84Fr132U1@mid.uni-berlin.de> <ms4lr9$dih$1@dont-email.me> <d4mh43F2geiU1@mid.uni-berlin.de> |
On 01/09/2015 21:45, Jens Thoms Toerring wrote: > Bartc <bc@freeuk.com> wrote: >> It doesn't have general purpose OO features; one reason is that many of >> the problems for which they would be needed in C++, are already solved >> in the language (generics and polymorphism for example). (The main such >> requirement has actually been overloading 'to-string' for printing user >> types, and that can be done with a discreet mechanism to link a type >> with a function). > > In other posts you had given the impression that it were a com- > piled language, but now it's an interpreted one. I guess you are > aware that there are some differences between those two and that > an interpreted language may take some "liberties" that aren't > possible for a compiled one. I have two private languages: one is statically typed and compiled, at about the same level as C, and the other is dynamically typed and interpreted. It's the latter that has all the features, and I use the first one to implement it. Notice there's a big gap in the middle where some people like to put C++, but I have no need for! Similarly, CPython is currently implemented in C. I don't see what benefit there would be in switching to C++. Python has, for example, flexible strings, but it doesn't need the implementation language to have flexible strings too! So it's a bit like comparing apples > to bananas. What about the execution speed? C++ aims at retaining > a similar speed as C and seems to fare not too bad in that respect. > I guess that this hardly is possible with an interpreted one. Care > to show any meaningful benchmarks? I'm not going to pretend the interpreted language is as fast as C or C++. In numeric benchmarks, it might be a magnitude slower. (But I have long experience of balancing the two kinds of language I use: if you get it right, an application mixing compiled and dynamic languages is not going to be significantly slower than one that has 100% native code.) This is not the point however (and after all some clever chap can come along and a create a fast JIT tracing compiler for it); I'm using this as an example of designing a language where you can have the features, without the visible overheads and complexity. A lot can be applied to a C-like static language too. > Is it bound to single processor architecture and/or operating > system? Inquirung minds may want to know. (The interpreter can be translated to C source, and therefore could run on a wide range of platforms. It's been tried on x86, x64, ARM-32, and on Windows and Linux. Notice again, I don't need to target C++; it doesn't buy me anything.) > And then I've still not seen a shred of a real description of your > language, just a very vague and general description, which might fit > the advertizing blurb for a lot of other interpreted languages. With- > out any reasonable documentation there's nothing to compare it to > C++, it's all claims you made. You wrote > > "that can do much of what C++ can do, and with none of the fuss" > > Either substantiate your claims or better refrain from making > them. I've already explained above. I didn't go into details because it's not that different from many other dynamic languages. Just substitute Python, Ruby, Lua etc, they can all do the same. (Although they do all have OO too, they don't need it for this basic stuff.) (The language is real enough though; here's an example: http://pastebin.com/dCpGzUps, which is part of a compiler, that generates C code. As I said, nothing remarkable, but it does make use of expanding lists and strings with little fuss, as I also said.) -- Bartc
Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
a style question: G G <gdotone@gmail.com> - 2015-08-31 02:30 -0700
Re: a style question: Ian Collins <ian-news@hotmail.com> - 2015-08-31 21:40 +1200
Re: a style question: jt@toerring.de (Jens Thoms Toerring) - 2015-08-31 09:52 +0000
Re: a style question: Malcolm McLean <malcolm.mclean5@btinternet.com> - 2015-08-31 03:24 -0700
Re: a style question: Bartc <bc@freeuk.com> - 2015-08-31 11:50 +0100
Re: a style question: Ben Bacarisse <ben.usenet@bsb.me.uk> - 2015-08-31 13:21 +0100
Re: a style question: Malcolm McLean <malcolm.mclean5@btinternet.com> - 2015-08-31 05:41 -0700
Re: a style question: Bartc <bc@freeuk.com> - 2015-08-31 14:55 +0100
Re: a style question: Ben Bacarisse <ben.usenet@bsb.me.uk> - 2015-08-31 15:50 +0100
Re: a style question: Bartc <bc@freeuk.com> - 2015-08-31 18:40 +0100
Re: a style question: Melzzzzz <mel@zzzzz.com> - 2015-08-31 17:46 +0200
Re: a style question: Bartc <bc@freeuk.com> - 2015-08-31 17:27 +0100
Re: a style question: Melzzzzz <mel@zzzzz.com> - 2015-08-31 18:42 +0200
Re: a style question: Jorgen Grahn <grahn+nntp@snipabacken.se> - 2015-08-31 17:41 +0000
Re: a style question: Malcolm McLean <malcolm.mclean5@btinternet.com> - 2015-08-31 15:33 -0700
Re: a style question: Jorgen Grahn <grahn+nntp@snipabacken.se> - 2015-09-01 08:34 +0000
Re: a style question: Ian Collins <ian-news@hotmail.com> - 2015-09-01 07:40 +1200
Re: a style question: Bartc <bc@freeuk.com> - 2015-08-31 21:36 +0100
Re: a style question: Ian Collins <ian-news@hotmail.com> - 2015-09-01 08:51 +1200
Re: a style question: Bartc <bc@freeuk.com> - 2015-08-31 22:37 +0100
Re: a style question: Malcolm McLean <malcolm.mclean5@btinternet.com> - 2015-08-31 15:24 -0700
Re: a style question: Ian Collins <ian-news@hotmail.com> - 2015-09-02 19:37 +1200
Re: a style question: jt@toerring.de (Jens Thoms Toerring) - 2015-08-31 23:33 +0000
Re: a style question: Bartc <bc@freeuk.com> - 2015-09-01 01:13 +0100
Re: a style question: Ian Collins <ian-news@hotmail.com> - 2015-09-01 18:21 +1200
Re: a style question: jt@toerring.de (Jens Thoms Toerring) - 2015-09-01 15:23 +0000
Re: a style question: Bartc <bc@freeuk.com> - 2015-09-01 18:06 +0100
Re: a style question: Jorgen Grahn <grahn+nntp@snipabacken.se> - 2015-09-01 20:39 +0000
Re: a style question: jt@toerring.de (Jens Thoms Toerring) - 2015-09-01 20:45 +0000
Re: a style question: Bartc <bc@freeuk.com> - 2015-09-01 22:53 +0100
Re: a style question: Malcolm McLean <malcolm.mclean5@btinternet.com> - 2015-08-31 17:51 -0700
csiph-web