Author Topic: C# and other OOP languages  (Read 64228 times)

0 Members and 1 Guest are viewing this topic.

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #75 on: October 09, 2014, 08:56:09 am »
Also, while I appreciate it is not for everyone, complaining that you have to manage types and memory in c++ doesn't make much sense. It is no accident and very specifically designed into the language, because it allows the optimiser to do things that would not be possible in a less strongly typed language.

C++ is an untyped language, in contrast to Java/C# etc. If you don't believe that, then if you look at a chunk of memory and see 0xdeadbeefcafebabe, please tell me with certainty whether that is a pointer, an integer, a car, a bitvector... With Java/C# there is always an associated explicit definition of what it is, a pointer to the class definition.

With C++ you have to be content with saying "I'm going to interpret it as a car, since that's what my code thinks it ought to be".
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #76 on: October 09, 2014, 09:06:03 am »
If you want to write something that is truly fast (linear algebra operations, real time graphics, JIT compiler, etc), pretty much your only choices are c, c++ or assembly. Often a mix of all three are used. I believe Linus Torvolds said that in some cases he optimises down to the point where he is shuffling instructions so that they enter the pipeline in a better order. That's the sort of performance I'm talking about here. If you give up strong types and manual memory management, you can't have that level of control anymore.

...and you have to do it all over again with the next generation of processor. And again. And again.

In contrast Java's HotSpot looks at what code is actually being executed (cf what the compliler can guess in the presence of having be pessimistic because of aliasing), and optimises the shit out of that. And when a new processor comes along, your workload is precisely zero, because HotSpot does it all for you. C# still has the aliasing problem, but does optmise for a specific processor when the assembly is installed. (Probably one reason why Windows updates take soo long to complete :) )

Interestingly when the same HotSpot techniques were applied to C/C++ code they radically improved the speed of  +O2 and +O4 C/C++ code. Even running post-compiled code on an emulation of processor X was as fast or faster than running the code on the same processor X. Look for HP's Dynamo compiler for details.
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 

Offline jeremy

  • Super Contributor
  • ***
  • Posts: 1079
  • Country: au
Re: C# and other OOP languages
« Reply #77 on: October 09, 2014, 09:47:04 am »
Also, while I appreciate it is not for everyone, complaining that you have to manage types and memory in c++ doesn't make much sense. It is no accident and very specifically designed into the language, because it allows the optimiser to do things that would not be possible in a less strongly typed language.

C++ is an untyped language, in contrast to Java/C# etc. If you don't believe that, then if you look at a chunk of memory and see 0xdeadbeefcafebabe, please tell me with certainty whether that is a pointer, an integer, a car, a bitvector... With Java/C# there is always an associated explicit definition of what it is, a pointer to the class definition.

With C++ you have to be content with saying "I'm going to interpret it as a car, since that's what my code thinks it ought to be".

Well, if we are going to get technical there isn't a good definition of what "strongly typed" or "untyped" even means. Ultimately the type system in C is as present as you would like it to be. You can pass around void* for everything if you like, but you are fighting the optimiser.

...

...and you have to do it all over again with the next generation of processor. And again. And again.

Yep, that's the point. Different processors are different? If you wanna squeeze out every last drop, that's what you have to do. And you also need a language to write the JIT compiler in.
 

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #78 on: October 09, 2014, 10:06:39 am »
There is zero possibility that a C++ environment could ever have a decent refactoring browser with "control-space" and "rename this method and all references to this method". Why? Because of the extreme difficulty of accurately parsing C++ source code, particularly when macros (as they always are) are included in the equation.

You should try out VisualAssist. It comes free with Atmel Studio, or can be downloaded as a demo for Visual Studio. It does exactly that kind of refactoring and I use it a lot. Renames a function and all references to it effortlessly. Seems to cope with macros okay.

It's not quite as good as what you get with C#, but it's 80% there most of the time.

So it only gets is wrong 20% of the time? In that case you still have to go and manually inspect all the changes it made, which defeats the purpose.

My point stands.
« Last Edit: October 09, 2014, 10:16:12 am by tggzzz »
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #79 on: October 09, 2014, 10:15:40 am »
Also, while I appreciate it is not for everyone, complaining that you have to manage types and memory in c++ doesn't make much sense. It is no accident and very specifically designed into the language, because it allows the optimiser to do things that would not be possible in a less strongly typed language.

C++ is an untyped language, in contrast to Java/C# etc. If you don't believe that, then if you look at a chunk of memory and see 0xdeadbeefcafebabe, please tell me with certainty whether that is a pointer, an integer, a car, a bitvector... With Java/C# there is always an associated explicit definition of what it is, a pointer to the class definition.

With C++ you have to be content with saying "I'm going to interpret it as a car, since that's what my code thinks it ought to be".

Well, if we are going to get technical there isn't a good definition of what "strongly typed" or "untyped" even means. Ultimately the type system in C is as present as you would like it to be. You can pass around void* for everything if you like, but you are fighting the optimiser.

Just so. But regarding C/C++ as strongly typed (or even typed) is getting dangerously close to unhelpful Humpty-Dumpty speak, viz. "When I use a word it means just what I choose it to mean — neither more nor less."

Quote
...

...and you have to do it all over again with the next generation of processor. And again. And again.

Yep, that's the point. Different processors are different? If you wanna squeeze out every last drop, that's what you have to do. And you also need a language to write the JIT compiler in.

The point is that such mechanical operations should (almost always) be left to robots, so that humans can concentrate on things that robots are incapable of doing. Humans should choose whatever mechanisms techniques and tools enable robots to take more drudgery off their hands. That's why HLLs have almost completely replaced assembly and macrocode languages. And why HDLs have replaced fuse maps.
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 

Offline nctnico

  • Super Contributor
  • ***
  • Posts: 26891
  • Country: nl
    • NCT Developments
Re: C# and other OOP languages
« Reply #80 on: October 09, 2014, 11:04:01 am »
Most of what makes C# a step up is the environment and the rapid UI tools around it.
Perhaps but then you are locked into a Windows environment forever. There are plenty of RAD tools for QT and WxWidgets which don't have that problem.

There is zero possibility that a C++ environment could ever have a decent refactoring browser with "control-space" and "rename this method and all references to this method". Why? Because of the extreme difficulty of accurately parsing C++ source code, particularly when macros (as they always are) are included in the equation.
Eclipse CDT does refactoring in C++ just fine. I'm using it every once in a while.
« Last Edit: October 09, 2014, 11:12:39 am by nctnico »
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #81 on: October 09, 2014, 11:44:33 am »
There is zero possibility that a C++ environment could ever have a decent refactoring browser with "control-space" and "rename this method and all references to this method". Why? Because of the extreme difficulty of accurately parsing C++ source code, particularly when macros (as they always are) are included in the equation.
Eclipse CDT does refactoring in C++ just fine. I'm using it every once in a while.

Perhaps you are only using it for "simple cases", maybe the "easy 80%"?

C++ is a real pig to parse correctly. Looking at various usenet newsgroups inhabited by people who have worked with C/C++ for decades and who also serve on various standardisation committees, even they have unresolved difficulties sometimes! If you need a language lawyer to determine the interpretation, then I can probably find another language lawyer to provide a differing and equally valid interpretation :( Not good.
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 

Offline _Sin

  • Regular Contributor
  • *
  • Posts: 247
  • Country: gb
Re: C# and other OOP languages
« Reply #82 on: October 09, 2014, 12:07:25 pm »
There is zero possibility that a C++ environment could ever have a decent refactoring browser with "control-space" and "rename this method and all references to this method". Why? Because of the extreme difficulty of accurately parsing C++ source code, particularly when macros (as they always are) are included in the equation.
Eclipse CDT does refactoring in C++ just fine. I'm using it every once in a while.

Perhaps you are only using it for "simple cases", maybe the "easy 80%"?

C++ is a real pig to parse correctly. Looking at various usenet newsgroups inhabited by people who have worked with C/C++ for decades and who also serve on various standardisation committees, even they have unresolved difficulties sometimes! If you need a language lawyer to determine the interpretation, then I can probably find another language lawyer to provide a differing and equally valid interpretation :( Not good.

Your original assertion was that there was 'zero' chance of an IDE doing 'decent' refactoring. Sadly 'decent' is subjective so you can always argue that it doesn't meet your personal definition and be 'right', but for most reasonable people an implementation that works in the majority of cases they ever meet would qualify just fine.

You can actually do some pretty cool things by coupling an IDE with a modern C++ front-end like Clang.

Which is not to say that other languages don't lend themselves better to this sort of thing, but I think you're being disingenuous with regard to what you can actually do with C++ these days.

Programmer with a soldering iron - fear me.
 

Offline HackedFridgeMagnet

  • Super Contributor
  • ***
  • Posts: 2028
  • Country: au
Re: C# and other OOP languages
« Reply #83 on: October 09, 2014, 12:21:45 pm »
Quote
In Java, a 32 bit integer requires 192 bits of memory. In c++, a 32 bit integer requires 32 bits of memory. See https://blogs.oracle.com/jrose/entry/fixnums_in_the_vm

Pretty sure 'int' is 32 bit. It probably takes 32 bits of memory.
'Integer' is a class derived from object, this is why is it bigger.
'integer' doesn't exist in Java.

I think the only fair comparison is with Java 'int'.

 

Offline jeremy

  • Super Contributor
  • ***
  • Posts: 1079
  • Country: au
Re: C# and other OOP languages
« Reply #84 on: October 09, 2014, 12:33:22 pm »
Quote
In Java, a 32 bit integer requires 192 bits of memory. In c++, a 32 bit integer requires 32 bits of memory. See https://blogs.oracle.com/jrose/entry/fixnums_in_the_vm

Pretty sure 'int' is 32 bit. It probably takes 32 bits of memory.
'Integer' is a class derived from object, this is why is it bigger.
'integer' doesn't exist in Java.

I think the only fair comparison is with Java 'int'.

Don't you at least need to expose it to the mark/sweep garbage collector? And any reference to the integer (a pointer) would take up some space in RAM, since it's location can't be known at compile time I think (is there compile time in java? just JIT time and runtime I think).

I don't think the comparison is fair between C++ int and Java int because, for instance, you can't put a Java int in a collection, but you can put a C++ int in a std::vector or std::map just fine.

But Java is not my strong suit, so I'm happy to give you the benefit of the doubt ;)
 

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #85 on: October 09, 2014, 02:12:22 pm »
There is zero possibility that a C++ environment could ever have a decent refactoring browser with "control-space" and "rename this method and all references to this method". Why? Because of the extreme difficulty of accurately parsing C++ source code, particularly when macros (as they always are) are included in the equation.
Eclipse CDT does refactoring in C++ just fine. I'm using it every once in a while.

Perhaps you are only using it for "simple cases", maybe the "easy 80%"?

C++ is a real pig to parse correctly. Looking at various usenet newsgroups inhabited by people who have worked with C/C++ for decades and who also serve on various standardisation committees, even they have unresolved difficulties sometimes! If you need a language lawyer to determine the interpretation, then I can probably find another language lawyer to provide a differing and equally valid interpretation :( Not good.

Your original assertion was that there was 'zero' chance of an IDE doing 'decent' refactoring. Sadly 'decent' is subjective so you can always argue that it doesn't meet your personal definition and be 'right', but for most reasonable people an implementation that works in the majority of cases they ever meet would qualify just fine.

You can actually do some pretty cool things by coupling an IDE with a modern C++ front-end like Clang.

Which is not to say that other languages don't lend themselves better to this sort of thing, but I think you're being disingenuous with regard to what you can actually do with C++ these days.

Only to some extent.

To me "decent" starts with "gets it right all the time without omissions or other mistakes". Anything less is a mere semi-random permutation of my source code - which most people would regard as unacceptable.

And I'm presuming that the programmer is using all the facilities in the C++ language, not a small convenient subset.
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #86 on: October 09, 2014, 02:19:16 pm »
Quote
In Java, a 32 bit integer requires 192 bits of memory. In c++, a 32 bit integer requires 32 bits of memory. See https://blogs.oracle.com/jrose/entry/fixnums_in_the_vm

Pretty sure 'int' is 32 bit. It probably takes 32 bits of memory.
'Integer' is a class derived from object, this is why is it bigger.
'integer' doesn't exist in Java.

I think the only fair comparison is with Java 'int'.

Don't you at least need to expose it to the mark/sweep garbage collector?

No you don't. When an "int" in memory then it is part of an object defined by a class, and only that object visible to the GC. Since the GC knows the objects fields, it avoids treating an int as a pointer.

Quote
I don't think the comparison is fair between C++ int and Java int because, for instance, you can't put a Java int in a collection, but you can put a C++ int in a std::vector or std::map just fine.

You can have many "ints" inside an object (e.g. an Array object or a user defined object) and each int only occupies 32 bits. The containing object has its own single class reference, of course.
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 

Offline miguelvp

  • Super Contributor
  • ***
  • Posts: 5550
  • Country: us
Re: C# and other OOP languages
« Reply #87 on: October 09, 2014, 02:23:39 pm »
Every tool can be misused, it's not a problem with the tool but the operator handling the tool.

Like _Sin mentions give Clang a try it's been C++11 feature complete since over a year and a half and C++14 feature complete since last year. And developed by people paid to do so.

Even enums can be strongly typed.
 

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #88 on: October 09, 2014, 03:01:42 pm »
Quote
It's not quite as good as what you get with C#, but it's 80% there most of the time.

So it only gets is wrong 20% of the time?

No, it only has 80% of the features. C just doesn't do things like reflection or allow things like immediate execution. It's actually incredibly accurate, sometimes I can write a few lines of code just by pressing tab.

"Control-space" (=tab, I presume) is an incredible powerful feature. In Java it enables you to explore code easily by asking questions such as "given that object, what is the exhaustive list of things could I do with it" - and you can reliably do that without executing any of your code.

In contrast reflection and immediate execution are "only" relevant in executing programs.
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 

Offline jeremy

  • Super Contributor
  • ***
  • Posts: 1079
  • Country: au
Re: C# and other OOP languages
« Reply #89 on: October 10, 2014, 06:52:07 am »
I don't think the comparison is fair between C++ int and Java int because, for instance, you can't put a Java int in a collection, but you can put a C++ int in a std::vector or std::map just fine.

You can have many "ints" inside an object (e.g. an Array object or a user defined object) and each int only occupies 32 bits. The containing object has its own single class reference, of course.

Right, but not in a generic container or user defined templated object. You can't store an int in a Vector without it being boxed to an Integer. See http://mindprod.com/jgloss/intvsinteger.html and http://illegalargumentexception.blogspot.fr/2008/08/java-int-versus-integer.html

Unless that has changed recently. Pretty sure I couldn't last year when I did some android work.
 

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #90 on: October 10, 2014, 08:07:58 am »
I don't think the comparison is fair between C++ int and Java int because, for instance, you can't put a Java int in a collection, but you can put a C++ int in a std::vector or std::map just fine.

You can have many "ints" inside an object (e.g. an Array object or a user defined object) and each int only occupies 32 bits. The containing object has its own single class reference, of course.

Right, but not in a generic container or user defined templated object. You can't store an int in a Vector without it being boxed to an Integer. See http://mindprod.com/jgloss/intvsinteger.html and http://illegalargumentexception.blogspot.fr/2008/08/java-int-versus-integer.html
Unless that has changed recently. Pretty sure I couldn't last year when I did some android work.

Correct, and it hasn't changed. But the context of this subthread has been snipped: that a 32bit int occupies 192bits. And that's incorrect since you can't have a "naked" int in memory, and adding an int to an existing class only adds 32bits of memory.
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 

Offline jeremy

  • Super Contributor
  • ***
  • Posts: 1079
  • Country: au
Re: C# and other OOP languages
« Reply #91 on: October 10, 2014, 08:11:13 am »
I don't think the comparison is fair between C++ int and Java int because, for instance, you can't put a Java int in a collection, but you can put a C++ int in a std::vector or std::map just fine.

You can have many "ints" inside an object (e.g. an Array object or a user defined object) and each int only occupies 32 bits. The containing object has its own single class reference, of course.

Right, but not in a generic container or user defined templated object. You can't store an int in a Vector without it being boxed to an Integer. See http://mindprod.com/jgloss/intvsinteger.html and http://illegalargumentexception.blogspot.fr/2008/08/java-int-versus-integer.html
Unless that has changed recently. Pretty sure I couldn't last year when I did some android work.

Correct, and it hasn't changed. But the context of this subthread has been snipped: that a 32bit int occupies 192bits. And that's incorrect since you can't have a "naked" int in memory, and adding an int to an existing class only adds 32bits of memory.

Fair enough, but I originally meant Integer (as in the boxed type) not the primitive because you can't use the primitive and have everything work.

My point was that by using only the primitive int, you lose some of the standard library in Java. For using a primitive int in C++, you don't lose templating or containers.
« Last Edit: October 10, 2014, 08:13:24 am by jeremy »
 

Offline miguelvp

  • Super Contributor
  • ***
  • Posts: 5550
  • Country: us
Re: C# and other OOP languages
« Reply #92 on: October 10, 2014, 08:29:25 am »
From: http://www.techrepublic.com/article/the-geekiest-tech-jokes-on-the-internet/?tag=nl.e101&s_cid=e101&ttag=e101&ftag=TRE684d531

Quote
...

8. Why do Java developers wear glasses? Because they can't C#

...

17. "Knock, knock. Who's there?"
very long pause...
"Java."

18. If you put a million monkeys on a million keyboards, one of them will eventually write a Java program. The rest of them will write Perl programs.

...

My favorite one from that link:

Quote
13. I would tell you a UDP joke, but you might not get it.
 

Offline SirNick

  • Frequent Contributor
  • **
  • Posts: 589
Re: C# and other OOP languages
« Reply #93 on: October 10, 2014, 08:44:53 pm »
Better than those people that tell TCP jokes, then go "get it?  get it?  get it?" until you say "YES.  I GOT IT."
 

Offline miguelvp

  • Super Contributor
  • ***
  • Posts: 5550
  • Country: us
Re: C# and other OOP languages
« Reply #94 on: October 10, 2014, 10:53:23 pm »
Better than those people that tell TCP jokes, then go "get it?  get it?  get it?" until you say "YES.  I GOT IT."

Be careful not to SLIP while you PPP, get it? get it? get it?  >:D

Made that one up myself long ago and it used to be my signature on usenet, or was it "when you PPP" don't recall.
Funny you can't find it even in Google and not everything is invented, but how will use SLIP or PPP? maybe mobile phones?
 

Offline nctnico

  • Super Contributor
  • ***
  • Posts: 26891
  • Country: nl
    • NCT Developments
Re: C# and other OOP languages
« Reply #95 on: October 10, 2014, 11:09:12 pm »
AFAIK mobile phones still use PPP to get internet access. A couple of years ago I built a tablet with 3G modem and I had to use PPP over a serial port to get internet from the 3G modem.
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #96 on: October 10, 2014, 11:27:02 pm »
I don't think the comparison is fair between C++ int and Java int because, for instance, you can't put a Java int in a collection, but you can put a C++ int in a std::vector or std::map just fine.

You can have many "ints" inside an object (e.g. an Array object or a user defined object) and each int only occupies 32 bits. The containing object has its own single class reference, of course.

Right, but not in a generic container or user defined templated object. You can't store an int in a Vector without it being boxed to an Integer. See http://mindprod.com/jgloss/intvsinteger.html and http://illegalargumentexception.blogspot.fr/2008/08/java-int-versus-integer.html
Unless that has changed recently. Pretty sure I couldn't last year when I did some android work.

Correct, and it hasn't changed. But the context of this subthread has been snipped: that a 32bit int occupies 192bits. And that's incorrect since you can't have a "naked" int in memory, and adding an int to an existing class only adds 32bits of memory.

Fair enough, but I originally meant Integer (as in the boxed type) not the primitive because you can't use the primitive and have everything work.

My point was that by using only the primitive int, you lose some of the standard library in Java. For using a primitive int in C++, you don't lose templating or containers.

I'm prepared to lose that, since the reason that is lost is to ensure all sorts of pains, errors, nightmares are also lost :)

Personally I'd prefer the int/Integer thing to have been "inverted", as it was in Smalltalk 33 years ago. Then, in effect, everything was an Integer but there was a hidden optimisation that small integers were invisibly, silently and transparently optimised to ints (and ditto back to Integers when they grew larger). But that isn't going to happen.

As for templates, as far as I can tell (since I gave up on C++ before they existed), the combination of templates and exceptions results in some very non-entertaining compiler error messages and core dumps. It always struck me as remarkably bad that C++ took so long to get container classes, when other contemporary languages had fully-fledged variants available from the first release.

There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 

Offline vvanders

  • Regular Contributor
  • *
  • Posts: 124
Re: C# and other OOP languages
« Reply #97 on: October 11, 2014, 04:54:09 am »
Most of what makes C# a step up is the environment and the rapid UI tools around it.
Perhaps but then you are locked into a Windows environment forever. There are plenty of RAD tools for QT and WxWidgets which don't have that problem.
QT I buy but wxWidgets? Eargh, I've spent many years working with it(not much recently) and it's the opposite of RAD.

There is zero possibility that a C++ environment could ever have a decent refactoring browser with "control-space" and "rename this method and all references to this method". Why? Because of the extreme difficulty of accurately parsing C++ source code, particularly when macros (as they always are) are included in the equation.
Eclipse CDT does refactoring in C++ just fine. I'm using it every once in a while.
At the risk of kicking off another religious debate Eclipse is a horrible IDE, poorly intuitive, buggy as all hell(doesn't detect file changes in win32). That said I've yet to see VS(>2012) misparse any autocomplete, and that's in some very complex codebases some near the million loc size.
 

Offline nctnico

  • Super Contributor
  • ***
  • Posts: 26891
  • Country: nl
    • NCT Developments
Re: C# and other OOP languages
« Reply #98 on: October 11, 2014, 10:17:29 am »
I don't share your vision on Eclipse. Maybe you looked at a very early version 10 years ago but the current version detects file changes just fine. It does take some getting used to Eclipse because it has been setup for dealing with huge projects consisting of many sub-projects. It is therefore more complicated than Visual Studio. But once you get the hang of it, it works really well. It makes big spaghetti projects like the Linux kernel or a huge VHDL project managable.
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline tggzzz

  • Super Contributor
  • ***
  • Posts: 19468
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: C# and other OOP languages
« Reply #99 on: October 11, 2014, 11:10:36 am »
I don't share your vision on Eclipse. Maybe you looked at a very early version 10 years ago but the current version detects file changes just fine. It does take some getting used to Eclipse because it has been setup for dealing with huge projects consisting of many sub-projects. It is therefore more complicated than Visual Studio. But once you get the hang of it, it works really well. It makes big spaghetti projects like the Linux kernel or a huge VHDL project managable.
I'll second that, and I have never seen the problems mentioned by vvanders.

I cannot comment on VS, since I've only used that for one tiny program.
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf