Search found 2764 matches

by Tourist Trap
Jun 10, 2015 0:13
Forum: Documentation
Topic: Operator Cast missing from the index
Replies: 21
Views: 2828

Re: Operator Cast missing from the index

Good idea overall. Allow me the modifications below, as a matter of example of what would sound for me more friendly. (Forgive the possible misinterpretations!) It would be kind if you could also answer by an example or a sentence to the questions. I've put all that in your text. Implicit conversion...
by Tourist Trap
Jun 09, 2015 19:16
Forum: General
Topic: Squares
Replies: 7043
Views: 428130

Re: Squares

@fxm, I think I begin to get it now. I've made this tiny demo code that is showing that it is true that the addresses tend to be always the same, at scope level, for a given order of instruction. Or rather the adresses start at same addresse. But the order in wich the assignations come may change th...
by Tourist Trap
Jun 09, 2015 16:48
Forum: General
Topic: Squares
Replies: 7043
Views: 428130

Re: Squares

... I wouldn't say I've well understood all that you said. It is rather complicated. However, I 've edited and added a static variable as suggested for the scope issue. Not sure what I should do for the rest, since you've expressed that in a quite theoritical tone. I'm still on the wine so no coffe...
by Tourist Trap
Jun 09, 2015 16:02
Forum: Community Discussion
Topic: Dim/Data block syntax
Replies: 4
Views: 703

Re: Dim block syntax

It's cleaner to encapsulate them in a Type and define one global var/object or maybe a local var/object which you can initialise with a constrcutor and pass as parameter to your mainprocessingfunction. Such code tend to be more reusable. Nice tip. Thanks. Types should go to .bi headers while Dims g...
by Tourist Trap
Jun 09, 2015 15:26
Forum: Community Discussion
Topic: Dim/Data block syntax
Replies: 4
Views: 703

Re: Dim block syntax

Hello Drago (MaLefoy?) ;-) For me Cut/Paste is a big affair for types and variables names, lesser for "Dim As" statement itself. This is the first remark. The other remark follows immediatly from my experience. When you want to perform Cut for example or Copy, you have to grasp the text fi...
by Tourist Trap
Jun 09, 2015 14:16
Forum: Community Discussion
Topic: Dim/Data block syntax
Replies: 4
Views: 703

Dim/Data block syntax

Hi, As far as I've been able to see, there are 2 ways to declare a variable ( leave aside Redim , or additionnal keywords like Shared , or variable/type versus type/variable order ) . Those are : Dim As SomeType someVariable , or As SomeType someVariable , only for fields sitting inside UserDefined ...
by Tourist Trap
Jun 08, 2015 21:23
Forum: General
Topic: Squares
Replies: 7043
Views: 428130

Re: Squares

Not quite sure what you mean tourist trap, on the first time through the loop both anyptr's are set to the same value and the loop exits. if you do this, it shows the object is in the same memory location each time Thanks for noticing. But it is how it is intended to be since it is proof ad absurdu...
by Tourist Trap
Jun 08, 2015 20:44
Forum: General
Topic: Squares
Replies: 7043
Views: 428130

Re:

Since this is a silly thread... here's a silly question, motivated by the code from Dodicat. Look at the macro labeled background. Is there a performance penalty for using DIM within a loop, as compared to defining the var before the loop? Not always the same place in memory will be used to store t...
by Tourist Trap
Jun 08, 2015 16:02
Forum: Community Discussion
Topic: More strict Cast/Cptr behaviour?
Replies: 44
Views: 5343

Re: More strict Cast/Cptr behaviour?

MOD wrote:I really don't like the idea of breaking code, especially if it's the casting operator (which is for sure used a lot in bigger projects).

I'd suggest better have new keywords than breaking the old ones.


CType() for instance?
by Tourist Trap
Jun 08, 2015 14:44
Forum: Community Discussion
Topic: Dim Byref syntax
Replies: 134
Views: 15226

Re: Dim Byref syntax

What do you think about the syntax? I like it because it matches the syntax for Byref parameters, and Byref function results, and it doesn't require a new keyword... A possible alternative that I saw suggested on this forum a while ago, by adding the Ref keyword: I would make a remark, even not as ...
by Tourist Trap
Jun 08, 2015 13:51
Forum: Tips and Tricks
Topic: Time Ellapsed Displayer UDT and function
Replies: 8
Views: 1262

Re: Time Ellapsed Displayer UDT and function

The simplest way of stopwatching would surely be this: Dim As Double timeRemind = Timer '... 'Do the things you want to measure '... Print Timer - timeRemind Quite true, but I'm under influence of reusability paradigm and as far as I can, I make efforts to bundle things together . Here above I woul...
by Tourist Trap
Jun 07, 2015 22:05
Forum: General
Topic: Really annoying pixel problem
Replies: 10
Views: 1026

Re: Really annoying pixel problem

Meaning maybe something like : PutPixel(X,Y) GetPixel(X,Y) rather than Point ? ... As a matter of test, tis following works fine for me : Screen 18 Circle (0,100), 100, 99 Dim As Double x,y,z z= Point(100,100) ? "z=";z Sleep ''Returns z=99 as excepted This also worked , ev...
by Tourist Trap
Jun 07, 2015 15:26
Forum: Tips and Tricks
Topic: Time Ellapsed Displayer UDT and function
Replies: 8
Views: 1262

Re: Time Ellapsed Displayer UDT and function

Good heavens, why are you doing it that complicated? Hi grindstone. Nice piece of code again! To answer you, I had no idea that static could serve in a function. In fact I've met first the case where static was put into a UDT. Some time ago I remember having failed to use shared to build global var...
by Tourist Trap
Jun 07, 2015 14:32
Forum: Documentation
Topic: Documenting Syntax
Replies: 7
Views: 3314

Re: Documenting Syntax

(...) The best (IMHO) should be that in the documentation: - only list of the different supported syntaxes, without keyword "Overload", - but an ordered list representing the compiler choice priority. This also is very true. Too much condensed syntax is most often unreadable. 1 / NAME old...
by Tourist Trap
Jun 07, 2015 12:29
Forum: Tips and Tricks
Topic: Time Ellapsed Displayer UDT and function
Replies: 8
Views: 1262

Time Ellapsed Displayer UDT and function

Hi, The idea (quite a classic) is to get a function that show ellapsed time between its last call and displays it (in a packed and versatile maneer). Calling it "PutTimeStone()" it behaves like below : 'Do something ... TimeStone() ''<----- Shows ellapsed time since last call, here 0 'Do s...

Go to advanced search