diff options
author | jaseg <git@jaseg.de> | 2022-01-19 00:36:05 +0100 |
---|---|---|
committer | jaseg <git@jaseg.de> | 2022-01-19 00:36:05 +0100 |
commit | 9e86bf6b3e92706c190283af83d71999fee03442 (patch) | |
tree | e3bb083ae976859df953d9d16d2eb5f628f0ab45 /gerbonara/gerber/utils.py | |
parent | d85790bc6d40deb1d52cc5d8a4c178f664635625 (diff) | |
download | gerbonara-9e86bf6b3e92706c190283af83d71999fee03442.tar.gz gerbonara-9e86bf6b3e92706c190283af83d71999fee03442.tar.bz2 gerbonara-9e86bf6b3e92706c190283af83d71999fee03442.zip |
Fix old gerber tests
Diffstat (limited to 'gerbonara/gerber/utils.py')
-rw-r--r-- | gerbonara/gerber/utils.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gerbonara/gerber/utils.py b/gerbonara/gerber/utils.py index 533f0a2..f7df4ed 100644 --- a/gerbonara/gerber/utils.py +++ b/gerbonara/gerber/utils.py @@ -60,6 +60,13 @@ class LengthUnit: else: return id(self) == id(other) + # This class is a singleton, we don't want copies around + def __copy__(self): + return self + + def __deepcopy__(self, memo): + return self + MILLIMETERS_PER_INCH = 25.4 Inch = LengthUnit('inch', 'in', MILLIMETERS_PER_INCH) |