Web Log di Adrian Florea

"You know you've achieved perfection in design, not when you have nothing more to add, but when you have nothing more to take away." Antoine de Saint-Exupery
posts - 440, comments - 2715, trackbacks - 3944

My Links

Archives

Post Categories

Image Galleries

.RO Blogs

.RO People

.RO Sites

Blogs

Furls

Links

vinCitori

Sub New vs. Sub [New] in VB .NET

Nel caso di New in VB .NET, c'è una differenza evidente però magari poco conosciuta tra la variante escaped (sinistra, metodo) e la variante non-escaped (destra, costruttore):

Class Foo
    Sub [New]()
    End Sub
End Class
Class Foo
    Sub New()
    End Sub
End Class
.class private auto ansi Foo
extends [mscorlib]System.Object
{
      .method public specialname rtspecialname instance
      void .ctor() cil managed
      {
            //
      }
 
      .method public instance
      void New() cil managed
      {
            //
      }
}
.class private auto ansi Foo
extends [mscorlib]System.Object
{
      .method public specialname rtspecialname instance
      void .ctor() cil managed
      {
            //
      }
}

Print | posted on martedì 16 agosto 2005 13:14 | Filed Under [ Carillon .NET ]

Powered by:
Powered By Subtext Powered By ASP.NET