469,341 Members | 7,261 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,341 developers. It's quick & easy.

c# is a good way to learn c


After working in c# for a year, the only conclusion I can come to is
that I wish I knew c.

All I need is Linux, the gnu c compiler and I can do anything.

Web services are just open sockets hooked up to interfaces.

The Gtk is more than enough gui.

Jul 21 '05
354 13587
In article <Pe********************@comcast.com>, =?iso-8859-1?Q?
li*********@bone.com says...
Back By Demand poked his little head through the XP firewall and said:
Yahoo! is written in c on BSD.

Google is written in c on linux.

Microsoft Office is built with it's own compiler -- not .NET, not VC++.

Even the companies that create these "platforms" don't use their own
stuff to create these platforms.


I thought Jim McCarthy (MS C++ team leader years ago and author of "The
Dynamics of Software Development") said that Microsoft ate its own dog-food?

Is what you said about MS Office true about all of their software?


It wasn't even true about Office - at least when I wrote some code for
Exchange Server in 1997-1998 that was also incorporated in Office. At
that time Office, as well as Exchange Server, used the stock MS Visual
C++ version 6 compiler. In fact, at one point, the Exchange Server team
"ate its own dogfood" by using a beta version of the Visual C++ compiler
to help out the compiler development team. Some Exchange developers
also used the stock MS Visual C++ IDE for editing though I personally
used CodeWright.
--
"There are 10 kinds of people in the world:
those that understand binary and those that don't." - Unknown
Jul 21 '05 #201
"Jeff_Relf" <Me@Privacy.NET> wrote in message
news:Je***********************@Cotse.NET...

Hi Hederman, Sorry about the late reply,
Re: typedef unsigned __int8 * uint_8_P ;
__int32 Swap_32 ( __int32 X ) { uint_8_P P = ( uint_8_P ) & X + 4 ;
return * -- P << 24 | * -- P << 16 | * -- P << 8 | * -- P ; }

You wrote: << Ummm, actually it does nothing of the sort.
Swapping the high and low bytes of the number 32 gives me 536870912,
and your result is 538976288. >>

Ever heard of Hex ? 0x81828384 is a better test.
As I've since said in a later post to you,
the code above doesn't work because of a bug in MS_CPP_7_1.
What is that bug exactly?
Re: My comment that I've held the same job since mid 1993,
and if you're record was as good.

You replied: << Nope, been headhunted 4 times in that period though. >>

Hmmm... so that's it then, you don't code anything yourself,
you're just a salesman who takes credit for the work of others.
Ummm, actually I was headhunted *because* of my code.
You wrote: << Coding is my sole means of support,
has been since I left varsity, and I live a very comfortable life,
if that's what you're asking. >>

What do you mean by coding ?
Pounding keys or pounding beers with clients ? I think the latter.

Re: #define LOOP while ( 1 )
#define Loop( N ) int J = - 1, LLL = N ; while ( ++ J < LLL )

You asked me: << Um, and having LOOP and Loop defined ?
You don't think that's a bad idea ?
Look, if you want to write BASIC, it's much easier just
to get a BASIC compiler than to try to #define C++ into it. >>

I have no problems differentiating between LOOP and Loop(),
LOOP in fact, does what it does in Modula-2, an early OOP language.
I know Modula-2 well thanks. If you want to write Modula-2 then do so. My
point about the differentiating on casing is not whether *you* understand it
or not, but whether anyone else might get confused. It seems a brilliant
example of deliberately trying to confuse a casual reader.
I never used Basic,
but Basic is what started MicroSoft, I'd never talk ill of it.
Strange, you #define C to be like Basic/Modula-2 and then you say you don't
like Basic. A little cognitive dissonance there I see.
You asked me: << You honestly believe that drek is readable ?
No comments, spaghetti code,
#define abuse that should be criminal, and non-semantic variable names.
>>

Yes, my code is the Most readible.


Hah!
Learning anyone's code is hard, and few, especially you,
are willing to spend more than a few seconds to learn it,
so your opinions carry no weight.


I shouldn't have to spend hours poring over your code to find out what it
does. Good code is more like an essay. Clear, commented, and well laid out.
Yours is quite clearly none of those things.
Jul 21 '05 #202
"Jeff_Relf" <Me@Privacy.NET> wrote in message
news:Je***********************@Cotse.NET...
Hi Sean_Hederman, Sorry about my late reply,
but there are only so many hours in a day, ya know.

The following code Should work in MS_CPP_7_1,
but it doesn't due to a ( ¿ unreported ) bug in MS_CPP_7_1:
Report it then.

[Snip] As for your:
int swapped = System.Net.IPAddress.NetworkToHostOrder( unswapped );

X.CPP does it like this:
Host_IP.sin_port = htons( Port = Serv->Port );

But that's not what I'd use to convert a .WAV file.
At any rate, it was just a trivial quiz.

By the way, you keep insisting that I care only about fast code,
and I keep insisting that I care only about results.
Code is what it does. Are you projecting ? I imagine so.
You've obviously never worked in a team environment.
As for your claim that my examples aren't readable,
...I won't be blamed for your lack of effort.


Code should *not* require an effort. It should be easy, well commented and
concise, except in the few occasions when a performance analysis has found
an area requiring optimization. In that case, it should be even more well
commented. It should not attempt to make use of strange #defines that change
the structure of the language.

Oh, and chrisv, I agree wholeheartedly with you about Jeff, so...

Cheers Jeff.

And no, I'm not running away, it's not worth my time to try and educate
someone without the ability to see their mistakes. Carry on in your happy
world, assured that you're the greatest programmer the world has ever seen.
And those of us who can actually write *useful* and easily maintainable
programs will continue to get better jobs, whilst you sit in your safe
little 13 year tenure.

*plonk*
Jul 21 '05 #203
"Linønut" <"=?iso-8859-1?Q?lin=F8nut?="@bone.com> wrote in message
news:Pe********************@comcast.com...
Back By Demand poked his little head through the XP firewall and said: [Snip]
Microsoft Office is built with it's own compiler -- not .NET, not VC++.

Even the companies that create these "platforms" don't use their own
stuff to create these platforms.


I thought Jim McCarthy (MS C++ team leader years ago and author of "The
Dynamics of Software Development") said that Microsoft ate its own
dog-food?


They do, but not neccesarily other divisions dog-food. So, for example, VC++
is compiled in VC++, and much of the .NET Framework is written in .NET. IIRC
the Office compiler does compile itself. I'm also pretty sure that I read
that they either have ported or are going to port Office to VC++.
Is what you said about MS Office true about all of their software?

--
When all you have is a hammer, everything looks like a nail.
When all you have is Microsoft software, everything looks like Windows.

Jul 21 '05 #204

Hi Greg_Cox ( and Linonut ), Re: If MS_Office had it's own compiler,
Ya writ: << It wasn't even true about Office - at least when I wrote some
code for Exchange Server in 1997-1998 that was also incorporated in Office.
At that time Office, as well as Exchange Server,
used the stock MS Visual C++ version 6 compiler.
In fact, at one point, the Exchange Server team
" ate its own dogfood " by using a beta version
of the Visual C++ compiler to help out the compiler development team.
Some Exchange developers also used the stock MS Visual C++ IDE
for editing though I personally used CodeWright. >>

Thanks for clearing that up for me,
there's been much confusion on that topic.

What do you like about CodeWright's debugger ? Editor ?

Jul 21 '05 #205
Craftsman attached to his tools?
If you were a real craftsman you'd know how to use the appropriate tool for
each task you encounter.
C# is an excellent language for most desktop application and infact using
the .NET framework saves you alot of time in the process.
If you are working on real-time application you will probably require more
system control and use C++.
You want full control? use assembler...

Funny thing is, 10 years ago there were assembly developers talking about C
and C++ the same way you take about C#...

--
Eran Kampf
http://www.ekampf.com/blog
http://www.ekampf.com
"Jeff_Relf" <Me@Privacy.NET> wrote in message
news:Je***********************@Cotse.NET...

Hi Hederman, Re: What to do when C# fails you, You told me: <<
Report it as a bug and/or write your own high-level routine
using low-level C# ( i.e. unsafe code/interop/pinvoke )
just like you would in any programming language. >>

Ha, ha, ha ! ! Without #define ? Not a chance. I wouldn't do it.

Re: My comment that C#'s high level routines are compromises,
where people say: A-a-aw, hell, it's good enough, I'll just go with it.

You replied: << Really ?
Which of the developers of those libraries told you that ? >>

What ! ? You think I can't reject code that I didn't write ?

Re: My comment that C, with it's #define, has stood the test of time,
and will continue to do so long after C# is forgotten,

You told me: << I thought the quality of code was independent of the
language.
I can write better code in VB.NET than many people can in C++.
The best language for the job depends on the job,
and frankly I've written business systems in many languages,
and I've found C# to be more than adequate for the job,
and it gives me more productivity than C++. >>

Are you overseeing the coders, or is it you there... twiddling the bits ?
I think it's the former.

I never said that VB.NET wasn't useful to many,
I'm just saying it's not the optimal solution, it's not a tool I'd ever
use.

You asked me: << Please, do you really believe that
the more experienced you are the more you tie yourself to one solution ?
Are you trying to assert that
C# developers by definition have less experience than C++ developers ?
Keep in mind that many C# developers come from a C++ background.
I'd say that having a religious devotion to one programming language
is the surest sign of a developers immaturity,
not which language they happen to use. >>

Not being a craftsman yourself,
you don't understand the attachment he gets for his tools.
You don't tell Picasso what type of paint to use.

Jul 21 '05 #206
Jeff_Relf wrote:
Hi Greg_Cox ( and Linonut ), Re: If MS_Office had it's own compiler,
Ya writ: << It wasn't even true about Office - at least when I wrote some
code for Exchange Server in 1997-1998 that was also incorporated in Office.
At that time Office, as well as Exchange Server,
used the stock MS Visual C++ version 6 compiler.
In fact, at one point, the Exchange Server team
" ate its own dogfood " by using a beta version
Sounds like the next step is for these groups to write Office in c#.

Thanks for clearing that up for me.
of the Visual C++ compiler to help out the compiler development team.
Some Exchange developers also used the stock MS Visual C++ IDE
for editing though I personally used CodeWright. >>

Thanks for clearing that up for me,
there's been much confusion on that topic.

What do you like about CodeWright's debugger ? Editor ?

Jul 21 '05 #207
Greg Cox wrote:
It wasn't even true about Office - at least when I wrote some code for
Exchange Server in 1997-1998 that was also incorporated in Office. At
that time Office, as well as Exchange Server, used the stock MS Visual
C++ version 6 compiler. In fact, at one point, the Exchange Server team
"ate its own dogfood" by using a beta version of the Visual C++ compiler
to help out the compiler development team. Some Exchange developers
also used the stock MS Visual C++ IDE for editing though I personally
used CodeWright.


There should be plenty of people at M$ right now working to port
everything to .Net/Indigo and so on then...making all their products in c#
Jul 21 '05 #208
Greg Cox wrote:
"ate its own dogfood" by using a beta version of the Visual C++ compiler
to help out the compiler development team. Some Exchange developers
also used the stock MS Visual C++ IDE for editing though I personally
used CodeWright.


http://www.winsupersite.com/showcase...go_preview.asp

Office .NET Revealed?
Is Office NGO really the next version of Office?

A number of readers alerted me this week to a fascinating Shockwave
animation that purports to demonstrate some of the online/subscription
features of the next version of Microsoft Office, which will be called
Office .NET. Code-named Office NGO ("Next Generation Office") in the
animation, this Office version will include links to a number of of
online services, including a secure My Office Web site; a consolidated
email account with Web-based Inbox; Office .NET Notifications; online
scheduling with a sharable calendar; Meeting Workspaces for viewing
agendas, pending tasks, and related documents, SharePoint Team
Services-based Team Workspace for sharing information with team members;
and a set of online content such as templates, online training,
communities, and the like.
Jul 21 '05 #209
Jeff_Relf wrote:
Hi Hederman, Re: What to do when C# fails you, You told me: <<
Report it as a bug and/or write your own high-level routine
using low-level C# ( i.e. unsafe code/interop/pinvoke )
just like you would in any programming language. >>

Ha, ha, ha ! ! Without #define ? Not a chance. I wouldn't do it.

Re: My comment that C#'s high level routines are compromises,
where people say: A-a-aw, hell, it's good enough, I'll just go with it.

You replied: << Really ?
Which of the developers of those libraries told you that ? >>
Jeff,

Your code is fat and wasteful.

Check this out:

#include <stdio.h>

main(t,_,a)
char *a;
{return!0<t?t<3?main(-79,-13,a+main(-87,1-_,
main(-86, 0, a+1 )+a)):1,t<_?main(t+1, _, a ):3,main ( -94, -27+t, a
)&&t == 2 ?_<13 ?main ( 2, _+1, "%s %d %d\n" ):9:16:t<0?t<-72?main(_,
t,"@n'+,#'/*{}w+/w#cdnr/+,{}r/*de}+,/*{*+,/w{%+,/w#q#n+,/#{l,+,/n{n+\
,/+#n+,/#;#q#n+,/+k#;*+,/'r :'d*'3,}{w+K w'K:'+}e#';dq#'l q#'+d'K#!/\
+k#;q#'r}eKK#}w'r}eKK{nl]'/#;#q#n'){)#}w'){){nl]'/+#n';d}rw' i;# ){n\
l]!/n{n#'; r{#w'r nc{nl]'/#{l,+'K {rw' iK{;[{nl]'/w#q#\
n'wk nw' iwk{KK{nl]!/w{%'l##w#' i; :{nl]'/*{q#'ld;r'}{nlwb!/*de}'c \
;;{nl'-{}rw]'/+,}##'*}#nc,',#nw]'/+kd'+e}+;\
#'rdq#w! nr'/ ') }+}{rl#'{n' ')# }'+}##(!!/")
:t<-50?_==*a ?putchar(a[31]):main(-65,_,a+1):main((*a == '/')+t,_,a\
+1 ):0<t?main ( 2, 2 , "%s"):*a=='/'||main(0,main(-61,*a, "!ek;dc \
i@bK'(q)-[w]*%n+r3#l,{}:\nuwloca-O;m .vpbks,fxntdCeghiry"),a+1);}

What ! ? You think I can't reject code that I didn't write ?

Re: My comment that C, with it's #define, has stood the test of time,
and will continue to do so long after C# is forgotten,

You told me: << I thought the quality of code was independent of the language.
I can write better code in VB.NET than many people can in C++.
The best language for the job depends on the job,
and frankly I've written business systems in many languages,
and I've found C# to be more than adequate for the job,
and it gives me more productivity than C++. >>

Are you overseeing the coders, or is it you there... twiddling the bits ?
I think it's the former.

I never said that VB.NET wasn't useful to many,
I'm just saying it's not the optimal solution, it's not a tool I'd ever use.

You asked me: << Please, do you really believe that
the more experienced you are the more you tie yourself to one solution ?
Are you trying to assert that
C# developers by definition have less experience than C++ developers ?
Keep in mind that many C# developers come from a C++ background.
I'd say that having a religious devotion to one programming language
is the surest sign of a developers immaturity,
not which language they happen to use. >>

Not being a craftsman yourself,
you don't understand the attachment he gets for his tools.
You don't tell Picasso what type of paint to use.

Jul 21 '05 #210
tab
>Big deal. They sound like doofuses. They problem don't even know how
to
use the STL. You could probably beat them just as well if you used straightC.


In your dreams you one language twit.

Jul 21 '05 #211
tab
>C#'s high level routines are compromises, where people say:
A-a-aw, hell, it's good enough, I'll just go with it.


You are a guy that wants to debate which flavor M & M tastes better.
You think "your way" is the BEST way. I am the guy cleaning up your
death march project that failed, and trashing your crap that took
10 times as long to code, with 30X more bugs,

I guess you live in a world were money is flowing like a river into
your department, and can spend decades getting that crap to work.

Jul 21 '05 #212
"Eran Kampf" <er**@ekampf.com> wrote in message
news:uV**************@tk2msftngp13.phx.gbl...
Craftsman attached to his tools?
If you were a real craftsman you'd know how to use the appropriate tool
for each task you encounter.
C# is an excellent language for most desktop application and infact using
the .NET framework saves you alot of time in the process.
If you are working on real-time application you will probably require more
system control and use C++.
You want full control? use assembler...

Funny thing is, 10 years ago there were assembly developers talking about
C and C++ the same way you take about C#...


Hear, hear! And in 1959 there were people talking that way about Fortran.

BTW, I have no idea about telling Picasso what kind of paint to use. But
Leonardo da Vinci, a much greater artist, eagerly tested any kind of paint
he could get his hands on. As I recall, frescoes came out of his
experiments, or were much improved by them.
Jul 21 '05 #213
>Leonardo da Vinci, a much greater artist,
Is that opinion? fact? general consensus? blind guess? ...

--
Regards,
Alvin Bruney - ASP.NET MVP

[Shameless Author Plug]
The Microsoft Office Web Components Black Book with .NET
Now available @ www.lulu.com/owc
"Michael A. Covington" <lo**@ai.uga.edu.for.address> wrote in message
news:em**************@TK2MSFTNGP09.phx.gbl...
"Eran Kampf" <er**@ekampf.com> wrote in message
news:uV**************@tk2msftngp13.phx.gbl...
Craftsman attached to his tools?
If you were a real craftsman you'd know how to use the appropriate tool
for each task you encounter.
C# is an excellent language for most desktop application and infact using
the .NET framework saves you alot of time in the process.
If you are working on real-time application you will probably require
more system control and use C++.
You want full control? use assembler...

Funny thing is, 10 years ago there were assembly developers talking about
C and C++ the same way you take about C#...


Hear, hear! And in 1959 there were people talking that way about Fortran.

BTW, I have no idea about telling Picasso what kind of paint to use. But
Leonardo da Vinci, a much greater artist, eagerly tested any kind of paint
he could get his hands on. As I recall, frescoes came out of his
experiments, or were much improved by them.

Jul 21 '05 #214

"Alvin Bruney [MVP - ASP.NET]" <www.lulu.com/owc> wrote in message
news:Od**************@tk2msftngp13.phx.gbl...
Leonardo da Vinci, a much greater artist,

Is that opinion? fact? general consensus? blind guess? ...


Opinion, of course, but widely held among art historians. I've just asked
my wife, who has a degree in art.
Jul 21 '05 #215

Linønutlinønu*@bone.com wrote:
Alex poked his little head through the XP firewall and said:
"Tukla Ratte" <tu*********@tukla.net> wrote in message news:m2************@stitch.tukla.net...
After all, COBOL is still being used for a lot of new development.


Source?


I don't have any source myself, but google for "Visual COBOL". Or
"object-oriented COBOL".


There is a bit of a difference between "still exists" and "still being
used for *a lot* of new development" (emphasis mine).

I am not aware of any signifigant amout of *new* development done in
COBOL.
Of course, maintenance is a whole different story.

Jul 21 '05 #216

The Ghost In The Machine wrote:
Don't take my word for it, c.l.c++.m (see above) is
a great resource - you have Stroustrup, Sutter,
Alexandrescu and their peers actively participating
in discussions there and offering ego-less advice.


Do they do STL in there?


Is the pope catholic?

Jul 21 '05 #217
In article <Je***********************@Cotse.NET>, Me@Privacy.NET says...

Hi Greg_Cox ( and Linonut ), Re: If MS_Office had it's own compiler,
Ya writ: << It wasn't even true about Office - at least when I wrote some
code for Exchange Server in 1997-1998 that was also incorporated in Office.
At that time Office, as well as Exchange Server,
used the stock MS Visual C++ version 6 compiler.
In fact, at one point, the Exchange Server team
" ate its own dogfood " by using a beta version
of the Visual C++ compiler to help out the compiler development team.
Some Exchange developers also used the stock MS Visual C++ IDE
for editing though I personally used CodeWright. >>

Thanks for clearing that up for me,
there's been much confusion on that topic.

What do you like about CodeWright's debugger ? Editor ?


I used CodeWright for many years simply because I loved how it allowed
me to completely customize the keyboard and write custom commands in C.
One of the things I used most was a copy/cut/paste that was columnar
instead of stream based. With a simple mouse click I could copy the
text in columns 20-34 of lines 200-300 and paste them in columns 30-44
of lines 410-510. It's amazing how often I used that functionality. It
also allowed me to easily create and use on-the-fly macros. I ended up
with a keyboard map so customized nobody but me could use it...

I'm unfamiliar with a debugger by them so I can't comment.
--
"There are 10 kinds of people in the world:
those that understand binary and those that don't." - Unknown
Jul 21 '05 #218
In article <p7********************@speakeasy.net>, ro***@trower.rocks
says...
Jeff_Relf wrote:
Hi Greg_Cox ( and Linonut ), Re: If MS_Office had it's own compiler,
Ya writ: << It wasn't even true about Office - at least when I wrote some
code for Exchange Server in 1997-1998 that was also incorporated in Office.
At that time Office, as well as Exchange Server,
used the stock MS Visual C++ version 6 compiler.
In fact, at one point, the Exchange Server team
" ate its own dogfood " by using a beta version


Sounds like the next step is for these groups to write Office in c#.


I'm not sure what that would get them. You're talking about hundreds of
thousands to millions of lines of existing C/C++ code. Why would they
want to dump that and start over?
--
"There are 10 kinds of people in the world:
those that understand binary and those that don't." - Unknown
Jul 21 '05 #219
"Michael A. Covington" <lo**@ai.uga.edu.for.address> wrote in message
news:uz**************@TK2MSFTNGP12.phx.gbl...

"Alvin Bruney [MVP - ASP.NET]" <www.lulu.com/owc> wrote in message
news:Od**************@tk2msftngp13.phx.gbl...
>Leonardo da Vinci, a much greater artist,

Is that opinion? fact? general consensus? blind guess? ...


Opinion, of course, but widely held among art historians. I've just asked
my wife, who has a degree in art.


I should add that I asked her what the experts think, not what she thinks...
Jul 21 '05 #220

Hi Greg_Cox, Re: CodeWright, You wrote: <<
I'm unfamiliar with a debugger by them so I can't comment. >>

You used MicroSoft's debugger then, I assume, MS_DevStudio... Right ?
( or Visual_Studio )

Visual_Studio_Net_2003 allows On_The_Fly macros,
I hit F7 to start/stop recording and then F8 to play it.
The so_called quick_Macro can then be edited, if I want,
to create a VBA script ( to assign it to a key or toolbar icon ).

Holding down the Alt and the Shift keys and then moving the text cursor
( via the mouse or keys ) allows me to select a block of text,
....instead of sequential characters.

You can assign a name to your keybindings file, I call mine Key_Bindings.VSK
Below is the .BAT file I use to save off my Visual_Studio settings.
Save_Setngs.BAT:

C:
cd "C:\Documents and Settings\Owner\Application Data\Microsoft\VisualStudio\7.1"
REM Must exit VS to save CmdUI.PRF and Key_Bindings.VSK

XCopy /Y /F 1033\CmdUI.PRF F:\VS
XCopy /Y /F Key_Bindings.VSK F:\VS
XCopy /Y /F devenv.xml F:\VS
XCopy /Y /F "C:\__\Visual Studio Projects\VSMacros71\MyMacros\__.vsmacros" F:\VS
XCopy /Y /F C:\__\X\VS.REG F:\VS
XCopy /Y /F C:\__\X\VS.VB F:\VS
XCopy /Y /F C:\__\X\Save_Setngs.BAT F:\VS
XCopy /Y /F C:\__\X\Restore_Setngs.BAT F:\VS
XCopy /Y /F C:\__\X\Bit_Stream.TTF F:\VS

Pause

REM More info at:
REM http://blogs.msdn.com/jledgard/archi.../05/67869.aspx

Below is how I restore them to another machine, when I have the privileges.
Restore_Setngs.BAT:

XCopy /Y /F CmdUI.PRF "C:\Documents and Settings\BLab-242\Application Data\Microsoft\VisualStudio\7.1\1033"

REM Key_Bindings must be selected by hand.

XCopy /Y /F "Key_Bindings.VSK" "C:\Documents and Settings\BLab-242\Application Data\Microsoft\VisualStudio\7.1"
XCopy /Y /F devenv.xml "C:\Documents and Settings\BLab-242\Application Data\Microsoft\VisualStudio\7.1"
XCopy /Y /F __.vsmacros "C:\__\Visual Studio Projects\VSMacros71\MyMacros\__.vsmacros"
rem XCopy /Y /F __.vsmacros "C:\Documents and Settings\blab-242\My Documents\Visual Studio Projects\VSMacros71\MyMacros\__.vsmacros"
VS.REG

Pause

Jul 21 '05 #221
Alex O. wrote:
I am not aware of any signifigant amout of *new* development done in
COBOL.
Of course, maintenance is a whole different story.


That is because like every other fool around here, you have no idea what
runs corporate information systems...your only schooling is the PC
sandbox, so you assume that IIS and Sql Server actually do any real work.
http://www.infogoal.com/cbd/cbdhome.htm
Jul 21 '05 #222
Greg Cox wrote:

I'm not sure what that would get them. You're talking about hundreds of
thousands to millions of lines of existing C/C++ code. Why would they
want to dump that and start over?


LOL.

Ok, so then that argument applies to each and every application that
might consider .NET
Jul 21 '05 #223
Alvin Bruney [MVP - ASP.NET] wrote:
Leonardo da Vinci, a much greater artist,


Is that opinion? fact? general consensus? blind guess? ...


exactly...Da Vinci was a loser most of whose 'inventions' were to crappy
to be built or work right.

Jul 21 '05 #224
Look guys, if this clown can't stop trolling could you at least stop
responding to his idiocy? Perhaps he'll get bored and go away...
--
http://www.kynosarges.de
Jul 21 '05 #225
Yes it does.

Anyone who suggested to a company to take their existing application that is fit for purpose and completely rewrite millions of lines of code *purely* so it runs on .NET should be shot.

However, often existing applicaiton reach the end of the road (maybe the business it weas built have changed and the architecture can't support the new requirements without a substantial rewrite) and become due a rewrite naturally or large sectrions of it anyway. So a more common case is for a full or partial rewrite to occur then.

Also completely new requirements of projects emerge and these get written in managed code.

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk

Greg Cox wrote:

I'm not sure what that would get them. You're talking about hundreds of
thousands to millions of lines of existing C/C++ code. Why would they
want to dump that and start over?


LOL.

Ok, so then that argument applies to each and every application that
might consider .NET

[microsoft.public.dotnet.languages.csharp]
Jul 21 '05 #226

Hi Rose_Mountain, Easy one, Rose_Mountain.CPP prints: <<
On the first day of Christmas my true love gave to me
a partridge in a pear tree. ... >>

Only I'd write it like this:
#include <stdio.h>
FILE * fp ;

Recurse ( int t, int _, char * a ) {
return
1 < t
? t < 3
? Recurse ( -79, -13, a + Recurse( -87, 1 - _
, Recurse ( -86, 0, a + 1 ) + a ) )
: 1, t < _
? Recurse ( t + 1, _, a )
: 3 , Recurse ( -94, -27 + t, a ) && t == 2
? _ < 13
? Recurse ( 2, _+ 1, "%s %d %d\n" )
: 9
: 16
: t < 0
? t < -72
? Recurse ( _, t,
"@n'+,#'/*{}w+/w#cdnr/+,{}r/*de}+,/*{*+,/w{%+,/w#q#n+,/#{l,+,/n{n+"
",/+#n+,/#;#q#n+,/+k#;*+,/'r :'d*'3,}{w+K w'K:'+}e#';dq#'l q#'+d'K"
"#!/+k#;q#'r}eKK#}w'r}eKK{nl]'/#;#q#n'){)#}w'){){nl]'/+#n';d}rw' i"
";# ){nl]!/n{n#'; r{#w'r nc{nl]'/#{l,+'K {rw' iK{;[{nl]'/w#q#n'wk "
"nw' iwk{KK{nl]!/w{%'l##w#' i; :{nl]'/*{q#'ld;r'}{nlwb!/*de}'c "
";;{nl'-{}rw]'/+,}##'*}#nc,',#nw]'/+kd'+e}+;"
"#'rdq#w! nr'/ ') }+}{rl#'{n' ')# }'+}##(!!/" )
: t < -50
? _ == * a
? fwrite ( a + 31, 1, 1, fp )
: Recurse ( -65, _, a + 1 )
: Recurse ( ( * a == '/' ) + t, _, a + 1 )
: 0 < t
? Recurse ( 2, 2 , "%s")
: * a == '/'
|| Recurse ( 0
, Recurse ( -61, * a
, "!ek;dc i@bK'(q)-[w]*%n+r3#l,{}:\nuwloca-O;"
"m .vpbks,fxntdCeghiry" ), a + 1 ); }

main() { fp = fopen( "AA.TXT","w"); Recurse ( 1, 0, "" ); fclose(fp); }

Jul 21 '05 #227

Hi Montie, You imagined: << There should be plenty of people at M$ right now
working to port everything to .Net/Indigo and so on,
...making all their products in c# >>

Right... and there should be trees that grow hundred dollar bills too.

I can see it now:
DOS_Prompt_> Mono MS_Word.EXE

That's just never going to happen.

Jul 21 '05 #228

Hi Eran_Kampf, Re: How I won't use C# because it doesn't have #define,
You told me: << Funny thing is, 10 years ago there were assembly developers
talking about C and C++ the same way you take about C#. >>

C++ is as high_level as I want it to be because I can always add a DLL.

But C#, with it's Program_Inside_a_Program, lack of #define
and UnGodly_Bloat are a straightjacket I refuse to wear.

Jul 21 '05 #229
"Lee Marvin" <th*@professionals.is.a.cool.movie> wrote in message
news:Yu********************@speakeasy.net...
Alvin Bruney [MVP - ASP.NET] wrote:
Leonardo da Vinci, a much greater artist,


Is that opinion? fact? general consensus? blind guess? ...


exactly...Da Vinci was a loser most of whose 'inventions' were to crappy
to be built or work right.


Da Vinci is regarded as one of the greatest geniuses of all time. When they
try to figure out the IQ's of historical figures based on their works, the
estimate for Leonardo's is consistently off the charts. He came up with
inventions that were so far ahead of their time, that often the reason they
didn't work was the materials available to him. Recently a group of
scientits built a spring loaded car that he designed. It worked. He produced
the first robot, designs for helicopters (wouldn't work), gliders (would
work), machine guns, tanks (built recently & worked), and a submarine. He
was able to write both normally and in mirror-writing. He was one of the
worlds most accomplished artists ever, and was regarded as a master of
anatomy.

All this in 1452-1519, 486 years ago. Here's a challenge, why don't you come
up with *one* feasible design that will only be possible to built in 2491AD,
and that would be in common use then?

http://en.wikipedia.org/wiki/Leonardo_Da_Vinci
Jul 21 '05 #230
"Christoph Nahr" <ch************@kynosarges.de> wrote in message
news:8k********************************@4ax.com...
Look guys, if this clown can't stop trolling could you at least stop
responding to his idiocy? Perhaps he'll get bored and go away...
Yep, already killfiled him.
http://www.kynosarges.de

Jul 21 '05 #231
"Richard Blewett [DevelopMentor]" <ri******@NOSPAMdevelop.com> wrote in
message news:uD**************@TK2MSFTNGP10.phx.gbl...
Anyone who suggested to a company to take their existing application that
is fit for purpose
and completely rewrite millions of lines of code *purely* so it runs on
.NET should be shot.


No! Such a strategy would involve murdering hundreds of thousand of the
PHB's who religiously jump on the latest bandwagon...

....

....

Um, okay.

Can I be one of the executioners? Should we do this en-masse, or one at a
time? The efficient part of me says all at once, but I really, really,
really want to see the whites of their eyes.

"Decided to migrate a perfectly good mainframe app to Java, AFTER Y2K"
*bang!*
"Switched development platform 3 times before development was complete"
*Bang!*
"Decided that development tools choice is a marketing function" *BANG!*
*BANG!!* <machine gun fire> <mortar fire>
"Wants the desktop graphics editing tool to 'implement SOA'" <artillery,
tanks, thousand of Gurkhas shouting>
"Wants to rewrite Windows-only product in C++ from .NET so 'we can be
cross-platform' when no customers/potential customers want this" <nuclear
strike> -> this one happened to me, so I'm a bit twitchy.
"Wants to write internal system with complex screens and rich UI
requirements in one honking big ASPX with no purchased controls, in 5 days"
<armageddon> -> also happened to me :-(
Jul 21 '05 #232
So why are you posting here?

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk

Hi Eran_Kampf, Re: How I won't use C# because it doesn't have #define,
You told me: << Funny thing is, 10 years ago there were assembly developers
talking about C and C++ the same way you take about C#. >>

C++ is as high_level as I want it to be because I can always add a DLL.

But C#, with it's Program_Inside_a_Program, lack of #define
and UnGodly_Bloat are a straightjacket I refuse to wear.
[microsoft.public.dotnet.languages.csharp]
Jul 21 '05 #233
begin virus.scr Richard Blewett [DevelopMentor] wrote:
So why are you posting here?


Because Relf is an idiot. He consistently posts his windows-only garbage in
a linux group
Jul 21 '05 #234
>> Sounds like the next step is for these groups to write Office in c#.

I'm not sure what that would get them. You're talking about hundreds of
thousands to millions of lines of existing C/C++ code. Why would they
want to dump that and start over?

My guess is more security, and one code executable that runs on 64 bit, 32
bit, Itanium,....
Also .NET programs are far more modular in design and thus easier to change.

But it won't happen overnight.
Jul 21 '05 #235
That's good enough for me.

--
Regards,
Alvin Bruney - ASP.NET MVP

[Shameless Author Plug]
The Microsoft Office Web Components Black Book with .NET
Now available @ www.lulu.com/owc
"Michael A. Covington" <lo**@ai.uga.edu.for.address> wrote in message
news:Oq**************@TK2MSFTNGP12.phx.gbl...
"Michael A. Covington" <lo**@ai.uga.edu.for.address> wrote in message
news:uz**************@TK2MSFTNGP12.phx.gbl...

"Alvin Bruney [MVP - ASP.NET]" <www.lulu.com/owc> wrote in message
news:Od**************@tk2msftngp13.phx.gbl...
>Leonardo da Vinci, a much greater artist,
Is that opinion? fact? general consensus? blind guess? ...


Opinion, of course, but widely held among art historians. I've just
asked my wife, who has a degree in art.


I should add that I asked her what the experts think, not what she
thinks...

Jul 21 '05 #236
Well I did promise to do the C++ test to see what would be the difference
in code generated by C#+JIT and unmanaged C++ for you function.
My prediction would be that it would come close to the unmanaged C++ and
here is what I found. So the myh that C# would create less performant code
than C++ because of the virtual machine is now proven to be incorrect.

Losing perfomance is probably not caused by C# itself but the liraries used
and the way how the programs are designed.
I don't know about the Mono compilers, I don't have it to test it.
Personal tests suggests that my C# programs are about 5% slower than
unmanaged C++ programs, but my user interface is far more rich, so that
could explain the loss of speed. Also there is a psychological impression
that C# programs are slower because they load slower. The loading is slower
because of the JIT that compiles the code and doe ssecurity checks. bu once
loaded it is fast.

This is the C++ version (not optimized since I have the standard edition
which has no optimizing). But with my understanding of assembler I predict
that the optimized code would still look very close to what we have here
because it is already very optimized.
Both the C# and C++ are compiled with VStudio 2003 standard.edition

#define byte unsigned char
int iOriginal=0x01234567;
int iSwapped=(((byte) iOriginal)) << 24 | ((byte) (iOriginal >> 8)) << 16 |
((byte) (iOriginal >> 16)) << 8 | ((byte) (iOriginal >> 24));

Generates assembler like this:

00000011 mov eax,esi
00000013 and eax,0FFh
00000018 shl eax,18h
0000001b mov edx,esi
0000001d sar edx,8
00000020 and edx,0FFh
00000026 shl edx,10h
00000029 or eax,edx
0000002b mov edx,esi
0000002d sar edx,10h
00000030 and edx,0FFh
00000036 shl edx,8
00000039 or eax,edx
0000003b mov edx,esi
0000003d sar edx,18h
00000040 and edx,0FFh
00000046 or eax,edx
00000048 mov edi,eax

As you remember (my previous post) the C# version that got compiled to ILASm
,and later from ILAsm to real processor instructions by the JIT did create
this:

iOriginal=iOriginal;
int swapped=(((byte) iOriginal)) << 24 | ((byte) (iOriginal >> 8)) << 16 |
((byte) (iOriginal >> 16)) << 8 | ((byte) (iOriginal >> 24));

00000090 mov eax,esi // eax=iOriginal
00000092 and eax,0FFh // (byte) iOriginal (converting int to byte)
00000097 shl eax,18h // (byte) iOriginal<< 24
0000009a mov edx,esi // edx=iOriginal
0000009c sar edx,8 // iOriginal >> 8
0000009f and edx,0FFh // ((byte) (iOriginal >> 8))
000000a5 shl edx,10h // ((byte) (iOriginal >> 8)) << 16
000000a8 or eax,edx // ((byte) iOriginal)) << 24 | ((byte)
// (iOriginal >> 8)) << 16
000000aa mov edx,esi // edx=iOriginal
000000ac sar edx,10h // iOriginal >> 16
000000af and edx,0FFh // ((byte) (iOriginal >> 16))
000000b5 shl edx,8 // ((byte) (iOriginal >> 16)) << 8
000000b8 or eax,edx // ((byte) iOriginal)) << 24 | ((byte)
// (iOriginal >> 8)) << 16 |
// ((byte) (iOriginal >> 16)) <<
8
000000ba mov edx,esi // edx=iOriginal
000000bc sar edx,18h // iOriginal >> 24
000000bf and edx,0FFh // ((byte) (iOriginal >> 24)
000000c5 or eax,edx // ((byte) iOriginal)) << 24 | ((byte)
//(iOriginal >> 8)) << 16 |
// ((byte) (iOriginal >> 16))
<< 8 |
//((byte) (iOriginal >> 24)
000000c7 mov ebx,eax // copy to the swap variable.

Have a nice day. :-)
Jul 21 '05 #237
Michael A. Covington wrote:
"Eran Kampf" <er**@ekampf.com> wrote in message
news:uV**************@tk2msftngp13.phx.gbl...
Craftsman attached to his tools?
If you were a real craftsman you'd know how to use the appropriate tool
for each task you encounter.
C# is an excellent language for most desktincorporatedon and infact using
the .NET framework saves you alot of time in the process.
If you are working on real-time application you will probably require
more system control and use C++.
You want full control? use assembler...

Funny thing is, 10 years ago there were assembly developers talking about
C and C++ the same way you take about C#...


Hear, hear! And in 1959 there were people talking that way about Fortran.

BTW, I have no idea about telling Picasso what kind of paint to use. But
Leonardo da Vinci, a much greater artist, eagerly tested any kind of paint
he could get his hands on. As I recall, frescoes came out of his
experiments, or were much improved by them.


Fresco is rather older than that, the Romans used to use it. Leonardo had
no training in fresco painting, which is why he experimented instead of
using more traditional techniques. One of the least successful experiments
of his career. Frescos are amongst the most durable forms of painting, as
the pigments are incorporated in the plaster as it drys. Some of them even
survived Pompeii. But Leonardo's were painted on the wall in layers, and
were showing serious decomposition in less than 20 years.
--
Regards,
Jim
Jul 21 '05 #238
Jeff_Relf wrote:
Hi Montie, You imagined: << There should be plenty of people at M$ right now
working to port everything to .Net/Indigo and so on,
...making all their products in c# >>

Right... and there should be trees that grow hundred dollar bills too.

I can see it now:
DOS_Prompt_> Mono MS_Word.EXE

That's just never going to happen.


Beagle which is written in mono will the be the desktop search standard.

So, yes, it will.

Jul 21 '05 #239
tab poked his little head through the XP firewall and said:
C#'s high level routines are compromises, where people say:
A-a-aw, hell, it's good enough, I'll just go with it.


You are a guy that wants to debate which flavor M & M tastes better.
You think "your way" is the BEST way. I am the guy cleaning up your
death march project that failed, and trashing your crap that took
10 times as long to code, with 30X more bugs,


What exaggeration!

Especially where you seem to claim that you can clean up any kind of
project.

--
When all you have is a hammer, everything looks like a nail.
When all you have is Microsoft software, everything looks like Windows.
Jul 21 '05 #240
tab poked his little head through the XP firewall and said:
Big deal. They sound like doofuses. They problem don't even know how

to
use the STL. You could probably beat them just as well if you used

straight
C.


In your dreams you one language twit.


Is that supposed to be a reasoned response?

Or did you wake up today with a wild hair?

--
When all you have is a hammer, everything looks like a nail.
When all you have is Microsoft software, everything looks like Windows.
Jul 21 '05 #241
In article <Yu********************@speakeasy.net>,
th*@professionals.is.a.cool.movie says...
Greg Cox wrote:

I'm not sure what that would get them. You're talking about hundreds of
thousands to millions of lines of existing C/C++ code. Why would they
want to dump that and start over?


LOL.

Ok, so then that argument applies to each and every application that
might consider .NET


That might be true if Microsoft hadn't released a .NET version of Visual
C++. With that they can immediately reuse 95%+ of the existing code
base and integrate any desired .NET features for the next version.
--
"There are 10 kinds of people in the world:
those that understand binary and those that don't." - Unknown
Jul 21 '05 #242
In article <42***********************@news.skynet.be>,
ob******@skynet.be says...
Sounds like the next step is for these groups to write Office in c#.


I'm not sure what that would get them. You're talking about hundreds of
thousands to millions of lines of existing C/C++ code. Why would they
want to dump that and start over?

My guess is more security, and one code executable that runs on 64 bit, 32
bit, Itanium,....
Also .NET programs are far more modular in design and thus easier to change.

But it won't happen overnight.


So how far along this road would you get by just switching your project
from using Microsoft's Visual C++ 6.x to their Visual C++ .NET dev
environment (like Office would be doing)?
--
"There are 10 kinds of people in the world:
those that understand binary and those that don't." - Unknown
Jul 21 '05 #243
In article <Je************************@Cotse.NET>, Me@Privacy.NET
says...

Hi Greg_Cox, Re: CodeWright, You wrote: <<
I'm unfamiliar with a debugger by them so I can't comment. >>

You used MicroSoft's debugger then, I assume, MS_DevStudio... Right ?
( or Visual_Studio )
Correct, except when we had to debug Windows itself, then we used the
kernel debugger. While we were developing Exchange Server we were also
taking weekly drops of what would become Win2k Server from the Windows
dev team. I NEVER want to go through that again. What a nightmare...

Visual_Studio_Net_2003 allows On_The_Fly macros,
I hit F7 to start/stop recording and then F8 to play it.
The so_called quick_Macro can then be edited, if I want,
to create a VBA script ( to assign it to a key or toolbar icon ).

Holding down the Alt and the Shift keys and then moving the text cursor
( via the mouse or keys ) allows me to select a block of text,
...instead of sequential characters.


I'll have to remember both of those. Thanks.

--
"There are 10 kinds of people in the world:
those that understand binary and those that don't." - Unknown
Jul 21 '05 #244
>> My guess is more security, and one code executable that runs on 64 bit,
32
bit, Itanium,....
Also .NET programs are far more modular in design and thus easier to
change.

But it won't happen overnight.


So how far along this road would you get by just switching your project
from using Microsoft's Visual C++ 6.x to their Visual C++ .NET dev
environment (like Office would be doing)?

I don't think they will rewrite from scratch.
They probably start creating the new stuff in C#/managed C++ as they build
while keeping their original code.
Probably the parts that are securety sensitive and Internet related word
could be rewritten or t leas ported to .NET way of doing.
And gradually when people get more and more experienced with the .NET way,
more code will be ported als older unmanaged C++ gets replaced by new
people.

In my opinion, it will take a few years before completing the stuff.
The new .NET version should have at lease the same functionality als the
previous one, so it is not something you write in a short time.
Jul 21 '05 #245
"Relf" ? is this a backhanded reference to a 60's guitarist ?

"chrisv" <ch****@nospam.invalid> wrote in message
news:mo********************************@4ax.com...
Lee Jackson wrote:
Guess what Jeff? I dont care either.

PLONK!


Good move. That's all the Relf troll deserves, the antisocial prick
that he is.

It never ceases to amaze, how more people are always coming-along to
feed the troll, to tell him his quoting sucks, to tell him that his
cross-posting sucks, to tell him his coding sucks, etc, as if they
think they're the first person to inform the troll that he sucks.

Jul 21 '05 #246
Olaf Baeyens wrote:
In my opinion, it will take a few years before completing the stuff.
The new .NET version should have at lease the same functionality als the
previous one, so it is not something you write in a short time.


The real issue is that the new Web oriented technologies such as .NET
make the Office concept of monolithic desktop apps obsolete.

Notepad, Thunderbird and Firefox serve 99.9% of both the home and
business user.
Jul 21 '05 #247
In article <42*********************@news.skynet.be>, ob******@skynet.be
says...
My guess is more security, and one code executable that runs on 64 bit,
32
bit, Itanium,....
Also .NET programs are far more modular in design and thus easier to
change.

But it won't happen overnight.


So how far along this road would you get by just switching your project
from using Microsoft's Visual C++ 6.x to their Visual C++ .NET dev
environment (like Office would be doing)?

I don't think they will rewrite from scratch.
They probably start creating the new stuff in C#/managed C++ as they build
while keeping their original code.
Probably the parts that are securety sensitive and Internet related word
could be rewritten or t leas ported to .NET way of doing.
And gradually when people get more and more experienced with the .NET way,
more code will be ported als older unmanaged C++ gets replaced by new
people.

In my opinion, it will take a few years before completing the stuff.
The new .NET version should have at lease the same functionality als the
previous one, so it is not something you write in a short time.


Given my eighteen years at Microsoft as direct experience, what you
describe sounds very likely how they will move Office into the future.

--
"There are 10 kinds of people in the world:
those that understand binary and those that don't." - Unknown
Jul 21 '05 #248
Greg Cox poked his little head through the XP firewall and said:
That might be true if Microsoft hadn't released a .NET version of Visual
C++. With that they can immediately reuse 95%+ of the existing code
base and integrate any desired .NET features for the next version.


Yeah, the same you can can "integrate" C code into C++ projects.

--
When all you have is a hammer, everything looks like a nail.
When all you have is Microsoft software, everything looks like Windows.
Jul 21 '05 #249
In article <p4********************@comcast.com>, =?iso-8859-1?Q?
li*********@bone.com says...
Greg Cox poked his little head through the XP firewall and said:
That might be true if Microsoft hadn't released a .NET version of Visual
C++. With that they can immediately reuse 95%+ of the existing code
base and integrate any desired .NET features for the next version.


Yeah, the same you can can "integrate" C code into C++ projects.


Well, yea. What do you think C++ is? Or, in other words, do you think
that the formula handling code in Excel that is written in C++ has to be
completely rewritten to make Excel .NET compatable?
--
"There are 10 kinds of people in the world:
those that understand binary and those that don't." - Unknown
Jul 21 '05 #250

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

7 posts views Thread by tada991 | last post: by
22 posts views Thread by Ramzy Darwish | last post: by
11 posts views Thread by Sam | last post: by
269 posts views Thread by Montrose... | last post: by
15 posts views Thread by Alex L Pavluck | last post: by
6 posts views Thread by Jamiil | last post: by
5 posts views Thread by vinnie | last post: by
reply views Thread by Purva khokhar | last post: by
1 post views Thread by haryvincent176 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.