Re: Overflowing a Long
- From: "S. I. Becker" <stewart@xxxxxxxxxxxxx>
- Date: Tue, 06 Mar 2007 13:36:41 +0000
Michael C wrote:
"Mike Williams" <mike@xxxxxxxxxxxxxxxxx> wrote in message news:uUhjtq3XHHA.2436@xxxxxxxxxxxxxxxxxxxxxxxI'm not "under exaggerating", Michael. I have written BASIC programs for almost thirty years and many of even my very earliest BASIC programs would run with no problems whatsoever if I pasted them into a VB6 Button Click event, for example.
They mustn't do much though. They obviously can't draw to the screen.
That's more to do with the DOS/Windows API than the languages themselves, and you know it.
But not a single one of them would run in dotnet. Not even the simplest of them. Not even most of the "one liners".
That is likely true but restricting vb.net to vb6 syntax would have held it back a *huge* amount.
It didn't need to be restricted, only to be backwards compatible without breaking changes. Adding new things is a good thing (when done with careful thought). Breaking old behaviour is always bad. For example, they could have added .NET's file I/O *in addition to* keeping the VB6 way. The only two things they needed to change were: deterministic finalization and running in the .NET framework. Even then, the option to compile to native should be there (like it is for C++).
Can you imagine our nicely oop language being infected with gosubs, gotos etc?
If you don't like a part of the language, and can avoid it, then don't use it - simple as that. C++ still has goto, despite being looked down upon by most.
A massive number of changes!
but it's still the same basic syntaxNo it isn't, Michael. It is massively different.
It's basically the same.
The *tokens* of VB6 and VB.NET are very similar. However the *grammars* of VB6 and VB.NET are only fairly similar (Dim, As, Function; Sub; Type; [With]; Public; Private; For...Next; Exit <Block>; [Property]; . as scope operator; function calls ...) but not the "basically the same" (File I/O; Error handling; GoSub/GoTo; Mixed Visibility Properties ... ). Therefore the languages cannot be considered the same, not only because the grammars are significantly different (Had VB.NET merely _extended_ VB6's grammar then they might be considered that might be ) but also because many items' *semantics* have been removed or changed (Return; Variant; Dimensioning arrays; On Error; String; Long; Integer; Dim x, y as Type).
Syntax = Tokens + Grammar. (http://en.wikipedia.org/wiki/Syntax_of_programming_languages , summarised)
Language = (At least) Syntax + Semantics. (My definition)
It's the same with java and C++. They use almost identical tokens, similar grammars (but with significant differences) and different semantics (e.g. How many java operations are "implementation defined"). Do you consider java and C++ to be "basically the same"?
It's not something I've bothered to actually quantify. It's more of a "gut feeling" thing, although you could certainly quantify it if you wished to do so. As I said earlier, I've been programming for nearly thirty years (machine code, Assembler, Fortran and BASIC) and when I picked up my first copy of Visual Basic (which I didn't bother doing until VB5 came out, because I was busy with other languages at the time) I was almost immediately comfortable with it. It was BASIC, but with some extra bells and whistles. There was of course a slight learning curve because of the event driven nature of VB5 (which was new to me) but nevertheless I felt at home almost straight away and I could convert even the oldest of my previous BASIC programs to VB5 very quickly and with very few problems. Dotnet is not like that.
There is a slight learning curve but it's really not that bad. It's definately less of learning curve to going from a dos language to an event driven language (if you think back, learning events wasn't that easy, it could get complicated).
It's not the learning curve that's the issue: any programmer worth their salt will be able to pick up new languages fairly quickly (they will need to, as the set of languages in use changes). The issue is taking old code, that behaved one way, and knowing that it will behave the same way in what is supposed to be the next version of a language.
Not like that at all. As far as I am concerned, dotnet is not BASIC at all. The only relationship dotnet has to the old BASIC is that the Micro$oft sales team have persuaded the Micro$oft programmers to "graft onto it" a large number of "Basic sounding constructs" in an attempt to persuade people that it is something which it isn't! Their underhand ploy hasn't worked for me, although I'm sure lots of people will be taken in by it, at least until they have parted with their money.
You can design a form just like vb6 and all the syntax is still basic syntax. It's both visual and basic :-)
Wrong, you've confused "syntax" with merely "tokens" again. But at least you're right about the visual bit - no-one denies the right of Fred to be called _Visual_ Fred, it's just the Basic bit that's at odds with reality. <g>
Stewart
.
- References:
- Re: Overflowing a Long
- From: Michael C
- Re: Overflowing a Long
- From: Mike Williams
- Re: Overflowing a Long
- From: Michael C
- Re: Overflowing a Long
- From: Mike Williams
- Re: Overflowing a Long
- From: Michael C
- Re: Overflowing a Long
- Prev by Date: Re: VB 2005 DDL in VB 6.0 project
- Next by Date: Re: Excel, Datatypes
- Previous by thread: Re: Overflowing a Long
- Next by thread: Re: Overflowing a Long
- Index(es):
Relevant Pages
|