|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
http://en.wikipedia.org/wiki/C_Sharp_%28programming_language%29
"C#'s principal designer and lead architect [...] has stated that flaws
in most major programming languages (e.g. C++, Java, Delphi, and
Smalltalk) drove the fundamentals of the CLR, which, in turn, drove the
design of the C# programming language itself."
"Multiple inheritance is not supported, although a class can implement
any number of interfaces."
...so they implemented Java's flawed MI-but-not-MI model? How is that
fixing the flaws from other major programming languages?
Oh, wait... He said that "flaws drove the fundamentals of the design".
So... you designed it to *keep* all the best flaws of other languages? :-D
--
http://blog.orphi.me.uk/
http://www.zazzle.com/MathematicalOrchid*
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Invisible wrote:
> ...so they implemented Java's flawed MI-but-not-MI model? How is that
> fixing the flaws from other major programming languages?
Ever attempted to use multiple inheritance in C++? Things get really
interesting when you have more than one base class, and some members
overlap. I think the :: operator helps keep things relatively straight,
though. There are other issues, of course, such as which copy of the
base class is used when 2 classes share a common base class and are
inherited by a further derived class. (Looks like a diamond on an
inheritance diagram)
> Oh, wait... He said that "flaws drove the fundamentals of the design".
> So... you designed it to *keep* all the best flaws of other languages? :-D
>
Use C# for a while, especially the newer version (3.0) It's actually
quite nice. I've sort of grown to like it since I've started actually
using it. C++ish syntax, some stuff borrowed from Java.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
C# is a strange mix of Delphi's ideas and Java syntax and implementation. The
main designer and his team was bought by M$ from Borland where they worked on
Delphi. In fact, he was also Turbopascal implementer.
BTW, Orchid, you know some major Haskell designers and implementers work for M$,
right? Simon Peyton Jones works at M$ Research, long after he started work on
Haskell. Erik Meijer too. The thing is, many ideas of Haskell, like monadic
IO are present in .NET nowadays in a builtin framework named LINK.
You may find the ideas of Erik Meijer somewhat interesting:
http://research.microsoft.com/~emeijer/Papers/fpca91.pdf
http://research.microsoft.com/~emeijer/
the first paper is interesting, but Meijer is an idiosyncratic personality with
strong opinions. In his view, Haskell is just a scripting language... ;)
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Mike Raiford wrote:
> Invisible wrote:
>
>> ...so they implemented Java's flawed MI-but-not-MI model? How is that
>> fixing the flaws from other major programming languages?
>
> Ever attempted to use multiple inheritance in C++?
No.
Given that I can't handle C and C++ is more complicated, I figured it
was just a bad idea. ;-)
> Things get really
> interesting when you have more than one base class, and some members
> overlap.
Ever tried to use multiple inheritance in Eiffel?
Since I am presumably the only person here who has ever heard of Eiffel,
let me go over it.
Suppose that class A inherits from classes B and C, which themselves
inherit from D. Suppose that D defines an attribute called, say, banana.
That means that B and C each have a copy of banana. In A, these two
copies are automatically merged by default.
Alternatively, you can rename one (or both) copies to something else.
Stop and think about that for a moment.
Suppose I rename the banan from B to banana_b and the other to banana_c.
That means that anybody who tries to access "banana" through the B
interface actually gets banana_b, anybody trying to access "banana"
through the C interface gets banana_c instead, and anybody trying to
access the A interface directly can see two seperate bananas. A similar
thing happens with methods. [Except that you can override both inherited
methods, or rename one, or...]
It's funny really. Eiffel's slogan is "Simple. Elegant. Powerful." That
first is *highly* debatable...
> Use C# for a while, especially the newer version (3.0) It's actually
> quite nice. I've sort of grown to like it since I've started actually
> using it. C++ish syntax, some stuff borrowed from Java.
It sounds like it's fixed a few of the things that makes C and C++ so
impossible. I'm still not sure I'd like it very much. [And I'm certainly
not keen to shell out money to find out.]
--
http://blog.orphi.me.uk/
http://www.zazzle.com/MathematicalOrchid*
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> Since I am presumably the only person here who has ever heard of Eiffel,
> let me go over it.
>
I heard of it. I know some of its features. I have never used it, and
don't even know what the syntax looks like.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Invisible" <voi### [at] devnull> wrote in message
news:47b1c6c2$1@news.povray.org...
>
> It sounds like it's fixed a few of the things that makes C and C++ so
> impossible. I'm still not sure I'd like it very much. [And I'm certainly
> not keen to shell out money to find out.]
You don't have to. There's a free IDE (more than sufficient for trying stuff
out) and the underlying framework and compiler are freely downloadable.
There's more than enough docs, tuts and info on the net that you won't have
to read a book if you don't want to.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Nicolas Alvarez" <nic### [at] gmailisthebestcom> wrote in message
news:47b1c743$1@news.povray.org...
> > Since I am presumably the only person here who has ever heard of Eiffel,
> > let me go over it.
> >
>
> I heard of it. I know some of its features. I have never used it, and
> don't even know what the syntax looks like.
Very much like C++ or Java at a first glance.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
nemesis wrote:
> C# is a strange mix of Delphi's ideas and Java syntax and implementation. The
> main designer and his team was bought by M$ from Borland where they worked on
> Delphi. In fact, he was also Turbopascal implementer.
Mmm, I wonder if C# is any more object-oriented than TP 5.5? ;-)
> BTW, Orchid, you know some major Haskell designers and implementers work for M$,
> right?
*sigh* Yes.
Indeed, everything I mention M$ I get flamed for insulting people's
employer.
Here's the part I can't figure out. M$ basically exists to steal other
people's ideas, pass them off as "new" and "original", and con people
out of huge sums of money for it. So... why is M$ even interested in
something geniunely advanced and revolutionary?
> The thing is, many ideas of Haskell, like monadic
> IO are present in .NET nowadays in a builtin framework named LINK.
Yeah, looking at the Wikipedia page for C# I see they've stolen a whole
crapload of good ideas from Haskell. [No doubt in a few years everybody
will say how C# is the best programming language because of these
features. And Haskell still isn't the best. For the same reason.]
> the first paper is interesting, but Meijer is an idiosyncratic personality with
> strong opinions. In his view, Haskell is just a scripting language... ;)
Oh, sure. It has compilation, strong typing, compile-time error
checking, pervasive optimisation techniques, and an elegant underlying
algebra. Definitely a scripting language. :-P
--
http://blog.orphi.me.uk/
http://www.zazzle.com/MathematicalOrchid*
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Gail Shaw wrote:
>> I heard of it. I know some of its features. I have never used it, and
>> don't even know what the syntax looks like.
>
> Very much like C++ or Java at a first glance.
Er, what?
class
HELLO_WORLD
create
make
feature
make
do
print("Hello, world!%N")
end
end
Sure, looks just like C++ or Java. ;-)
[Actually, I think Pascal would be closer... Unlike certain other
languages, the syntax is more heavy on language keywords than exotic
punctuation.]
--
http://blog.orphi.me.uk/
http://www.zazzle.com/MathematicalOrchid*
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Invisible" <voi### [at] devnull> wrote in message
news:47b1cbd9$1@news.povray.org...
> Gail Shaw wrote:
>
> >> I heard of it. I know some of its features. I have never used it, and
> >> don't even know what the syntax looks like.
> >
> > Very much like C++ or Java at a first glance.
>
> Er, what?
Sorry. Misread. Thought he was talking about C#
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|