• Print

Author Topic: QB64 string function accepts negative values [by design]  (Read 586 times)

sjt1975

  • Newbie
  • *
  • Posts: 49
    • My Personal Web-Site
    • Email
Re: QB64 string function accepts negative values
« Reply #15 on: March 18, 2013, 10:55:06 AM »
Quote from: fluffrabbit on March 18, 2013, 08:41:13 AM
Quote from: sjt1975 on March 17, 2013, 11:45:48 AM
Quote from: fluffrabbit on March 17, 2013, 10:49:39 AM
I think that complete compatibility with QBASIC should be maintained at all times.

That would be the ideal answer.

Quote from: fluffrabbit on March 17, 2013, 10:49:39 AM
This may or may not be an incompatibility.

Strictly speaking, this is an incompatibility with QB45.  However, I consider it to be a harmless incompatibility, since it doesn't cause any errors (the functions just return an empty string) and the original behaviour (as per QB45) still works as intended.  A programmer would not normally pass negative parameters to the LEFT$/MID$/RIGHT$ functions, since they don't make logical sense.

What if someone wrote a QBASIC program in the QB64 editor and then tried to port it to QB 4.5?

As I've already said, it is a strict in-compatibility with QB45, so the programmer would have to ensure that they coded in a strictly-compatible manner, if they were to do this; however, in this modern day-and-age, why would somebody develop a program in QB64, then 'port it' (i.e. compile it) with QB45?  The resultant EXE would be 16-bit, so would not run on a modern version of Windows.  So, there isn't much advantage to doing that, but many more dis-advantages to doing that...

However, Galleon has already stated that the current behaviour won't be changed, at least in the short-term, so it's getting to be a moot point now...

fluffrabbit

  • Sr. Member
  • ****
  • Posts: 431
Re: QB64 string function accepts negative values
« Reply #16 on: March 19, 2013, 07:57:56 AM »
Whatever. The main reason for compiling with QB 4.5 would be compatibility with DOS and versions of Windows earlier than QB64 supports.

sjt1975

  • Newbie
  • *
  • Posts: 49
    • My Personal Web-Site
    • Email
Re: QB64 string function accepts negative values
« Reply #17 on: March 19, 2013, 11:31:03 AM »
Quote from: fluffrabbit on March 19, 2013, 07:57:56 AM
The main reason for compiling with QB 4.5 would be compatibility with DOS and versions of Windows earlier than QB64 supports.

Yes, of course, but people shouldn't be running such old systems nowadays.
« Last Edit: March 19, 2013, 12:13:39 PM by sjt1975 »

fluffrabbit

  • Sr. Member
  • ****
  • Posts: 431
Re: QB64 string function accepts negative values
« Reply #18 on: March 19, 2013, 02:22:58 PM »
Quote from: sjt1975 on March 19, 2013, 11:31:03 AM
Quote from: fluffrabbit on March 19, 2013, 07:57:56 AM
The main reason for compiling with QB 4.5 would be compatibility with DOS and versions of Windows earlier than QB64 supports.

Yes, of course, but people shouldn't be running such old systems nowadays.
Speak for yourself.

sjt1975

  • Newbie
  • *
  • Posts: 49
    • My Personal Web-Site
    • Email
Re: QB64 string function accepts negative values
« Reply #19 on: March 19, 2013, 02:45:23 PM »
Quote from: fluffrabbit on March 19, 2013, 02:22:58 PM
Quote from: sjt1975 on March 19, 2013, 11:31:03 AM
Quote from: fluffrabbit on March 19, 2013, 07:57:56 AM
The main reason for compiling with QB 4.5 would be compatibility with DOS and versions of Windows earlier than QB64 supports.

Yes, of course, but people shouldn't be running such old systems nowadays.
Speak for yourself.

I'm not having a go at you, fluffrabbit, don't be offended.  Of course, it's up to you, what systems you wish to run, but you are more limited with older systems.
« Last Edit: March 19, 2013, 03:07:18 PM by sjt1975 »

fluffrabbit

  • Sr. Member
  • ****
  • Posts: 431
Re: QB64 string function accepts negative values
« Reply #20 on: March 19, 2013, 02:52:52 PM »
Quote from: sjt1975 on March 19, 2013, 02:45:23 PM
Quote from: fluffrabbit on March 19, 2013, 02:22:58 PM
Quote from: sjt1975 on March 19, 2013, 11:31:03 AM
Quote from: fluffrabbit on March 19, 2013, 07:57:56 AM
The main reason for compiling with QB 4.5 would be compatibility with DOS and versions of Windows earlier than QB64 supports.

Yes, of course, but people shouldn't be running such old systems nowadays.
Speak for yourself.

I'm not having a go at you, fluffrabbit, don't be offended.  Of course, it's up to you, what systems you wish to run, but you are more limited with older systems.
I disagree, but I'm not going to argue with you. I'm just saying that at its core, QB64 is a QBASIC compiler. Yes, Galleon has added some features, but he also broke compatibility with all but the newest computers. If you ask me, the best features are the original features. QBASIC is all you need. QB64 just adds some shortcuts (what with those underscore commands).

OlDosLover

  • Hero Member
  • *****
  • Posts: 4125
  • OlDosLover
    • Email
Re: QB64 string function accepts negative values
« Reply #21 on: March 19, 2013, 04:19:02 PM »
Hi all,
   
Quote
If you ask me, the best features are the original features. QBASIC is all you need. QB64 just adds some shortcuts (what with those underscore commands).
I'm not trying to be argumentative here but i disagree. I dont need qbasic compatibility that much. To me the best features are the new underscore commands. If Qbasic is all you need then you'd be stuck in low resolutions and low color depths just for starters.
OlDosLover.

fluffrabbit

  • Sr. Member
  • ****
  • Posts: 431
Re: QB64 string function accepts negative values
« Reply #22 on: March 19, 2013, 07:03:39 PM »
Quote from: OlDosLover on March 19, 2013, 04:19:02 PM
Hi all,
   
Quote
If you ask me, the best features are the original features. QBASIC is all you need. QB64 just adds some shortcuts (what with those underscore commands).
I'm not trying to be argumentative here but i disagree. I dont need qbasic compatibility that much. To me the best features are the new underscore commands. If Qbasic is all you need then you'd be stuck in low resolutions and low color depths just for starters.
OlDosLover.
Sure, the screen resolutions and color depths. The underscore commands make it easier too. It's not like you need QB64 over QB 4.5 to make games, though. That's all I use QB for anyways. Yes, I understand that QB64 has some new features, but new isn't always better. No offense to Galleon. I really like QB64, but it's not perfect yet.

Mrwhy

  • Hero Member
  • *****
  • Posts: 2908
  • My Dad called me Mr Why when I was 5.
    • Email
Re: QB64 string function accepts negative values
« Reply #23 on: March 19, 2013, 08:10:36 PM »
I completely agree with you, Fluffy.
Not only that but to get a prog running RIGHT takes 1/10th time in qb45. I do  all my development by first switching back to qb45 and then, once debugged, changing them back to qb64.
As for the colours, if they look good in qb64, so much better can they look in qb64 but the only things needed are trifling (and boring) changes in mere code!
I suppose I will have to automate this process in the end.

sjt1975

  • Newbie
  • *
  • Posts: 49
    • My Personal Web-Site
    • Email
Re: QB64 string function accepts negative values
« Reply #24 on: March 19, 2013, 11:40:10 PM »
Quote from: fluffrabbit
I disagree, but I'm not going to argue with you.

I don't want you to argue with me.  Everybody is entitled to their opinions.  I respect your opinions.  I agree with some of what you have said, like Clippy, but also with some of what Galleon has said.  I am merely expressing my opinions, as you are.

Quote from: fluffrabbit
I'm just saying that at its core, QB64 is a QBASIC compiler. Yes, Galleon has added some features, but he also broke compatibility with all but the newest computers. If you ask me, the best features are the original features. QBASIC is all you need. QB64 just adds some shortcuts (what with those underscore commands).

I agree with you, in theory, that QBASIC should be all you need.  However, in my experience, the more functionality you give users in software, the more functionality they come to demand/expect, so it gets to be a vicious circle.  In my opinion, QB64 needs to expand as a programming language, as you say with the _ commands, but the QB45 commands should behave as per QB45, as much as possible.
« Last Edit: March 19, 2013, 11:49:16 PM by sjt1975 »

fluffrabbit

  • Sr. Member
  • ****
  • Posts: 431
Re: QB64 string function accepts negative values
« Reply #25 on: March 21, 2013, 12:17:21 PM »
Quote from: sjt1975 on March 19, 2013, 11:40:10 PM
I agree with you, in theory, that QBASIC should be all you need.  However, in my experience, the more functionality you give users in software, the more functionality they come to demand/expect, so it gets to be a vicious circle.  In my opinion, QB64 needs to expand as a programming language, as you say with the _ commands, but the QB45 commands should behave as per QB45, as much as possible.

I see things in a similar way. In my opinion, adding more functionality is usually a good thing provided that it does not get harder to use anything. QB64 is walking a fine line. I consider myself lucky to be able understand and make use of QB64. Other languages (such as Java, C, and ActionScript) proved far too hard to learn. If I can't make a Mario-type game in a day, I am using the wrong language. So, as long as QB64 doesn't get any harder and doesn't lose any compatibility, I fully support any changes.

Just to give you a little background on where I'm coming from, when I was in high school I learned this cool new language called DarkBASIC, which is like QBASIC but 3D. The only thing I didn't like about it was that it only made games for Windows, since it relied on DirectX and was proprietary and closed-source. QB64 apparently does what DarkBASIC doesn't, however from what I hear, it is not compatible with Windows 98. It may even require some special service pack for XP compatibility. We cannot abandon Windows 98.

OlDosLover

  • Hero Member
  • *****
  • Posts: 4125
  • OlDosLover
    • Email
Re: QB64 string function accepts negative values
« Reply #26 on: March 21, 2013, 02:21:33 PM »
Hi all
   
Quote
Other languages (such as Java, C, and ActionScript) proved far too hard to learn.
I can attest to that!

Quote
If I can't make a Mario-type game in a day, I am using the wrong language.
Boy  , your impatient!

Quote
however from what I hear, it is not compatible with Windows 98. It may even require some special service pack for XP compatibility. We cannot abandon Windows 98.
    98 has gone. You carn't compile on it. However last time i tried ,supplying the exe and DLL's they do work!
OlDosLover.

mcalkins

  • Hero Member
  • *****
  • Posts: 1297
    • qbasicmichael.com
    • Email
Re: QB64 string function accepts negative values
« Reply #27 on: March 21, 2013, 02:22:38 PM »
Anyone running XP should be using SP3.

QB64 GL works on Windows 2000 SP4 with 1 change. A few more changes are needed to get it to work on 98SE. There was some work on this a few months ago, but the results were inconclusive.

Give me some time, and I will try to find out better what is needed to make it run on 98SE. You probably won't be able to use the printer.

What kind of microprocessor do you have on your 98SE computer? The MinGW currently requires a 686. (Pentium Pro or Pentium II)

Regards,
Michael

P.S. We could use a different C++ compiler, such as an older version of MinGW. The one that came with Dev-C++ did work on Windows 98SE with 586 (Pentium I). That might take more changes to the QB64 source code, though.

This discussion has gone way off topic from the original... My further responses will be in a new topic..
« Last Edit: March 21, 2013, 02:51:49 PM by mcalkins »
The QBASIC Forum Community: http://www.network54.com/index/10167 Includes off-topic subforums.
QB64 Off-topic subforum: http://qb64offtopic.freeforums.org/

OlDosLover

  • Hero Member
  • *****
  • Posts: 4125
  • OlDosLover
    • Email
Re: QB64 string function accepts negative values
« Reply #28 on: March 21, 2013, 02:36:39 PM »
Hi all,
    That would be a problem for some of my older computers.
Quote
What kind of microprocessor do you have on your 98SE computer? The MinGW currently requires a 686. (Pentium Pro or Pentium II)
    PI 120G and P1 166G but i dont use them any more. To be honest Michael if it needs PII then you'd be better off with Win2K on them. Very early in the peace when Galleon changed the compiler version my copy would not compile on Millennium anymore so i went to Win2K , and then after same went to XP sp3.
OlDosLover.

  • Print