diff options
author | Erich Eckner <git@eckner.net> | 2015-07-29 16:14:32 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2015-07-29 16:14:32 +0200 |
commit | 18ca3940994716110e0ed95ac17adc7a53b39397 (patch) | |
tree | 18c722888e8b9727c8b58064a19322322906f745 | |
parent | 75cfcada7d08c5c4e8d5b5e084f5ffbbca110539 (diff) | |
download | units-18ca3940994716110e0ed95ac17adc7a53b39397.tar.xz |
kleine Erklaerung zu Fehler in exprToFloat eingebaut
-rw-r--r-- | matheunit.pas | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/matheunit.pas b/matheunit.pas index 9525fe3..7fc3188 100644 --- a/matheunit.pas +++ b/matheunit.pas @@ -54,6 +54,7 @@ constructor tKnownValues.create; begin inherited create; fillchar(kvs,sizeof(kvs),#0); + add('π',pi); end; destructor tKnownValues.destroy; @@ -472,7 +473,12 @@ begin if not cbv then result:=strtofloat(s) else if not kvs.extract(s,result) then begin if st then result:=1 - else if assigned(cbgv) then result:=cbgv(s); + else if assigned(cbgv) then result:=cbgv(s) + else begin + result:=nan; + gibAus(''''+s+''' kann ich nicht auflösen!',3); + halt(1); + end; end; (* if s='np' then result:=params.np else if s='maxw' then result:=params.maxW |