Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add more jl_is_int in julia.h #7288

Closed
armgong opened this issue Jun 17, 2014 · 3 comments · Fixed by #7290
Closed

add more jl_is_int in julia.h #7288

armgong opened this issue Jun 17, 2014 · 3 comments · Fixed by #7290

Comments

@armgong
Copy link
Contributor

armgong commented Jun 17, 2014

julia have many integer type like int8 int16 uint8 uint16,but in julia.h no jl_is_int8 or jl_is_int16,so request add to julia.h

define jl_is_int8(v) jl_typeis(v,jl_int8_type)

define jl_is_int16(v) jl_typeis(v,jl_int16_type)

define jl_is_uint8(v) jl_typeis(v,jl_uint8_type)

define jl_is_uint16(v) jl_typeis(v,jl_uint16_type)

@StefanKarpinski
Copy link
Member

Seems to me that the rhs of each of these is quite easy to write.

@armgong
Copy link
Contributor Author

armgong commented Jun 17, 2014

yes,it is so easy,I can define these in my c code ,but I think it is better add to julia.h

@tknopp
Copy link
Contributor

tknopp commented Jun 17, 2014

Stefans point was that is so easy that it might not be worth introducing these macros.

But as we already have these functions for int32/int64 I think it is ok to add them for consistency reasons.

JeffBezanson added a commit that referenced this issue Jun 17, 2014
Add jl_is_ for int8/int16/uint8/uint16 (fix #7288)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants