Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Add arithmetic operators for maps #1891
This is a first commit for arithmetics of maps. As suggested by @cdeil we use a general
Tests check that quantities are correctly handled for various geometries and check that a
A proper compatibility check or map geometries will be added later in a subsequent PR.
@registerrier - thanks!
See inline comments.
Just out of curiosity, not really needed:
Does this work also if the map is on the right hand side and the quantity is on the left?
If it does, you could add one test showing that it does (e.g. for +).
+ 4 with a number? Does that work for a unit-less map? Again, if yes, you could add one check that it does.
+ "spam" with a string? Does this give a TypeError?