Libraries & objects
About Archicad and BIMcloud libraries, their management and migration, objects and other library parts, etc.

'Use of real types can result in precision problems'

Durval
Enthusiast
When trying to edit, in AC9, an object created by AC7, I get the message on the title of this post when the 'Check Script' button is pressed. I haven't changed anything in the scripts yet.
The line where the warning points to have IF statements like these:
IF B=0 THEN ....
IF anyparameter<>0 THEN...
Despite the warnings, the object seems to work perfectly.
What 'real types' is AC talking about??
--- www.dtabach.com.br ---
AC 24 BR – MacBook Pro 2,9 GHz Intel Core i7 16GB RAM Mac OS 10.14
23 REPLIES 23
Durval
Enthusiast
Olivier wrote:
Let's take this example about text position (old GV's names to make short).

IF (W~ > 90 AND W~ <= 270) THEN ROT2 180 ELSE ROT2 0
Currently, this script works, with some weaks for limt values, and i understand now, why.
Thanks to all the programmers for their explanations.

According to the new rules, i should write, if i understand correctly
eps=0.0001
IF (ABS(W~ -90) > eps AND ABS(W~ -270) <= eps) THEN ROT2 180 ELSE ROT2 0
it does'nt work.

If i write
IF ((W~ -90) > eps AND (W~ -270) <= eps) THEN ROT2 180 ELSE ROT2 0
this statement works perfectly.
None of your examples would trigger the warning.
By the way, Karl, '>='s and '<='s also do not trigger them.
--- www.dtabach.com.br ---
AC 24 BR – MacBook Pro 2,9 GHz Intel Core i7 16GB RAM Mac OS 10.14
It seems with a recent (2045?) update, actual precision problems have arisen where there were harmless warnings before.

I had several windows suddenly start failing to generate with 'incompatible types of expression' errors in the report. I opened them to check for errors, and the only errors were 'UORTCRIPP's.

I fixed them and the windows were fine. I have been selectively ignoring those warnings, but I'm stopping as of now.
James Murray

Archicad 27 • Rill Architects • macOS • OnLand.info
Anonymous
Not applicable
Durval wrote:
Olivier wrote:
Let's take this example about text position (old GV's names to make short).
Hi Durval,

You force me to work on the national day, here, what a pity.
Well, before a "non sleeping night", if i can clarify some points.

Thanks to the help of many contributors on this forum, and specially Oleg's help, i solved most of these problems.
I must admit that for ">= & <=" equalities, sometime i still get some weird results.
With the quoted example, sometime i can't get correct results (for limit values), anything i try. No more with GS examples.
I don't have the truth, so, for such particular situations, i add a parameter allowing the user to correct this manually.
JGoode
Expert
I can't believe this is still an issue 14 years later.
Any way to turn off this particular error message yet?
ArchiCAD 23

Windows 10