From 99d2b22336461162b9e71aa49ee7b770c93bc390 Mon Sep 17 00:00:00 2001 From: "Johan B.W. de Vries" Date: Sat, 17 May 2025 18:42:27 +0200 Subject: [PATCH] Moved the typeclasse tests. Fix typeclass name. --- phasm/prelude/__init__.py | 2 +- tests/integration/test_typeclasses/__init__.py | 0 tests/integration/{test_lang => test_typeclasses}/test_bits.py | 0 tests/integration/{test_lang => test_typeclasses}/test_eq.py | 0 .../{test_lang => test_typeclasses}/test_extendable.py | 0 .../{test_lang => test_typeclasses}/test_floating.py | 0 .../{test_lang => test_typeclasses}/test_foldable.py | 0 .../{test_lang => test_typeclasses}/test_fractional.py | 0 .../{test_lang => test_typeclasses}/test_integral.py | 0 .../integration/{test_lang => test_typeclasses}/test_intnum.py | 0 .../integration/{test_lang => test_typeclasses}/test_natnum.py | 0 tests/integration/{test_lang => test_typeclasses}/test_ord.py | 0 .../{test_lang => test_typeclasses}/test_promotable.py | 0 tests/integration/{test_lang => test_typeclasses}/test_sized.py | 0 14 files changed, 1 insertion(+), 1 deletion(-) create mode 100644 tests/integration/test_typeclasses/__init__.py rename tests/integration/{test_lang => test_typeclasses}/test_bits.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_eq.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_extendable.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_floating.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_foldable.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_fractional.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_integral.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_intnum.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_natnum.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_ord.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_promotable.py (100%) rename tests/integration/{test_lang => test_typeclasses}/test_sized.py (100%) diff --git a/phasm/prelude/__init__.py b/phasm/prelude/__init__.py index e269590..b91c31f 100644 --- a/phasm/prelude/__init__.py +++ b/phasm/prelude/__init__.py @@ -462,7 +462,7 @@ instance_type_class(IntNum, f64, methods={ 'neg': stdtypes.f64_intnum_neg, }) -Integral = Type3Class('Eq', (a, ), methods={ +Integral = Type3Class('Integral', (a, ), methods={ }, operators={ '//': [a, a, a], '%': [a, a, a], diff --git a/tests/integration/test_typeclasses/__init__.py b/tests/integration/test_typeclasses/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/integration/test_lang/test_bits.py b/tests/integration/test_typeclasses/test_bits.py similarity index 100% rename from tests/integration/test_lang/test_bits.py rename to tests/integration/test_typeclasses/test_bits.py diff --git a/tests/integration/test_lang/test_eq.py b/tests/integration/test_typeclasses/test_eq.py similarity index 100% rename from tests/integration/test_lang/test_eq.py rename to tests/integration/test_typeclasses/test_eq.py diff --git a/tests/integration/test_lang/test_extendable.py b/tests/integration/test_typeclasses/test_extendable.py similarity index 100% rename from tests/integration/test_lang/test_extendable.py rename to tests/integration/test_typeclasses/test_extendable.py diff --git a/tests/integration/test_lang/test_floating.py b/tests/integration/test_typeclasses/test_floating.py similarity index 100% rename from tests/integration/test_lang/test_floating.py rename to tests/integration/test_typeclasses/test_floating.py diff --git a/tests/integration/test_lang/test_foldable.py b/tests/integration/test_typeclasses/test_foldable.py similarity index 100% rename from tests/integration/test_lang/test_foldable.py rename to tests/integration/test_typeclasses/test_foldable.py diff --git a/tests/integration/test_lang/test_fractional.py b/tests/integration/test_typeclasses/test_fractional.py similarity index 100% rename from tests/integration/test_lang/test_fractional.py rename to tests/integration/test_typeclasses/test_fractional.py diff --git a/tests/integration/test_lang/test_integral.py b/tests/integration/test_typeclasses/test_integral.py similarity index 100% rename from tests/integration/test_lang/test_integral.py rename to tests/integration/test_typeclasses/test_integral.py diff --git a/tests/integration/test_lang/test_intnum.py b/tests/integration/test_typeclasses/test_intnum.py similarity index 100% rename from tests/integration/test_lang/test_intnum.py rename to tests/integration/test_typeclasses/test_intnum.py diff --git a/tests/integration/test_lang/test_natnum.py b/tests/integration/test_typeclasses/test_natnum.py similarity index 100% rename from tests/integration/test_lang/test_natnum.py rename to tests/integration/test_typeclasses/test_natnum.py diff --git a/tests/integration/test_lang/test_ord.py b/tests/integration/test_typeclasses/test_ord.py similarity index 100% rename from tests/integration/test_lang/test_ord.py rename to tests/integration/test_typeclasses/test_ord.py diff --git a/tests/integration/test_lang/test_promotable.py b/tests/integration/test_typeclasses/test_promotable.py similarity index 100% rename from tests/integration/test_lang/test_promotable.py rename to tests/integration/test_typeclasses/test_promotable.py diff --git a/tests/integration/test_lang/test_sized.py b/tests/integration/test_typeclasses/test_sized.py similarity index 100% rename from tests/integration/test_lang/test_sized.py rename to tests/integration/test_typeclasses/test_sized.py