• ### Announcements

#### Archived

This topic is now archived and is closed to further replies.

# C# changes

## Recommended Posts

From http://zdnet.com.com/2100-1104-965046.html:
That release of Visual C# will include four new features: support for "generics," which is a form of a C++ template that can help C# developers build software more quickly; support for "iterators," which help developers create new code; anonymous methods, which ease development of what’s known as "event-driven" code; and support for "partial types," which make it easier to use C# for building large projects.

God puts an apple tree in the middle of the Garden of Eden and says, do what you like guys, oh, but don''t eat the apple. Surprise surprise, they eat it and he leaps out from behind a bush shouting "Gotcha." It wouldn''t have made any difference if they hadn''t eaten it... because if you''re dealing with somebody who has the sort of mentality which likes leaving hats on the pavement with bricks under them you know perfectly well they won''t give up. They''ll get you in the end. -- Douglas Adams

##### Share on other sites
Interesting. Signals and slots any time soon, or are we confined to using the .Net framework messaging architecture only?

I guess it''s time to start learning the thing. I still won''t use it until Mono is operational about par, but I''ve got to look to the future...

##### Share on other sites
I think they''re releasing this a bit early. I mean Visual Studio.NET was only released this year, and they''re going to release a new one only a year after? I mean, the features are nice and all that, but it''s times like this I wish I had a Universal MSDN subscription and didn''t have to buy new IDEs whenever they came out..

There was another one there that actually hid some of the text so I had to cut and paste it into notepad just so could see it...

If I had my way, I''d have all of you shot!

codeka.com - Just click it.

##### Share on other sites
The only problem about the genarics and other support is that it won''t be around until late 2003? I think that is when Yukon is going to be released... So learning C# now might help you but if you want to use generics it isn''t available yet... As for iterators they are avalible now, and so is the partial types (although this is "unsafe" code which means the type checker cannot find problems with it...) Anonymous methods? I really don''t know I havent heard about it so I can''t comment on it...

##### Share on other sites
quote:
Original post by djkno3
...learning C# now might help you but if you want to use generics it isn''t available yet...

I already have generics in C++, which I use for my production work right now (alongside a few scripting languages). I don''t need generics in C# now, though others may. I only need it when Mono is stable and usable.

quote:
Anonymous methods? I really don''t know I havent heard about it so I can''t comment on it...

Very very nice Java feature:

  Boolean SomeClass::someMethodThatTakesEventHandler(  ret_type eventHandler( param ) { /* code */ } );

##### Share on other sites
quote:
Original post by Dean Harding
I think they''re releasing this a bit early.

I don''t think we will be seeing this for at least a year yet. See http://msdn.microsoft.com/vstudio/productinfo/roadmap.asp. These changes are scheduled for "Visual Studio for Yukon" - they won''t be in Everett(1.1).

Btw - does anyone have an idea what they mean by "partial types"?

God puts an apple tree in the middle of the Garden of Eden and says, do what you like guys, oh, but don''t eat the apple. Surprise surprise, they eat it and he leaps out from behind a bush shouting "Gotcha." It wouldn''t have made any difference if they hadn''t eaten it... because if you''re dealing with somebody who has the sort of mentality which likes leaving hats on the pavement with bricks under them you know perfectly well they won''t give up. They''ll get you in the end. -- Douglas Adams

##### Share on other sites
partial types has to deal with partially accepted code. Which means that the security access of the program running isn''t really trusted. So if you have a program running from a web application and it trys to call a method from a shared libary unless the library has a specification in it to allow "partial typing" then the program cannot call the method. This is how MS is trying to stop stuff like internet worms/viruses and stuff like that because if the app runs in an "untrusted" context it can''t have access to the normal shared libraries (dll''s). If the library allows access to partial types though you are kinda screwed. By default shared libries have to be "Strongly typed" which means they have the company that made them and such in the properties menu and the system admin can also disallow any "strongly typed" librarys from being shared if they do not have a trusted digital signature (eg from verisign)

##### Share on other sites
I don''t think you need the universal subscription to get the new IDE - I think the next step down gets you that. Doesn''t Universal include all the stuff, like office-dev, BizTalk, etc... or is that something else where you get *everything*.

##### Share on other sites
Yeah, that was probably the one. I''ve already got VS.NET (though it''s the academic version). Here''s hoping...

If I had my way, I''d have all of you shot!

codeka.com - Just click it.

##### Share on other sites
quote:
Original post by djkno3
partial types has to deal with partially accepted code. Which means that the security access of the program running isn't really trusted. So if you have a program running from a web application and it trys to call a method from a shared libary unless the library has a specification in it to allow "partial typing" then the program cannot call the method...

Actually, that is running code under partial trust , which is one of the security features built into the .NET frameworks, and is available now. This is a feature of the runtime, not of the language itself, so it's available to any of the .NET languages.

The new feature being added to C#, partial types, is the ability to seperate types (i.e. classes) across multiple source files.

[edited by - Alias2 on November 9, 2002 5:30:51 AM]

##### Share on other sites
aww crap ok I thought partial typing was allready in the language...

##### Share on other sites

God puts an apple tree in the middle of the Garden of Eden and says, do what you like guys, oh, but don''t eat the apple. Surprise surprise, they eat it and he leaps out from behind a bush shouting "Gotcha." It wouldn''t have made any difference if they hadn''t eaten it... because if you''re dealing with somebody who has the sort of mentality which likes leaving hats on the pavement with bricks under them you know perfectly well they won''t give up. They''ll get you in the end. -- Douglas Adams

##### Share on other sites
Arild-

Also, SQL Server Yukon is going to host the CLR...so (from what I''ve read) you''ll be able to code your SPROCS in C#, et al. Your DB layer could be hosted in the DB itself...obviously the details of implementation, maintainability, and versioning will really determine the feasability of this...but even "just" being able to write complex SPROCS in C# rather than SQL will be a huge advance.

Epolevne

##### Share on other sites
just wanted to post another article on the C# and C++ changes in the upcomming versions (and also explains annon methods).
http://www.devx.com/cplus/Article/9937

• ### Forum Statistics

• Total Topics
627718
• Total Posts
2978793

• 9
• 9
• 21
• 14
• 12