Search found 1284 matches

by AGS
Jul 19, 2014 23:09
Forum: Tips and Tricks
Topic: Scrolling Color Boxes
Replies: 5
Views: 1071

Re: Scrolling Color Boxes

Old school color - cycling lives again :) Here is a link to some more old school color cycling used in combination with a html 5 canvas http://www.effectgames.com/demos/canvascycle/?sound=0 Here is a bit of code that mimics mouse - hovering (as in 'perform some action when the mouse stays in one pla...
by AGS
Jul 19, 2014 5:02
Forum: Tips and Tricks
Topic: Pseudo random number generator
Replies: 3
Views: 1473

Re: Pseudo random number generator

You could try this one: http://xorshift.di.unimi.it/ I have an Intel IvyBridge so I should be able to use the RDRAND machine instruction to get a hardware generated random number. But..... Intel goofed up and there is a hardware bug on some of the processors, including mine. Thanks for the link. I ...
by AGS
Jul 10, 2014 23:32
Forum: Projects
Topic: FB debugger : 2.96 32/64 BIT ..... (2020/02/17)
Replies: 637
Views: 156753

Re: FB debugger : 2.80 BETA 12 (may 30th, 2014)

I cannot get the buttonbar to show up correctly (no pictures) yet. Must be doing something wrong when compiling the debugger. Still, fbdebugger comes with plenty of tooltips so I don't even need those pictures. To get the images : put the folder containing all these images in the directory of fbdeb...
by AGS
Jul 09, 2014 11:04
Forum: Projects
Topic: json basic scripting language [update 7/18]
Replies: 40
Views: 5814

Re: json basic scripting language [update 7/8]

I ran a simple test and got some interesting results. var a = 88 var b = 99 var c = a + b There is a ; missing at the end of every line. The parser, however, will report that a variable was not declared (a). If I turn a + b into b + a then I get a report that variable b was not declared. Both could ...
by AGS
Jul 08, 2014 20:02
Forum: Projects
Topic: FB debugger : 2.96 32/64 BIT ..... (2020/02/17)
Replies: 637
Views: 156753

Re: FB debugger : 2.80 BETA 12 (may 30th, 2014)

Alas, Insight can no longer be used as debugger on win32. It breaks when loading a file compiled with the latest version of the fbc. Meaning that I will be using your debugger from now on, SARG. I cannot get the buttonbar to show up correctly (no pictures) yet. Must be doing something wrong when com...
by AGS
Jul 08, 2014 17:46
Forum: General
Topic: Slow code generation when using -gen gcc -g -R (SOLVED)
Replies: 2
Views: 556

Re: Slow code generation when using -gen gcc -g -R (many mac

I'm going to mark this subject SOLVED.

And thanks for taking the time to check the problem out, dkl.
by AGS
Jul 06, 2014 17:15
Forum: General
Topic: Slow code generation when using -gen gcc -g -R (SOLVED)
Replies: 2
Views: 556

Slow code generation when using -gen gcc -g -R (SOLVED)

I've created a file that consists of nothing but one line macros that look like this #define identifier hexadecimal_number When using the assembler back end the compiler reports that creation of the .asm file took 0.2 seconds. Using the time utility I get a total time of execution (time fbc -g -R fi...
by AGS
Jul 02, 2014 7:46
Forum: Projects
Topic: json basic scripting language [update 7/18]
Replies: 40
Views: 5814

Re: json basic scripting language [update 7/1]

I have used cutest in the past for creation of a test suite. http://cutest.sourceforge.net/ It consists of two small. I translated the entire code of cutest to FreeBASIC cutest.bi #IFNDEF CU_TEST_H #DEFINE CU_TEST_H #ifndef NULL #define NULL 0 #endif #ifdef __FB_UNIX__ #define NEWLINE !"\r"...
by AGS
Jun 30, 2014 0:22
Forum: Projects
Topic: json basic scripting language [update 7/18]
Replies: 40
Views: 5814

Re: json basic scripting language

You might need a test suite real soon. Regression testing while writing a piece of software like an interpreter is a must-have. Perhaps a very rigid approach to testing might help: create a test suite with enough test cases so that executing the test suite will execute every functions at least once....
by AGS
Jun 28, 2014 17:12
Forum: Community Discussion
Topic: I debated doing this...
Replies: 11
Views: 2306

Re: I debated doing this...

!Infidel! Thou shalt not program in a programming language other than FreeBASIC.
by AGS
Jun 28, 2014 17:00
Forum: Projects
Topic: json basic scripting language [update 7/18]
Replies: 40
Views: 5814

Re: json basic scripting language

What about a grammar, rollie? You are creating a language and I'd like to see what it looks like. Reading your source code I can find out what language it is you are implementing (jsb_context tells tales). But a grammar could tell me what a .jsb file is all about a lot faster. A grammar for the json...
by AGS
Jun 14, 2014 9:53
Forum: Projects
Topic: in-process-locks, would someone pls take a look?
Replies: 4
Views: 931

Re: in-process-locks, would someone pls take a look?

It looks like the procedures were intended to be called with the Borland fastcall convention. The code does not make sense to me. To pick just one problem, the instruction sequence: cmp [ebx],0 'ok.. is the Flag=0? jz @GotLock 'it is, oh joy Is not atomic, so between the comparison and the conditio...
by AGS
Jun 10, 2014 4:28
Forum: Projects
Topic: in-process-locks, would someone pls take a look?
Replies: 4
Views: 931

Re: in-process-locks, would someone pls take a look?

The code looks close enough to fb to (almost) use it as-is. Couple of things are missing. This should be at the top #include "windows.bi" windows.bi is needed to gain access to the synchronization functions (Interlocked*). The @ must be removed (all instances). Example (@ removed) AquireLo...
by AGS
May 08, 2014 0:17
Forum: Tips and Tricks
Topic: Pseudo random number generator
Replies: 3
Views: 1473

Pseudo random number generator

This example is an implementation of a pseudo random number generator. It was copied and translated by me from http://www0.cs.ucl.ac.uk/staff/d.jones/GoodPracticeRNG.pdf There are more examples of prng implementations in the paper (and some tips on how to use/write a (p)rng). The period of the gener...
by AGS
May 05, 2014 20:06
Forum: Projects
Topic: A lexical analyzer generator for FreeBASIC
Replies: 50
Views: 11059

Re: A lexical analyzer generator for FreeBASIC

Using [[:charclass:]] solved the problem. I found something else. Using _ in an identifier uses as the lhs of a variable leads to a syntax error. Example Let pattern_var='a' pattern:'{pattern_var}' Error message when using poodle-lex Unable to parse rule 'pattern': Character 8: Expected "}"...

Go to advanced search