Could FreeBASIC replace C

General FreeBASIC programming questions.
RayBritton
Posts: 306
Joined: Jun 02, 2005 7:11
Contact:

Could FreeBASIC replace C

Postby RayBritton » Mar 01, 2006 11:16

Hi, i was wondering could FreeBASIC replace C as the number 1 language. Or are they things that C can do and FreeBASIC can't yet.
arenth
Posts: 511
Joined: Aug 30, 2005 6:22

Postby arenth » Mar 01, 2006 12:08

C isnt the number one language anymore, C++ is, and to be honest, attempting to replace even it is somewhat pointless, as that is what MS is already attempting to do with the .net platform and the various managed languages, however freebasic could certainly add to the myriad of choices available to a programmer, and since its such an excellent choice, I'm sure it would be very welcome.
TheMG
Posts: 376
Joined: Feb 08, 2006 16:58

Postby TheMG » Mar 01, 2006 12:58

C was never the top language, and neither was C++. The top language is ASM. FreeBASIC could quite easily replace them both (C/++).
PlayerOne
Posts: 173
Joined: Aug 15, 2005 18:58
Location: UK

Postby PlayerOne » Mar 01, 2006 13:18

No.

It isn't so difficult to translate between C and FB code, but I think most people familiar with both would still prefer the C syntax. C is extremely popular, most languages invented since then have followed C's lead to some extent (C++, C#, Java, PHP, D). BASIC often seems a bit woolly in comparison, but FB does have a nice runtime and gfxlib which makes it easier to get a useful program started, and I don't believe there's anything it can't do.
TheMG
Posts: 376
Joined: Feb 08, 2006 16:58

Postby TheMG » Mar 01, 2006 13:21

The most powerful language doesnt have to be popular.
1000101
Posts: 2556
Joined: Jun 13, 2005 23:14
Location: SK, Canada

Postby 1000101 » Mar 01, 2006 13:38

TheMG wrote:C was never the top language, and neither was C++. The top language is ASM. FreeBASIC could quite easily replace them both (C/++).


Quite the opposite. ASM is neither a language nor at the top. ASM is the lowest "language" by definition.

Further, even attempting to replace C/C++ is laughable. And the only contender is Java.
TheMG
Posts: 376
Joined: Feb 08, 2006 16:58

Postby TheMG » Mar 01, 2006 13:42

Erm would you kindly explain you insanity? lol

ASM is a language, it has words, syntax and ways of expressing values. Its fastest, smallest, portablest etc. Its even easy to understand (but not to write).

Java is not a contentder to replace VBScript. LOL. It is one of the most unportable languages ever. Sucky...
1000101
Posts: 2556
Joined: Jun 13, 2005 23:14
Location: SK, Canada

Postby 1000101 » Mar 01, 2006 13:52

Well, first off, RTM :P

Assembly is on the same level of a language as grunts and arm gestures. You can communicate what you need but it isn't efficient. Assembly is the lowest level language in that it's closest to the hardware (every assembly mneumonic has a direct meaning to the CPU). Nor is assembly portable at all. Portability means it can be transported between different things, platforms, architecture, etc. Assembly is rarely portable between platforms and never between architecture. If you don't understand this, then you really do need to RTM.

Now, as to the lunacy of Java vs VBScript...WTF? Even if you mean JavaScript (which is not Java) then you are still wrong. Nothing (except MS products) support VBScript. JavaScript will run in every browser on every server, VBScript is limited to IE and IIS.
Last edited by 1000101 on Mar 01, 2006 14:02, edited 1 time in total.
SJ Zero
Posts: 136
Joined: Jun 19, 2005 4:12

Postby SJ Zero » Mar 01, 2006 14:02

Erm.... Assembler isn't portable.

Between CPUs it simply 100% isn't portable, and between operating systems, it's only as portable as the design allows -- just like C.
TheMG
Posts: 376
Joined: Feb 08, 2006 16:58

Postby TheMG » Mar 01, 2006 14:06

1 The VBScript thing, I was joking. But still Java is reliant on JRE, so cannot say make an OS.

2 Grunts and arm getsures (if made standardised) are languages.

3 By portable it is will be as portable as possible. But it still rules in speed (and small exe's).
1000101
Posts: 2556
Joined: Jun 13, 2005 23:14
Location: SK, Canada

Postby 1000101 » Mar 01, 2006 14:14

TheMG wrote:1 The VBScript thing, I was joking. But still Java is reliant on JRE, so cannot say make an OS.


You make no indication your were joking. Writen language does not convey intent, only litteral translation.

TheMG wrote:2 Grunts and arm getsures (if made standardised) are languages.


True, but the amount of grunts and gestures it would take to convey anything of meaning makes it a completely unusable option.

TheMG wrote:3 By portable it is will be as portable as possible. But it still rules in speed (and small exe's).


Again, no intent is conveyed. You did not mean as portable as possible. You meant portable. Further, saying "as portable as possable" is completely meaningless. You can portage a battleship "as well as possable" which is to say, "not at all."
SJ Zero
Posts: 136
Joined: Jun 19, 2005 4:12

Postby SJ Zero » Mar 01, 2006 14:18

ASM won't run on any other processor architecture other than the one it was designed for, and in some cases won't even run correctly on similar architectures using the same instruction set. C is more portable, period. A well-designed C program using cross-platform libs can run on a variety of different architectures and operating systems. It is more or less considered the standard when you want compatibilty.
hippy
Posts: 84
Joined: Nov 04, 2005 18:13
Location: UK

Postby hippy » Mar 01, 2006 14:22

It's all about semantics; what does "Top Language" mean ? Most used, most prefered, most suitable, most lines of code written using it, most portable, or something else ?

Likewise for, will FB replace C, C++ or anything else.

As to ASM / Assembly Language, I certainly consider it to be a programming language, and ideally suited for some applications and a far better choice than any higher level language in some cases, especially on low-end, highly constrained, microcontrollers. As always, it's a case of choosing the right tool for the job.
shiftlynx
Posts: 6
Joined: May 27, 2005 18:37
Location: United Kingdom
Contact:

Postby shiftlynx » Mar 01, 2006 14:27

TheMG, please unplug your computer and sell it. This is required as part of legislation to remove idiocy from the Internet.

FreeBASIC will never replace C for a number of reasons, the number one reason being that the language isn't standardised. FreeBASIC is an excellent toy language and it's great for newbie programmers, but imagining it being adopted by the software development industry as a replacement for C is just stupid.

I don't think you understand why object oriented programming is so popular. It's not because it's "easy", it's because of the benefits of structural design, code reuse, abstraction, maintainability... the list goes on and unless you appreciate what these buzzwords mean and why they're so important, you can't make serious speculation about the future of software development.

Assembly is the opposite of portability. The point of assembly is to provide mnemonics representing opcode instructions specific to an architecture. The point of a portable language is to abstract away from any specific platform.

Do some research and you'll see that C++ and Java are the most popular modern programming languages - .NET languages (C#, VB.NET, etc.) are likely to catch up with (if not overtake) Java - partly because of Microsoft's marketing budget and partly because, in reality, the paradigm is a good one. There are reasons in specific circumstances why it's not always a good paradigm, but in general, it is good.
1000101
Posts: 2556
Joined: Jun 13, 2005 23:14
Location: SK, Canada

Postby 1000101 » Mar 01, 2006 14:30

hippy wrote:It's all about semantics; what does "Top Language" mean ? Most used, most prefered, most suitable, most lines of code written using it, most portable, or something else ?

Likewise for, will FB replace C, C++ or anything else.

As to ASM / Assembly Language, I certainly consider it to be a programming language, and ideally suited for some applications and a far better choice than any higher level language in some cases, especially on low-end, highly constrained, microcontrollers. As always, it's a case of choosing the right tool for the job.


Yes, "Top Language" is a little ambiguous, but I took (read: assumed) it to mean, "balanced between usability, scalability, portability and ability to preform the myriad tasks required on a given system."

Anything replacing C or C++ is utterly ludicrous though. C and C++ are too wide spread and fullfills most of what I mentioned just above too well. Sure, there are a few things where C/C++ could do better, but it is, for the most part, the best language for any job.

As to asm on microcontrollers and embeded systems. This isn't always true. While, yes, sometimes you need that routine in less then 200 bytes of code, but for a lot of microcontrollers there are C compilers. The HC11 has one, for example (this is the only example I can think of and am assuming more have them too).

Choosing the right tool for the job I can agree with too. Most things don't need to be coded in assembly though. If anything, only small portions need some hand-tooled assembly and most modern compilers allow for inline assembly.

Return to “General”

Who is online

Users browsing this forum: No registered users and 10 guests