Author Topic: Why bc9Basic  (Read 4773 times)

0 Members and 1 Guest are viewing this topic.

Offline James C. Fuller

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 595
  • User-Rate: +11/-8
Why bc9Basic
« on: March 01, 2016, 02:09:34 PM »
Why bc9Basic?

For me it's the versatility it offers.
As IT Consultant Patrice has pointed out in many posts, C++ is THE definitive language. IT Consultant Fred (the minimalist)  posts pages upon pages of very informative information tracing his foray into the language.

I dislike the C/C++ nomenclature with all it's semi-colons and braces. I was introduced to coding using BASIC and have always preferred it. Also note this is a translator not a compiler or interpreter.

With bc9Basic I can have the power of c++ using a BASIC syntax.
bc9Basic is NOT a beginners language. You do need at least some knowledge of c/c++ to take advantaged of it's assets.

With bc9Basic and the batch files included with the package:
  I can produce c or c++ code
    32 or 64 bit (I personally do not code in 32 bit anymore) with just a -m32 or -m64
      exe (console or gui),dll,obj,lib
      MFC or SDK (MFC is minimal on lack of knowledge on my part. VS only)
  features
    Optional parameters for "c" code akin to c++.
    Ansi or Unicode from the same basic source.
    Window/Dialog creation and message loop encapsulation
    C++ classes
    C++ STL constructs to die for :)
       vectors
       Range based For loops
       auto var declaration
       string/wstring
       regexp (although I use the pcre library)
 
Tested Compilers with supplied batch files for compiling:
    PellesC (c) (32 & 64)
    TinyC (c) (32 & 64)
    TDM-GCC (c/c++) (32 & 64) My current favorite   
    Nuwen (c/c++) (64 only)
    Visual Studio 2015 community (c/c++) (32 & 64)

James




Offline Theo Gottwald

  • Administrator
  • Hero Member
  • *****
  • Posts: 924
  • User-Rate: +30/-4
    • it-berater
Re: Why bc9Basic
« Reply #1 on: March 01, 2016, 05:59:46 PM »
Can you post some small sample Algos in bc9 Basic?
For example some easy sorting or mathematics algos and maybe a hello world.
How does it behave witH API / COM Calls ?

Offline James C. Fuller

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 595
  • User-Rate: +11/-8
Re: Why bc9Basic
« Reply #2 on: March 01, 2016, 09:35:55 PM »
Theo,
  Thanks to your request I discovered a significant bug in the latest release when compiling using Visual Studio 2015 Community.
I default to adding olepro32.lib as one of the libraries to link. It does not exist for 64 bit and as far as I can tell it was for pre XP OS's.
My gcc distros have it for 64 bit but I still need to update bc9Basic first.

James


Offline Frederick J. Harris

  • Hero Member
  • *****
  • Posts: 914
  • User-Rate: +16/-0
    • Frederick J. Harris
Re: Why bc9Basic
« Reply #3 on: March 06, 2016, 01:31:28 AM »
Quote
I default to adding olepro32.lib...

Can't say as I recall using that lib.  For the things I work on all I ever seem to need are ole32, oleauto32, and uuid.lib.  Perhaps its something old James?


Offline James C. Fuller

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 595
  • User-Rate: +11/-8
Re: Why bc9Basic
« Reply #4 on: March 06, 2016, 11:25:25 AM »
I found out that olepro32.lib is just for compatibility with older Windows versions. pre XP ?
I was surprised I did not catch it until now what with all the testing I do???

James

Offline Theo Gottwald

  • Administrator
  • Hero Member
  • *****
  • Posts: 924
  • User-Rate: +30/-4
    • it-berater
Re: Why bc9Basic
« Reply #5 on: March 06, 2016, 11:47:07 AM »
I doubt that even XP does need to be supported at this time.

Offline James C. Fuller

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 595
  • User-Rate: +11/-8
Re: Why bc9Basic
« Reply #6 on: March 06, 2016, 02:01:59 PM »
Theo,
  I do not test on/for XP but my translator should run fine on it. I compile bc9Basic as a 32bit app with the TDM-GCC compiler. Visual Studio dropped default XP support several versions ago. It can still be done but it takes more effort that I am willing to do. Also most of my testing is 64bit.

James