summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lowlevelunit.pas34
1 files changed, 34 insertions, 0 deletions
diff --git a/lowlevelunit.pas b/lowlevelunit.pas
index 7ff4268..e7be518 100644
--- a/lowlevelunit.pas
+++ b/lowlevelunit.pas
@@ -36,6 +36,10 @@ type
tWarnstufe = (wsStreng,wsLasch);
tGenauigkeit = (gSingle,gDouble,gExtended);
+operator = (x1,x2: t2x2Extended): boolean;
+operator = (x1,x2: tIntPoint): boolean;
+operator = (x1,x2: tExtPoint): boolean;
+
function signSqr(x: extended): extended; inline;
function mpfToStr(f: mpf_t): string;
function myTimeToStr(t: extended): string;
@@ -104,6 +108,36 @@ implementation
uses matheunit, systemunit;
+// überladene operatoren *******************************************************
+
+operator = (x1,x2: t2x2Extended): boolean;
+var
+ c,d: char;
+begin
+ result:=true;
+ for c:='x' to 'y' do
+ for d:='x' to 'y' do
+ result:=result and (x1[c,d]=x2[c,d]);
+end;
+
+operator = (x1,x2: tIntPoint): boolean;
+var
+ c: char;
+begin
+ result:=true;
+ for c:='x' to 'y' do
+ result:=result and (x1[c]=x2[c]);
+end;
+
+operator = (x1,x2: tExtPoint): boolean;
+var
+ c: char;
+begin
+ result:=true;
+ for c:='x' to 'y' do
+ result:=result and (x1[c]=x2[c]);
+end;
+
// allgemeine Funktionen *******************************************************
function signSqr(x: extended): extended;