STYLE: Use itk.int64_t and itk.uint64_t instead of if os.name == "nt" - #6767
STYLE: Use itk.int64_t and itk.uint64_t instead of if os.name == "nt"#6767N-Dekker wants to merge 1 commit into
if os.name == "nt"#6767Conversation
Replaced `if os.name == "nt"` statements which used `itk.SL`, `itk.SLL`, `itk.UL`, or `itk.ULL` with the equivalent code, using just `itk.int64_t` or `itk.uint64_t`. Aims to improve code readability and remove OS-specific code. Follow-up to pull request InsightSoftwareConsortium#6762 commit dc0ea28 "ENH: Add CType aliases for numeric types of specific sizes to Python"
hjmjohnson
left a comment
There was a problem hiding this comment.
Thanks! I think this is much cleaner.
|
Does anyone here know, is this a similar case? ITK/Modules/Core/Mesh/wrapping/test/itkMeshArrayPixelTypeTest.py Lines 30 to 34 in f1daa03 What is the meaning of "ULAD"? And then, is (It's not a show-stopper to me, I'm just wondering... 🤔) |
Probably, but I am not entirely sure. PR good even as-is. |
Thanks @dzenanz I see now, the "ULAD check" was introduced by Pranjal (@PranjalSahu) PR #2970 commit 7e59d1b, merged on Dec 17, 2021. You already commented at #2970 (comment)
On my Windows 11 laptop, So in practice, I think |
|
|
It is up to you whether you also want to update the "ULAD check". |
Replaced
if os.name == "nt"statements which useditk.SL,itk.SLL,itk.UL, oritk.ULLwith the equivalent code, using justitk.int64_toritk.uint64_t.Aims to improve code readability and remove OS-specific code.