Christoph, i'm quite at a loss as to why you would need anything that any particular language doesn't provide. C++ seems to have all it needs for coding major applications, rebol has all it needs for network-oriented scripting applications, ruby has all it needs to be functionally equivalent to nearly all other scripting languages....
if you need to use one obscure and (extremely) rarely-used feature of some extremely obscure language, why do you need to create (or modify) a language that includes those features? after all, such features are so uncommon as it is.
Programming language features
Re:Programming language features
Hi,
As far as Rebol and other special-purpose programming languages are concerned, my general perception has been that these languages in general just provide convenient syntactic sugar for things that other languages would put into libraries (possibly hiding them behind some unwieldly generic syntax).
Don't get me wrong-- I don't want to change or come up with new languages at this point, I just want to examine a couple of language features from a mathematical point of view in my thesis, and try to see how they can (semantically) interact. That's why I'm looking for fresh ideas here-- networked objects, serialization, exceptions, continuations, side effects and slicing all give a lot of motivation for this kind of work, but there may be lots of useful things I'm missing.
-- Christoph
Well, C++ doesn't really have a decent type system, so its usefulness for large-scale applications is somewhat debatable (the fact that large programs have been created in C++ should be contrasted with the general quality of today's software, which, compared to the products of any other discipline considered to be an engineering one, is still, at the very least, embarassing).grey wolf wrote: Christoph, i'm quite at a loss as to why you would need anything that any particular language doesn't provide. C++ seems to have all it needs for coding major applications, rebol has all it needs for network-oriented scripting applications, ruby has all it needs to be functionally equivalent to nearly all other scripting languages....
As far as Rebol and other special-purpose programming languages are concerned, my general perception has been that these languages in general just provide convenient syntactic sugar for things that other languages would put into libraries (possibly hiding them behind some unwieldly generic syntax).
That doesn't mean it's not useful now or in the future. Imagine suggesting networked objects to someone twenty years ago-- you would've been laughed at.grey wolf wrote: if you need to use one obscure and (extremely) rarely-used feature of some extremely obscure language, why do you need to create (or modify) a language that includes those features? after all, such features are so uncommon as it is.
Don't get me wrong-- I don't want to change or come up with new languages at this point, I just want to examine a couple of language features from a mathematical point of view in my thesis, and try to see how they can (semantically) interact. That's why I'm looking for fresh ideas here-- networked objects, serialization, exceptions, continuations, side effects and slicing all give a lot of motivation for this kind of work, but there may be lots of useful things I'm missing.
-- Christoph
Re:Programming language features
well, C/C++ wasn't exactly designed with RTTI in mind. it was just meant to give you hardware.
good luck on your thesis. i wish i could give helpful input.
good luck on your thesis. i wish i could give helpful input.
Re:Programming language features
hmmm this is not about the thread exactly but I found somthing funny about C/C++
when you define:
#define PRN printf("Hello\n"); // see that ';'?
you can type in:
PRN // No Semi-Colen!!! with no errors!
but I think that'd be the source of bugs and mis-types and bad habits. I think that C/C++ should have a protection about that so errors are less.
Is that off-thread or i'm never going to understand what you mean and I shouldn't even post in this thread? ::) ??? :-[
when you define:
#define PRN printf("Hello\n"); // see that ';'?
you can type in:
PRN // No Semi-Colen!!! with no errors!
but I think that'd be the source of bugs and mis-types and bad habits. I think that C/C++ should have a protection about that so errors are less.
Is that off-thread or i'm never going to understand what you mean and I shouldn't even post in this thread? ::) ??? :-[
Re:Programming language features
Well, one thing you have to keep in mind is that, while it is defined alogn with C in the ANSI standard, the preprocessor is {i}not{/i] a part of the language proper. The preprocessor is just what the name implies: a tool which processes parts of the source code, making changes to it, before the text is sent to the compiler. Except for the #pragma statements (which change the option switches sent to the C compiler) , every preprocessor directive has the effect of adding, replacing or removing text in the C source code.Tom wrote: hmmm this is not about the thread exactly but I found somthing funny about C/C++
when you define:
#define PRN printf("Hello\n"); // see that ';'?
you can type in:
PRN // No Semi-Colen!!! with no errors!
but I think that'd be the source of bugs and mis-types and bad habits. I think that C/C++ should have a protection about that so errors are less.
Is that off-thread or i'm never going to understand what you mean and I shouldn't even post in this thread? ::) ??? :-[
In the case of [tt]#define[/tt] statements, what they do is replace the defined label with the exact text that follows (except comments, which the preprocessor removes first) until the end of the line - since they are not C statements themselves, [tt]#define[/tt]s are not closed by semi-colons. (In the case of macros, the parameter labels which appear in the defined string are first replaced with their actual arguments before te label is changed). So, when after the preprocessor is done, what the C compiler sees is
Code: Select all
printf("Hello, World!");
Re:Programming language features
has anyone ever heard of c--? ive only seen one mention of it somewhere, and i forget the source. its supposd to be lower level than c, but higher than asm. but id like a compiler that lets you write in c or c++, but you can inculde a block
asm{
//code here
}
and it would compile that asm code. i think gcc can do this, but i HATE AT&T assembly syntax. i think its so ugly. nasm syntax is nice and clean, and id like a compiler that lets you do wat i said above using nasm sytanx
asm{
//code here
}
and it would compile that asm code. i think gcc can do this, but i HATE AT&T assembly syntax. i think its so ugly. nasm syntax is nice and clean, and id like a compiler that lets you do wat i said above using nasm sytanx
Re:Programming language features
Hi,
-- Christoph
Found the link on Simon Peyton-Jones HP: http://www.cminusminus.org/.elias wrote: has anyone ever heard of c--? ive only seen one mention of it somewhere, and i forget the source. its supposd to be lower level than c, but higher than asm.
-- Christoph