Visual Basic 2008 !

30.11.2007

Okuyucu : 1.402
Günlük Okuyucu : 8,6

Bildiğiniz gibi ben bir Visual Basic insanıyım,  bilmeyenler şimdi "Nasıl yani C# değil mi?" diye bir an için şok olmuş olabilirler, hayır C# değil! Bence C# ve VB aynı Linux ve Windows gibi. Herneyse, bu konu hakkında gerekli geyiği VB.NET mi C mi? konusunda yeterince yapmıştık.

Şimdi Visual Basic blogunu okurken şu harika yazıyı gördüm : Hidden Gems in Visual Basic 2008, Normalde bu tip yazıları okuduklarım' da paylaşıyorum ama bu anasayfayı hakedecek kadar güzel. Visual Basic 2008' deki yeni aksiyonlar, iki tanesi özellikle çok önemli.

Nihayet güzel bir IIF implemantasyonu gelmiş :

Dim intD As Integer = If(intA = intB, intA, intB)

Diğer bir süper yenilik, constructorları daha rahat set edebilmek için :

Dim strm As New StreamWriter( New FileStream("C:\out.txt", FileMode.OpenOrCreate) With {.Position = 10})

Gene de bunlar beni çok kesmedi ben i++, --i vs. yapmak istiyorum.

Yorumlar

RSS Bu makalenin yorumlarını RSS ile takip et!

Linq yu begendin mi peki?
Geri kalan makyajimsi ozellikleri sormuyorum :)

Bu arada vb ve c# olayina gelince biraz takinti yaptigini dusunuyorum. Ben de vb insaniydim fakat C#da daha guzel geldi hala da c#in daha mantikli bir dil oldugunu dusunmeden edemiyorum.

Tuna Toksoz [ # | 30.11.2007 ]

One question we occasionally get is why we didn't introduce C-style increment (++) and decrement (--) operators into the language when we introduced the compound operators (i.e. += and -=). We did consider it, but:

Assignment in VB is always done at the statement level and not the expression level. Introducing a ++ statement and -- statement seemed pretty redundant. If you're going to have "x++" as a statement, why not just use "x += 1"?
If we introduced ++ and -- as assignment expressions, then it would be weird not to allow general assignment expressions. For example, in C#, you can say "if ((x = foo()) == 10) {}" and have the assignment done as part of evaluating the if expression. The problem, as you might have already guessed, is that we already use the = operator in expressions for testing value equality. Thus, there would be no easy way to introduce general assignment expressions into the language, which would make it strange that we had -- and ++.
Even if we ignored the weirdnesses inherent in having increment and decrement with no assignment, the operators' main function in C often times seems to be to encourage programmers to write arcane and brittle code. Besides the confusion in meaning between prefix and postfix, the increment/decrement operators usually depend on the order of evaluation of expressions. Which requires remembering the order of evaluation in a particular language, which isn't always very obvious. For example, in C, what do the following expressions result in? It really depends on the order in which the expressions happen to be evaluated.
a[b++] = ba[b] = ++bfoo(b++, ++b, b++, ++b)
Overall, we felt we were better off just leaving the increment and decrement operators alone.

Tuna Toksoz [ # | 30.11.2007 ]

http://blogs.msdn.com/ericlippert/archive/2004/07/19/why-no.aspx
bu da cok guzel noktalara deginmis. tam interview(mulakat) sorulari gibi :p

Tuna Toksoz [ # | 30.11.2007 ]

Linq yu begendin mi peki?

Henuz kullanmadim hic :) olayi guzel ama bence olumcul bir sey yok, Aktif olarak kullanirsam o zaman herhalde daha verimli yorumlar yapabilirim. Su an sadece etraftaki buzz uzerine konusuyorum.

Bu arada vb ve c# olayina gelince biraz takinti yaptigini dusunuyorum. Ben de vb insaniydim fakat C#da daha guzel geldi hala da c#in daha mantikli bir dil oldugunu dusunmeden edemiyorum.
Takinti yok :) Linkledigim onceki blogumda zaten gorusumu acikladim, burada Windows - Linux olayi gibi demem genelde C# cilar ile konusunca onlarin duruma bakisini ozetlemek icindi.

Ferruh Mavituna [ # | 30.11.2007 ]

http://blogs.msdn.com/ericlippert/archive/2004/07/19/why-no.aspx
Arkadas olayi hakikaten guzel aciklasmis ozellikle bu ozellikle statement expression olayini VB acisindan hic dusunmemsitim. Hakli bir kac yonu var, belki de cok hakli :) Neyse artik eskisi kadar istemiyorum bu ozelligi, Bill amca sana sesleniyorum, artik bu ozelligi koymasan da olur :p

Ferruh Mavituna [ # | 30.11.2007 ]

bence artik c#a gecme vaktin geldi :p

linq ve nhibernate birlesince ozellikle(ado.net entity frameworku sevemedim gitti) cok guzel bir sey ortaya cikiyor. nhibernate'in veritabani bagimsizligi ile linq'nun derleme zamanli kontrolu cok tatli geliyor adama :p

Tuna Toksoz [ # | 30.11.2007 ]

Yorum Ekle





Kullanılabilir Taglar : [<blockquote>] [<strong>] [<em>]

Visual Basic 2008 ! ile İlişkili Olabilecek Yazılar - Haberler

WPF - Windows Presentation Framework Nedir?
Windows Port Knocking Deamon
.NET ile Object Pool
.NET Kaynak Kodlarını Download Etme
Post Build Event

Diğer Yazılar

Neredeyim ?

Ferruh.Mavituna » Haberler » Visual Basic 2008 !

Ferruh Mavituna
© 2002-2007, Ferruh Mavituna

Sabit IP Adresi : 81.22.99.133, SSL Erişimi, Hakkında