個人檔案J. Daniel Smith相片部落格清單更多 工具 說明

部落格


Another C# 4.0 idea

Several people are starting to post various ideas for C# 4.0 (I'll let you do your own search).
 
Here's mine: allow the base keyword to be used where sealed is used now.  The reason? So that we can begin a transition over several releases to have classes "sealed" by default (or at least forcing you to be specific one way or the other).  In C# 4.0, there would be no change other than allowing base to be used; in the next release (5.0), you would "have" (probalby via compiler warning?) to ise either sealed or base; and in the release after that sealed could become the default.  Heck, I don't know if it's that big of a deal to always have to type either base class or sealed class (or static class), maybe there doesn't need to be a default.
 

Ten Years

I've now been slinging code at the same company for ten years; that's practically an eternity in the software industry.  It's also more than my first two "real jobs" combined, and more than half of my total career.  Wow.
 

Happy 70th Don!

DEK turned 70 yesterday.

nullptr>: A Type-safe and Clear-Cut Null Pointer

 Quote

<i>nullptr</i>: A Type-safe and Clear-Cut Null Pointer

What I think I like best about this is that it will now be even better to be explicit and write if (ptr == nullptr) rather than using an implicit conversion to bool (if (ptr))  This is already the case in C#, it's nice to see C++ heading in that direction too.  I'm not sure if the implict cast will be depricated; probalby not as that would break a lot of code.


 

ISO C++0x: Complete Public Review Draft In October 2007?

 Quote

ISO C++0x: Complete Public Review Draft In October 2007?

You might say that it looks like "x might not be hex."

I'm happy to report that work on "C++0x", the much-anticipated Version 2.0 of the ISO C++ standard, has dramatically picked up steam over the past few months. The ISO C++ committee has now published the first partial draft of C++0x (for what "partial" means and what's still missing, see below), and plans to publish a complete public draft before the end of 2007.

First new "mainstream" language to fully embrace UNICODE?

 http://research.sun.com/projects/plrg/PLDITutorialSlides9Jun2006.pdf

Sun's new "Fortress" programming language (purported by some to be a replacement for FORTRAN) extensively uses UNICODE; it's a whole lot more than just letting variable names use non-ASCII characters; this is source code: http://research.sun.com/projects/plrg/faq/NAS-CG.pdf

Personally, I'm not into a lot of math, so everything doesn't appeal to me.  But I can see how using UNICODE (with TeX-like input for ASCII keyboards) mostly achieves the goal of the language looking similar to what you would write on a white-board. 

Fortress has other interesting parts as well such as loops being multi-threaded by default.

 

 

Microsoft's new codeplex.com

This doesn't instill a lot of confidence:
 
In either IE's warning messages nor Microsoft's ability to design a proper website.
 

Talking Sidebar Gadgets VS Live.com Gadgets

 Quote

Sidebar Geek : Sidebar Gadgets VS Live.com Gadgets

I hope Microsoft finds a way to merge the two types of gadgets; that probably means the sidebar gadgets will have to be more limited (AJAX) so the same thing will work on live.com.

 

Talking about Top Ten of Programming Advice to NOT follow

 Quote

Chryler's Top Ten of Programming Advice to NOT follow

Some interesting comments...not sure I agree with all of them, but it is worthwhile to think about "the conventional wisdom" occasionally.

Talking about: More on Windows DVD Maker

 Quote

Cook Computing: More on Windows DVD Maker

"...why has a fairly small scale app aimed at end-users been written in unmanaged code? ...a new unmanaged app like this gives them more ammunition."

Eric is trying his best to climb out of this tar pit, but it's starting to look like he's stuck. I applaud his candor (he could have dodged this whole issue), and it sounds like he was just doing as he was told when he wrote the UI for DVD Maker in unmanaged code.  Dare tries to help out, but as Charles says, he really misses the point.

However, Implying DVD Maker is part of the OS is really a stretch.  It surely is (or will be) part of the product called "Windows Vista", but hardly means that Vista won't usefully function w/o DVD Maker (or Notepad).  I'll accept that with GUI OS, explorer.exe is "part of the OS", but that's a far cry from DVD Maker.

And "decoupling and reducing dependencies" doesn't really fly either; after all .NET (and WinFX) will ship with Vista!  Now, I'm sure there were scheduling issues with Visual Studio 2005 being so late and the schedule for Vista being reworked.  But those are the same things the rest of us (i.e., developers outside of Microsoft) have had to deal with.

Maybe they wanted stuff that wasn't supported by .NET 1.1--say icons in the menus--but didn't want to depend on VS2005.  Well, guess what?  We want those features too; and what do we do?  Write a bunch of yucky code or use a third-party toolkit.

It sounds like DVD Maker development got caught up in corporate bureaucracy; somebody handed down an edict about not using .NET and the DVD Maker team had little choice in the matter.  If that's the case, it just goes to show that Microsoft is like any other large company.  Nevertheless, it gives the anti-.NET crowd some pretty strong ammunition.

 

 

No more CUJ

The C/C++ Users Journal is done:

Dear C/C++ Users Journal Reader,

For nearly 30 years, the C/C++ Users Journal has provided resources and information to server the constantly evolving community of C and C++ developers.  More recently, however, we at CMP Media LLC have come to the difficult realization that the best way to serve this community in the future is to focus on new web sites, magazines, and events.  What this means is that you are holding in your hands the last issue of the C/C++ Users Journal.  As a result, Dr. Dobb’s Journal, which as published C and C++ articles ranging from the days of Small-C to C++, will expand its coverage of these important programming languages even more.

… We sincerely appreciate your support of C/C++ Users Journal in the past, and we look forward to the opportunity to serer you in the future with timely and useful information about software development.

 

A Brief Look at C++0x

A Brief Look at C++0x

C++0x will hopefully be C++09...that's now three years away.


 

I crashed VC8!

template<typename T> void f1(T t) {

   t+=1;

}

is OK, but replace template with generic

generic<typename T> void f2(T t) {

   t+=1;

}

fatal error C1001: An internal error has occurred in the compiler.

(compiler file 'f:\rtm\vctools\compiler\utc\src\P2\main.c[0x10C746DF:0x50B373E9]', line 182)

To work around this problem, try simplifying or changing the program near the locations listed above.

C#: Future Directions in Language Innovation

 Quote

http://216.55.183.63/pdc2005/slides/TLN307_Hejlsberg.ppt

I think I'm going to really like the local variable type inference.

 

Talking about Does Visual Studio Rot the Mind?

 Quote

Does Visual Studio Rot the Mind?

Interesting comments.  I have a love/hate relationship with IntelliSense too.  And there clearly are problems with the auto-generated code.