JuliaArrays/StaticArrays.jl

Provide isless

Open

#367 建立於 2018年2月16日

在 GitHub 查看
 (9 留言) (0 反應) (0 負責人)Julia (839 star) (154 fork)batch import
featuregood first issue

描述

For tuples there is

(1, 2) < (1, 3) #true

Would it make sense to have it for SVectors as well?

SVector(1, 2) < SVector(1, 3) # ERROR: MethodError: no method matching isless(::SVector{2,Int64}, ::SVector{2,Int64})

My use case is to sort a long Vector of small SVector elements.

貢獻者指南