Download Reference Manual
The Developer's Library for D
About Wiki Forums Source Search Contact

Ticket #1303 (closed defect: fixed)

Opened 3 years ago

Last modified 2 years ago

x86_64 corrections for util.container

Reported by: Cyborg16 Assigned to: stonecobra
Priority: normal Milestone: 0.99.9
Component: Tango Version: 0.99.7 Dominik
Keywords: patch Cc:

Description

I've changed some of the int/uint types used in the new container package to size_t to allow building with gdc 4.1.3 20080623 (debian 0.25-4.1.2-23.1). All the unittests now pass under gdc and dmd 1.035, except for one assertion: math/Probability.d: 713. I also had to adjust the dsss.conf to link some libraries. (Based on svn 3944.)

I changed most instances of int/uint in the modules I changed (those uploaded), but left opApply and SortedMap?'s cmp functions using int. Couldn't work out what some of the functions were for, but never mind ;-)

Attachments

x86_64-changes.tgz (23.3 kB) - added by Cyborg16 on 09/24/08 07:40:11.
x86_64-changes-3977.tgz (25.7 kB) - added by Cyborg16 on 10/07/08 11:14:50.
updated (complete files)
x86_64-partial-diff-r3977 (20.7 kB) - added by Cyborg16 on 10/07/08 11:27:49.
Diff of some files only
x86_64-changes-r3995 (165.9 kB) - added by Cyborg16 on 10/09/08 11:26:48.
full (but not very useful) diff
x86_64-3977.diff (36.2 kB) - added by schveiguy on 10/16/08 12:51:21.
Useful diff file against r3977
x86_64-4055.diff (40.2 kB) - added by Cyborg16 on 11/01/08 09:43:56.
Updated; diff against r4055

Change History

09/24/08 07:40:11 changed by Cyborg16

  • attachment x86_64-changes.tgz added.

09/25/08 13:28:19 changed by kris

Is this purely for the container package, or does this also imply there's a full set of 64bit changes across the library?

10/06/08 02:23:05 changed by kris

can you provide a patch file, instead of a replacement file, please? It's near impossible to see what you changes otherwise :)

10/07/08 11:14:50 changed by Cyborg16

  • attachment x86_64-changes-3977.tgz added.

updated (complete files)

10/07/08 11:27:10 changed by Cyborg16

It only applies to the container package (the rest of tango compiled fine). Almost all it does it change uint to size_t. In one case this does make a function return size_t.max instead of uint.max! I left opApply functions returning int.

Sorry no full diffs because diff won't output useful results for some of those files - no idea why. kdiff3 works nicely though.

10/07/08 11:27:49 changed by Cyborg16

  • attachment x86_64-partial-diff-r3977 added.

Diff of some files only

10/07/08 14:08:05 changed by larsivi

if possible, use "svn diff"

10/09/08 11:26:48 changed by Cyborg16

  • attachment x86_64-changes-r3995 added.

full (but not very useful) diff

10/16/08 11:55:54 changed by Cyborg16

To save bothering about the diff, you can get the same result by replacing all occurrences of int and uint with size_t, except for the return values of opApply. As I said above, this does change the return value of the *Lists' first & last functions (this return value should be noted in the ddoc anyway, being unconventional).

Or mebbe I can just have svn access?

10/16/08 12:38:17 changed by schveiguy

Re: problems with diff

The problem is whitespace differences.

Kris, your files are a mixture of lines having carriage returns or not ;) This should probably be fixed.

I used the following command to ignore whitespace changes (after downgrading to 3977, and using the provided x86_64-changes-3977.tgz source):

svn diff --diff-cmd diff -x -b

The result will be attached as x86_64-3977.diff

Also, a tip to Cyborg, if you use the .diff extension, Trac does syntax highlighting (see attached file).

10/16/08 12:51:21 changed by schveiguy

  • attachment x86_64-3977.diff added.

Useful diff file against r3977

10/16/08 12:53:13 changed by schveiguy

Messed up the command, it should be (to output the right format):

svn diff --diff-cmd diff -x '-b -u'

10/16/08 16:11:01 changed by larsivi

(In [4008]) Fixed eol style for container package, refs #1303

11/01/08 09:43:56 changed by Cyborg16

  • attachment x86_64-4055.diff added.

Updated; diff against r4055

11/01/08 09:51:22 changed by Cyborg16

Thanks schveiguy. Made a few updates. All unittests pass. Should be fine to commit.

btw why were signed ints were used originally? I can't see that it makes a difference unless a negative loadFactor or so is passed.

12/01/08 05:46:09 changed by larsivi

  • owner changed from sean to kris.
  • component changed from Core Functionality to Tango.

01/17/09 19:10:50 changed by kris

  • owner changed from kris to stonecobra.

03/29/09 11:01:12 changed by larsivi

  • milestone changed from 0.99.8 to 0.99.9.

11/08/09 20:13:48 changed by kris

  • status changed from new to closed.
  • resolution set to fixed.

(In [5064]) fixes #1303 :: x86_64 corrections for util.container

Kudos to Cyborg16