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

Fix macro hygiene bug, remove unnecessary compat macros, and deprecated array constructor #354

Merged
merged 4 commits into from
Jan 19, 2017

Conversation

musm
Copy link
Member

@musm musm commented Jan 13, 2017

No description provided.

@musm
Copy link
Member Author

musm commented Jan 13, 2017

For https://github.com/JuliaIO/HDF5.jl/blob/master/src/plain.jl#L2378
I don't know if it's possible to use the array constructors without failures on 0.4 at least. See issue JuliaLang/Compat.jl#303

@yuyichao
Copy link
Contributor

Array{Int}()

@musm
Copy link
Member Author

musm commented Jan 13, 2017

Actually https://github.com/JuliaIO/HDF5.jl/blob/master/src/plain.jl#L2378 should probably be a Ref{HDF5Properties}() instead of 0-dim arrays, does it matter?

@@ -149,6 +151,8 @@ ucoder = read(fr, "ucode")
@assert ucode == ucoder
salut_splitr = read(fr, "salut_split")
@assert salut_splitr == salut_split
salut_splitr = read(fr, "salut_2d")
@assert salut_2d == salut_2d
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not a very strong test?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's the same as every other test in this file. I didn't want to change the spirit of the testing structure.

Copy link
Member Author

@musm musm Jan 14, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The testing infrastructure could use a revamp. Perhaps best left to a different PR.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no, you're testing a == a here, the lhs and rhs should be different variables for this to mean anything (other than maybe a nan check)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's supposed to be salut_2d == salut_splitr it's a typo

@musm
Copy link
Member Author

musm commented Jan 14, 2017

Amazing os x now builds hdf5. not sure what changed, perhaps something on master to fix the issue.

@tkelman
Copy link
Contributor

tkelman commented Jan 14, 2017

does JLD make use of any of the PROPERTIES consts?

@musm
Copy link
Member Author

musm commented Jan 14, 2017

@@ -2145,19 +2145,19 @@ function h5a_get_name(attr_id::Hid)
len = h5a_get_name(attr_id, 0, C_NULL) # order of args differs from {f,i}_get_name
buf = Array(UInt8, len+1)
h5a_get_name(attr_id, len+1, buf)
@compat unsafe_string(buf[1:len])
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a bug. doesn't make sense to unsafe_string an UInt8 array, we want the name

@musm musm changed the title Remove unnecessary compat macros and update deprecated array constructor Fix macro hygiene bug, remove unnecessary compat macros, and deprecated array constructor Jan 15, 2017
@musm
Copy link
Member Author

musm commented Jan 16, 2017

Anything else I need to take care of?

After merging this (when ready) can we please tag a release. Log files on travis are ridiculously long now....

@musm
Copy link
Member Author

musm commented Jan 17, 2017

bump

@musm
Copy link
Member Author

musm commented Jan 17, 2017

are there any active maintainers here other than Tony, a lot of trivial PRs and clean up tasks remain but have not received any attention in months?

@tkelman
Copy link
Contributor

tkelman commented Jan 17, 2017

please don't move code around in the same PR as you make deprecation changes, that's needlessly difficult to review

@musm
Copy link
Member Author

musm commented Jan 17, 2017

You can see the individual commit history for the changes.

@musm
Copy link
Member Author

musm commented Jan 17, 2017

It's better not to squash in this case

@tkelman
Copy link
Contributor

tkelman commented Jan 17, 2017

Still requires actually verifying that you didn't change any of the moved code. That commit is not necessary.

@musm
Copy link
Member Author

musm commented Jan 17, 2017

You can have a little trust in me ;)

@tkelman
Copy link
Contributor

tkelman commented Jan 17, 2017

No, I do not, that's the point. If you want to rearrange code in a way that github can show as a simple code movement it can be done in a different PR.

@musm musm closed this Jan 17, 2017
@musm musm deleted the compat branch January 17, 2017 22:28
@StefanKarpinski
Copy link
Member

I should perhaps point out that @tkelman generally doesn't trust anyone – including me (nor should he). I can attest first hand that this can be very frustrating, but making absolutely sure that things aren't broken rather than just taking it on faith is why @tkelman is such a good release manager and valuable but tough code reviewer. Please don't take it personally or the wrong way!

@musm musm restored the compat branch January 19, 2017 16:54
@musm musm reopened this Jan 19, 2017
@tkelman
Copy link
Contributor

tkelman commented Jan 19, 2017

Thanks for taking out the reorg commit. This was basically ready to go without it. Win32 on 0.4 was a fluke download failure, but it passed on win64 0.4 and win32 0.5 so I'm merging.

@tkelman tkelman merged commit 20e8eb9 into JuliaIO:master Jan 19, 2017
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 this pull request may close these issues.

4 participants