Search found 35 matches
- Feb 21, 2024 2:18
- Forum: General
- Topic: Having a strange problem with a program
- Replies: 3
- Views: 314
Re: Having a strange problem with a program
Compile with '-exx'. That will add in additional runtime checking for things like bounds. When I compile with -exx and run your example, I get: $ ./tinybasic hello.bas Aborting due to runtime error 6 (out of bounds array access) at line 573 of tinybasic.bas::INITLEX2() So I think your problem is so...
- Feb 21, 2024 1:27
- Forum: General
- Topic: Having a strange problem with a program
- Replies: 3
- Views: 314
Re: Having a strange problem with a program
Compile with '-exx'. That will add in additional runtime checking for things like bounds. When I compile with -exx and run your example, I get: $ ./tinybasic hello.bas Aborting due to runtime error 6 (out of bounds array access) at line 573 of tinybasic.bas::INITLEX2() So I think your problem is so...
- Feb 20, 2024 23:58
- Forum: General
- Topic: Having a strange problem with a program
- Replies: 3
- Views: 314
Having a strange problem with a program
I'm using: FreeBASIC Compiler - Version 1.10.1 (2023-12-24), built for win64 (64bit) On Windows 10. I have a simple program (650 lines of code, 36 functions) that is causing me problems :( I compile with: fbc64 -lang qb tinybasic.bas I run with: tinybasic hello.bas If I put a debugging function at t...
- Jan 18, 2023 14:37
- Forum: Community Discussion
- Topic: How reveive error message?
- Replies: 44
- Views: 3308
Re: How reveive error message?
No problem I was just a bit irritated. I _think_ it is perhaps a language issue, e.g., English vs. whatever his native tongue is (Croatian?). In any case, his English is much better than my Croatian! :) As I'm very friendly. I'll post some code in fbc with only Win Api but you will have to translat...
- Jan 17, 2023 19:11
- Forum: Community Discussion
- Topic: How reveive error message?
- Replies: 44
- Views: 3308
Re: How reveive error message?
I found something in Vanya IUP IDE and looking to me very complicated : I agree. Using CreatePipe can get pretty involved. I think the best bets are: * as suggested earlier by srvaldez and dodicat, use the shell command to run the compiler, and redirect the output to a temp file. Then just load the...
- Jan 17, 2023 10:59
- Forum: Community Discussion
- Topic: How reveive error message?
- Replies: 44
- Views: 3308
- Jan 17, 2023 10:58
- Forum: Community Discussion
- Topic: How reveive error message?
- Replies: 44
- Views: 3308
- Dec 20, 2022 13:28
- Forum: Projects
- Topic: cedit (windows , linux , freebsd , dos)
- Replies: 11
- Views: 5386
Re: cedit (windows , linux ,dos)
Very cool!
Also works on Ubuntu under WSL. Note: I did have to install missing libtinfo5
Thanks for sharing!
Also works on Ubuntu under WSL. Note: I did have to install missing libtinfo5
Thanks for sharing!
- Nov 11, 2022 17:59
- Forum: Sources, Examples, Tips and Tricks
- Topic: Trick: Multiple Child Windows Into Parent
- Replies: 4
- Views: 1092
Re: Trick: Multiple Child Windows Into Parent
When I compile this with v1.09, I get: fbc -s gui multiwin2.bas multiwin2.bas(10) warning 4(2): Suspicious pointer assignment multiwin2.bas(29) warning 4(2): Suspicious pointer assignment multiwin2.bas(65) error 20: Type mismatch, before ')' in 'AppendMenu(hMenu, MF_POPUP, cast(UINT,hSubMenu), "...
- Nov 03, 2022 14:32
- Forum: Beginners
- Topic: Result is different in -lang qb vs. just normal compile
- Replies: 2
- Views: 740
Result is different in -lang qb vs. just normal compile
Using: FreeBASIC Compiler - Version 1.09.0 (2021-12-31), built for win64 (64bit) On Windows 10. If I compile this with fbc foo.bas: print 78 + 34 * 9 * (45 * (23 - 15 * 4) - 8) The output is: -511860 If I compile it with: fbc -lang qb The output is: 12428 Why the difference? Note that GW-Basic, PC-B...
- Feb 21, 2022 20:51
- Forum: General
- Topic: A command line calculator?
- Replies: 10
- Views: 1957
Re: A command line calculator?
How did you compile it?
It requires "-lang qb" in order to compile.
--
- Feb 21, 2022 17:03
- Forum: General
- Topic: A command line calculator?
- Replies: 10
- Views: 1957
Re: A command line calculator?
Did anyone make ever made a calculator in freebasic that can be called from the command line / terminal? E.g. if I type fbcalc "((3+4)/2-1)" I get as output 2.5 Here is a (hopefully) simple one I wrote a few years ago. It uses precedence climbing to parse the expression. 'Eval function, s...
- Jun 27, 2021 15:12
- Forum: Community Discussion
- Topic: FreeBASIC 1.08.0 Release Discussion (June 2021)
- Replies: 74
- Views: 11896
Re: FreeBASIC 1.08.0 Release Discussion (June 2021)
In 1.07, the following compiles warning free with "-lang qb": declare function foo$ dim s$ s$ = foo$ function foo$ foo$ = "bar" end function In 1.08 (both fbc32 and fbc64) I get: foo.bas(4) warning 44(1): Suffix ignored in 'foo$' Is there a way to disable the new warning?
- May 28, 2021 21:07
- Forum: General
- Topic: openfilename
- Replies: 25
- Views: 3042
Re: openfilename
When you compile, use the "-s gui" option, as in:aurelVZAB wrote:Ok
I still dont know how to kill console in background ?? ..it is so annoying ...
fbc -s gui toy.bas
This tells FreeBasic you don't want that annoying console :)
- Mar 01, 2021 20:22
- Forum: General
- Topic: Numeric/String Eval function
- Replies: 9
- Views: 2221
Re: Numeric/String Eval function
I always thought exponentiation was always evaluated right to left. Low and behold, about half the languages I looked at do it left to right and half do it right to left. QBasic, VB, and FB all do it left to right. Python does it right to left. Most mathematicians insist on right to left as well al...