GitHub user rectang opened a pull request:
https://github.com/apache/lucy/pull/43
LUCY-302 NumUtils warnings
In NumberUtils.cfh:
* Widen the array index type for addressing 1-bit, 2-bit, and 4-bit arrays.
* Address a few (false positive) compiler warnings from `-Wconversion`.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/rectang/lucy LUCY-302-numutils-warnings
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/lucy/pull/43.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #43
----
commit fec8c524724c9b257089e9ed9c334cc5c44a4dbc
Author: Marvin Humphrey <[email protected]>
Date: 2016-04-21T23:45:54Z
Change some masks from uint8_t to unsigned int.
commit 42694aa7ce4f94a88c7ffc6359bde4d740f26a33
Author: Marvin Humphrey <[email protected]>
Date: 2016-04-21T23:57:57Z
Use ptrdiff_t to avoid conversion warnings.
commit e691a2223c2e55860804b0e1d65c8fcf2690f597
Author: Marvin Humphrey <[email protected]>
Date: 2016-04-22T00:01:52Z
Perform a safe truncation.
The result being truncated will never be wider than 8 bits.
commit f48cc9edddcb1ff8da2ddb79d4ced3f828f8689b
Author: Marvin Humphrey <[email protected]>
Date: 2016-04-22T00:10:21Z
Rework casting in decode_bigend_u16.
Both versions pass tests, but this doesn't make -Wconversion complain.
commit a311c31918770867929c1174c7d471d36d1c409f
Author: Marvin Humphrey <[email protected]>
Date: 2016-04-22T00:22:37Z
Change tick params for sub-byte arrays to size_t.
Change the tick (array index) parameter for 1-bit, 2-bit, and 4-bit
integer array manipulation routines from uint32_t to size_t.
commit dd6e79c9e36f9ff13c64609dd9aad9feec748b09
Author: Marvin Humphrey <[email protected]>
Date: 2016-04-22T01:11:59Z
Fix warnings regarding NumUtil array manip.
Make appropriate casts or other adjustments to avoid warnings with
regards to NumUtil 1-bit, 2-bit and 4-bit integer array manipulation
routines.
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---