• Welcome to Powerbasic Museum 2020-B.
 

News:

Forum in repository mode. No new members allowed.

Main Menu

Why bc9Basic

Started by James C. Fuller, March 01, 2016, 02:09:34 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

James C. Fuller

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




Theo Gottwald

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 ?

James C. Fuller

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


Frederick J. Harris

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?


James C. Fuller

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

Theo Gottwald

I doubt that even XP does need to be supported at this time.

James C. Fuller

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