summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--matheunit.pas8
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