Discussions
#6
Looks like you have an impressive start on a new Basic compiler. The main thing being dynamic Strings and WStrings, which for some reason others lack. Free Basic does have a dynamic String.
But is it a good idea to target it as a PB replacement? It will have to be almost 100% compatible to compile existing PB code. By the time you get there, how many will care? A potential new user won’t.
If the target is a new Basic compiler, there is no need to support 32bit, few will care.
Then you don’t have arbitrary data types to deal with.
The modern trend is something like U8, I64, F64; you know exactly what it is.
If you wish to support COM, supporting it in the compiler makes the assembly very complex. As a library, it can be added later.
Trying to support OPP and inheritance makes a confusing mess of the syntax. Some new compilers such as Go and Zig moved away from it. An object is just an allocated UDT.
Inheritance is just adding another UDT in the UDT and using the added UDT to call its procedures.

One really nice thing about Free Basic, ability to add a constructor and destructor to the UDT is powerful. With that, almost everything including strings and arrays can be in libraries. The destructor frees the memory when it goes out of scope.
Shouldn’t you focus on the compiler first, then the editor? The editor may have to keep changing if the compiler does.
If I was writing a compiler, I’d make it case sensitive to get away from reserved word hell.

Forget about the past, make a Basic compiler for the future. Just core necessities in the compiler, everything else in libraries which can be built and replaced over time as need arises.
Also, you need a ReAlloc function.
Good luck. Be interesting to see what you come up with.
Stan…
Reply


Messages In This Thread
Discussions - by Juergen Kuehlwein - 12.04.2026, 14:09
RE: Discussions - by Juergen Kuehlwein - 12.04.2026, 16:13
RE: Discussions - by Steven Pringels - 15.04.2026, 18:07
RE: Discussions - by Juergen Kuehlwein - 15.04.2026, 21:19
RE: Discussions - by Stanley Durham - 17.04.2026, 19:56
RE: Discussions - by Juergen Kuehlwein - 17.04.2026, 23:12
RE: Discussions - by Stanley Durham - 18.04.2026, 03:40
RE: Discussions - by Juergen Kuehlwein - 18.04.2026, 09:16

Forum Jump:


Users browsing this thread: 1 Guest(s)