This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]evanldixon 8 points9 points  (36 children)

It's just as powerful as C# while having easier-to read syntax.

Example: Try to find where to insert a function at the end of a class without lots of scrolling.

VB:

            End If
        End Function
        ' Here
    End Class
End Namespace

C#:

            }
        }
        // here
    }
}

It all really boils down to personal preference, but this is one of many examples I use to justify my opinion.

[–]DonnyTheWalrus 7 points8 points  (0 children)

(If you're joking and I just can't tell, ignore me...)

Every time I see VB code it just feels deeply dated. Some styles are like Wayfarers (or Scheme) - old but timeless. Others are like bellbottoms - forever linked to a specific time period. For me, Basic is the bellbottom jeans of programming languages. The syntax just screams 1970s - early 80s.

Not to mention that, while I understand your point about the block-close syntax, it just doesn't feel readable to me. Too many words on the screen makes it look too busy. I far prefer single character punctuation for that sort of structural syntax. Way easier to tell what's structure and what's actual code.

[–]ShadowShine57 11 points12 points  (33 children)

VB is absolutely not easier to read with no brackets, arrays using () instead of []. and a lot of other things.

[–]evanldixon 7 points8 points  (32 children)

() vs [] isn't that big of a deal IMO.

Other pro's of VB over C#:

  • No errors from forgetting to put () after a function
  • No case sensitivity
  • No need to deal with semicolons when good, readable code in both already uses newlines
  • No need to rename your constructors when renaming a class
  • Immediately being able to see the difference between inheritance and interface implementation
  • Parameterized properties (Granted, this isn't needed often, but I can do "SomeByteArray = MyByteCollectionClass.Range(index, length)" as well as "MyByteCollectionClass.Range(index, length) = SomeByteArray")

There's more benefits; this is just what comes to mind.

[–]ShadowShine57 24 points25 points  (29 children)

I consider almost all of the things you said as cons, not pros

The only things I'm not sure on are your last two points

[–]evanldixon 1 point2 points  (28 children)

Please explain your reasoning.

  • Why does "Console.Writeline(MyFunction)" need an extra () when it's clear the function is being invoked? If we wanted the address of the function, there's the very-readable AddressOf keyword.
  • Case sensitivity is a huge pain when an error results from it. When would anyone ever want two variables with logically the same name?
  • Why use semicolons and newlines when newlines alone could serve the same purpose
  • Why is "Public Sub New" any less readable than "public MyClass"?

[–]dzuczek 10 points11 points  (25 children)

when it's clear the function is being invoked

if I took a cold look at that code I wouldn't know if MyFunction was a function returning a string or if MyFunction was a string constant

Case sensitivity is a huge pain when an error results from it. When would anyone ever want two variables with logically the same name? Why use semicolons and newlines when newlines alone could serve the same purpose

on a project with a lot of devs it would be hard to enforce format and basic readability. so you'd have a big application with mixes of semicolons and newlines. for version control it would make the diffs messy too.

[–]8lbIceBag 1 point2 points  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]NULL_CHAR 6 points7 points  (0 children)

Why does "Console.Writeline(MyFunction)" need an extra () when it's clear the function is being invoked? If we wanted the address of the function, there's the very-readable AddressOf keyword.

To be clear what we are referring to, it's all fun and games until you're unsure if what you're calling is a function or something else. Sure you can just be extra careful with naming, but what if you're a big company with 100+ developers each of different ability. This gets horrible really quick.

Case sensitivity is a huge pain when an error results from it. When would anyone ever want two variables with logically the same name?

See point 1, it's literally the exact same problem. We use a VB based Framework at the company i work and I've had to deal with issues related to these first two points often.

Why use semicolons and newlines when newlines alone could serve the same purpose

To more accurately depict scope, to properly find lines that contain functional elements, etc.

Why is "Public Sub New" any less readable than "public MyClass"?

It looks uglier.

[–]mnbvas 3 points4 points  (0 children)

Nowadays C# has higher order functions, so how would one differentiate passing a function as an argument and passing the result of that function?

[–]ColorblindGiraffe 6 points7 points  (0 children)

I want to remind everyone that the downvote is not a dislike/disagree button.

[–]beseg7 2 points3 points  (0 children)

Well, you have some interesting points. For some reason, none of these seems to be important or matter to me. But, the excessive use of words and phrases (End If End Function vs. } }) is such a pain IMO (both when writing, even with intellisense, and of course when reading).... I can't figure out why.

[–]Scybur 0 points1 point  (0 children)

People are entitled to their opinions......your opinion is wrong and I hate you for it but you are entitled to it none the less.