Commit graph

63 commits

Author SHA1 Message Date
safety0ff
282e88bc60 Add unittests for bugs which seem to have been fixed over time. 2013-10-03 10:14:24 -04:00
safety0ff
d2b6f04f2f Support degenerate bitfields with fields of length 32 and 64 to match documented constraints. 2013-10-03 10:06:55 -04:00
Hackerpilot
9ecbfa6bc7 Reverted implicit string concatienation changes 2013-07-13 19:42:50 +00:00
Hackerpilot
ae1dcaa3e1 Removed empty declarations. Converted more C-style array declarations to D-style. Removed trailing whitespace 2013-07-13 19:34:37 +00:00
Andrej Mitrovic
4f5079e4f8 Fixes Issue 4124 - Implement toString for BitArray. 2013-06-01 15:40:01 +02:00
Andrej Mitrovic
bd2d3e5fea Detab and strip std.bitmanip. 2013-06-01 04:03:37 +02:00
Diggory Blake
be6f984726 Fixed std.bitmanip unit test so that the intended behaviour of checking both endian types is the actual behaviour 2013-05-27 11:26:48 +01:00
kai
17f3fe27d5 Fix endian issue in std.bitmanip
BitArray uses an array of size_t elements but opEquals() and opCmp()
cast it to an array of ubyte elements. On a big endian architecture
the bytes are accessed in wrong order.
The solution is to always use size_t elements.
2013-04-12 07:11:56 +02:00
Marco Nembrini
3bb400d492 Decommented unittest that was blocked by bug 6354, which has since been fixed. 2012-12-28 00:10:15 +11:00
k-hara
01df2f60be Remove redundant parenthesis for getters, and use assignment syntax for setters 2012-11-23 15:07:17 +09:00
Daniel Murphy
9c50d1c72f Remove variable shadowing in std.bitmanip 2012-10-28 21:55:30 +11:00
Kozzi11
b15c4205da Fixes Issue 8876 - bitfields template generate wrong code 2012-10-24 00:06:25 +02:00
alexrp
d913e07fc5 hash_t -> size_t. 2012-10-15 04:45:17 +02:00
nazriel
72ade9efec Add other types to peek & family 2012-09-17 12:46:39 +00:00
alexrp
85c1f161c0 Adding myself as author to the modules I have contributed to.
This is just me committing to maintain my code additions to
these modules. We should, in general, use these author lists
more so we know who's responsible for the various modules.
2012-07-16 05:31:09 +02:00
Matthias Walter
cf08b3e51a Made BitArray.toHash pure. 2012-06-25 08:34:09 +02:00
Matthias Walter
e99d6cf04a Reverted change in opCmp signature. 2012-06-22 08:42:42 +02:00
Matthias Walter
eb46d99217 Added to BitArray in std.bitmanip:
- const modifiers
- const versions of opApply
- toHash method
- return value for length setter.
2012-06-08 21:34:01 +02:00
jmdavis
9cf1eea338 Added checks to verify indices. 2012-06-07 01:27:25 -07:00
jmdavis
b36b6469e1 Made it possible to give endianness to peek, read, write, and append. 2012-06-06 20:39:50 -07:00
jmdavis
5e24378271 Added peek, read, write, and append to std.bitmanip.
These functions make it easier to manipulate buffers of ubytes which are
meant to be parsed or written to as sequences of larger integral types.
They assume that the buffers hold their data in big endian.
2012-06-06 02:21:33 -07:00
alexrp
aaaca447cc Make generated accessor for bitfields @safe pure nothrow. 2012-05-13 23:14:06 +02:00
alexrp
5abc66aec1 Fix overloads of opCast() on BitArray. 2012-03-20 18:32:16 +01:00
alexrp
d70f621afd Allow casting BitArray to size_t[]. 2012-03-19 02:58:33 +01:00
alexrp
4f8b530ba6 More improvements/fixes to BitArray docs. 2012-03-18 00:17:57 +01:00
alexrp
95da96d352 A few improvements to BitArray docs. 2012-03-17 13:06:50 +01:00
Walter Bright
8cfc0d232b 'is' doesn't work for signalling/quiet nan comparison 2012-01-10 00:03:14 -08:00
Walter Bright
380ae65511 remove empty statements 2011-12-29 00:05:45 -08:00
alexrp
cf9ddf9836 Drop unnecessary version statement and use size_t.sizeof * 8 instead. 2011-11-28 10:21:51 +01:00
alexrp
6460899b8a Use D_LP64 to make bitness-based decisions, not X86(_64). 2011-11-27 16:11:23 +01:00
jmdavis
2d3dc6fabe Made it so that the endian swapping functions work with bool. 2011-08-13 20:05:29 -07:00
Andrei Alexandrescu
dc6c28330c Merge pull request #166 from 9rnsr/bitmanipProperty
Add @property to std.bitmanip
2011-08-08 08:34:18 -07:00
dawg
a91d837754 avoid collision of store name with accessors in single member bitfield 2011-08-08 16:35:42 +02:00
k-hara
15e0e30f17 Merge branch 'master' into bitmanipProperty
Conflicts:
	std/bitmanip.d
2011-08-02 05:12:50 +09:00
k-hara
9780a8bee2 Fix tabs. 2011-08-02 00:27:12 +09:00
k-hara
a4e23d4b2d Add @property annotation for bitfields and BitArray members. 2011-08-02 00:14:09 +09:00
jmdavis
8167a7aedb Fix test breakage due to bug# 6354.
http://d.puremagic.com/issues/show_bug.cgi?id=6354

The test in question should be re-enabled once 6354 has been fixed.
2011-07-31 19:10:18 -07:00
jmdavis
9698cd62dc Some improvements based on review suggestions.
real has been removed, since it makes no sense to swap it if you can't
guarantee that real is the exact same size of the the machine that it's
being passed to.
2011-07-22 22:39:52 -07:00
jmdavis
09f2937aa8 Added functions for swapping endianness to std.bitmanip. 2011-07-22 00:48:15 -07:00
Andrei Alexandrescu
d061f13d34 https://github.com/D-Programming-Language/phobos/pull/23 2011-05-01 12:11:46 -05:00
Walter Bright
046e1b36db add source links 2011-02-06 15:46:50 -08:00
Brad Roberts
f368104f37 A bunch of 64 bit fixes, including disabling tests that don't pass 2010-12-23 20:39:22 +00:00
Walter Bright
b802a9af01 replace template with CTFE function 2010-12-20 08:30:16 +00:00
Brad Roberts
a1d52bdc2b Add support for MODEL=64 to the posix.mak file.
Fix a couple 64 bit issues.
2010-12-04 08:31:35 +00:00
Don Clugston
84477a5d3e Move Boost copyright declaration from ddoc to normal comment. Fixes ugly ddoc output. 2010-11-24 19:34:47 +00:00
Andrei Alexandrescu
3f2b8c12ea 64-bit compatibility work 2010-08-22 20:55:22 +00:00
Masahiro Nakagawa
cab2b77249 opApply's delegate needs to be 'scope' for avoiding heap allocation 2010-05-18 10:58:01 +00:00
Masahiro Nakagawa
a288172908 Add @property to length method. 2010-05-04 21:54:00 +00:00
Walter Bright
d340dab9f3 inout to ref 2009-12-19 07:46:41 +00:00
Walter Bright
1b0d9811c3 fix opEquals type 2009-11-22 08:38:36 +00:00