Commit graph

139 commits

Author SHA1 Message Date
jmdavis
ca68f72060 Further tweaks from review. 2011-12-22 22:27:24 -08:00
jmdavis
a7e665c013 Changed datetime's singletons to use a separate bool for now.
I'll change it back to use double-checked locking once that works with
shared, but the atomicLoading stuff seemed overly complicated and
error-prone for what is supposed to be a temporary workaround for the
issues with shared.
2011-12-22 20:39:09 -08:00
Jonathan M Davis
ea3a33b307 Merge pull request #350 from shoo/fix6642
Issue 6642 - SysTime should not be hasUnsharedAliasing
2011-12-20 23:13:49 -08:00
jmdavis
d3816f156e Changed singletons to use __gshared and atomicLoad and atomicStore.
Apparently. the compiler doesn't insert the correct memory fences for
shared yet, so double-checked locking does work right with shared yet.
This change should be undone (and the singletons changed back to using
shared) once shared has been fixed in the compiler.
2011-12-17 21:49:10 -08:00
jmdavis
56c8acdeb4 Removed static constructors from std.datetime. 2011-12-16 23:53:49 -08:00
k-hara
d2ada0e527 Add "America/Bahia" from/to "Bahia Standard Time"
Related: http://support.microsoft.com/kb/2633952/en-us
2011-12-15 12:19:48 +09:00
shoo
a2eeb11c67 Issue 6642 - SysTime should not be hasUnsharedAliasing
http://d.puremagic.com/issues/show_bug.cgi?id=6642
2011-12-05 23:42:42 +09:00
Andrei Alexandrescu
6ac45d88af Merge pull request #328 from jmdavis/deprecations
Applied deprecations for November 2011.
2011-12-04 13:04:07 -08:00
David Nadlinger
e312f9898b Strict @property syntax compliance.
This enables the test suite to build with the -property switch enabled.

std.cpuid: vendor()/processor() have not been converted to properties in accordance to core.cpuid.
std.xml: Element.text() cannot be a property due to the optional parameter.
2011-12-04 09:56:14 +01:00
Peter Alexander
88ad91f47a Size optimisation of std.datetime (saves 12KB)
Large switch statements have been replaced by data-driven array lookups to reduce the amount of code generated and also improve performance. Using DMD 2.056 on OSX x86 this cuts 12KB off of a Hello World program.

The motivation for this change is to try and reduce the size of small D programs as their large size is a common (and valid) complaint amongst newcomers.
2011-12-01 21:13:16 +00:00
jmdavis
afb5a1c7ce Applied deprecations for November 2011. 2011-11-21 00:24:57 -08:00
simendsjo
fdca5dde0d Bug 4414 has been fixed 2011-11-06 17:01:17 +01:00
dawg
f37038c586 spurious variable in StopWatch.start 2011-10-30 21:19:48 +01:00
jmdavis
256976dddd Removed "scheduled for deprecation" pragmas.
The pragmas have not been as effective as we might have liked, since
they only work with templates and can't tell you where in your code you
need to make changes, and they seemed to have been more annoying to
programmers than helpful, so we're going to discontinue them. We'll
leave them in for stuff that's actually been deprecated until deprecated
has been improved enough to take a message, but we'll leave "scheduled
for deprecation" messages to the documentation and changelog.
2011-10-23 23:11:17 -07:00
jmdavis
1d9e802a77 Updated link to TZ Database. 2011-10-19 20:25:48 -07:00
Walter Bright
a83c651411 remove redundant 'you' from documentation 2011-10-08 13:13:29 -07:00
jmdavis
fba52fbeba Added link to "Introduction to std.datetime" to std.datetime. 2011-10-06 23:52:19 -07:00
k-hara
cce3e38388 Use new std.windows.registry in std.datetime. 2011-10-03 03:34:41 +09:00
jmdavis
429f5b4155 Disabled some locale-dependent tests in std.datetime. 2011-09-30 23:59:05 -07:00
jmdavis
824f441382 Temporarily disable test so that tests pass on FreeBSD. 2011-09-26 02:05:28 -07:00
jmdavis
d087bac970 Fixed DST issues in std.datetime.
1. I fixed some issues surrounding DST switches and added much more
thorough unit tests for testing what happens when a DST switch occurs.

2. I also added utcOffsetAt to TimeZone and utcOffset to SysTime to give
the total UTC offset at a specific time.

3. And last but not least, since the unit tests seem to no longer cause
dmd to run out of memory on Windows, std.datetime's unit tests have been
enabled on Windows.

This also fixes Bug# 6181: http://d.puremagic.com/issues/show_bug.cgi?id=6181
2011-09-17 16:51:41 -07:00
Daniel Murphy
1590a5cc38 Issue 6572 - Deprecate typedef
Remove use of deprecated typedef from phobos.  This mostly consists of changing typedef to alias, and disabling unittests that require typedef.  One change to std.registry is needed to work around a bug in typedef (6571).
2011-08-30 13:22:10 +10:00
k-hara
0a136cc44c Additional fix for 6546 2011-08-24 11:55:37 +09:00
k-hara
5395df09c2 Remove std.datetime.DTRebindable 2011-08-24 11:55:36 +09:00
Lars T. Kyllingstad
ff4fb88db7 Update std.datetime and std.file for new std.path 2011-08-18 08:30:22 +02:00
jmdavis
80975d1088 Fixed std.datetime to use the new endian swapping functions 2011-08-14 17:51:07 -07:00
Andrei Alexandrescu
537c59c79e Merge pull request #178 from jmdavis/deprecation
Deprecated stuff which was scheduled to be deprecated in August 2011.
2011-08-14 11:04:21 -07:00
Andrei Alexandrescu
d1adcfcd23 Merge pull request #188 from venix1/master
GDC Win64 patch for Phobos2
2011-08-13 20:51:16 -07:00
Daniel Green
dcbfae3364 Merge GDC Win64 changes. 2011-08-14 00:52:10 -04:00
jmdavis
0ec7697819 Fixed enum values in std.traits to follow Phobos naming conventions. 2011-08-13 00:14:13 -07:00
jmdavis
db5051a5af Changed "Warning" to "Notice" in deprecation messages.
Hopefully, they don't get confused with compiler warnings this way.
2011-08-09 00:39:27 -07:00
jmdavis
28ccdeb8dd Deprecated old date/time stuff. 2011-08-09 00:22:39 -07:00
jmdavis
2c62451020 Fixed uses of TABLE in std.datetime so that they don't double up anymore. 2011-07-27 23:27:32 -07:00
jmdavis
9fcaa2c187 Adjusted SysTime to properly deal with negative FracSec values.
Before, it wasn't possible to have negative FracSecs (which worked great
for SysTime but not so well for Duration). Now, in order to fix
Duration, negative FracSecs are possible, so SysTime has been changed to
throw if it's given a negative FracSec.
2011-07-10 03:04:30 -07:00
jmdavis
302323559a Revert "not really pure"
This reverts commit 4f28db6ffb.

Since Walter put weakly pure back in, these changes need to be undone.

Conflicts:

	std/datetime.d
2011-07-07 01:40:07 -07:00
jmdavis
09b7cf618b Adjusting deprecation dates for a July release. 2011-07-04 01:46:26 -07:00
Jonathan M Davis
da0fd9dbf8 Merge pull request #101 from jmdavis/string
Improvements for std.string, std.uni, and std.ctype.
2011-07-03 00:12:57 -07:00
jmdavis
88c829ca7f Merge branch 'master' into string 2011-06-29 21:25:39 -07:00
jmdavis
e3a592b126 Merged latest master into branch with std.datetime changes.
Conflicts:
	std/datetime.d
2011-06-26 21:14:16 -07:00
Walter Bright
bb53c94eb5 safe function isn't safe 2011-06-26 20:41:03 -07:00
Walter Bright
4f28db6ffb not really pure 2011-06-25 19:58:09 -07:00
jmdavis
a6ef12b6c9 Renamed endOfMonthDay to daysInMonth.
endOfMonthDay is too close to endOfMonth, and std.date had daysInMonth
(which amounts to the same thing), so I'm renaming endOfMonthDay to
daysInMonth. So, endOfMonthDay is now scheduled for deprecation. I also
adjusted the various deprecation messages related to std.datetime so
that they included the month when the items in question would be deprecated.
2011-06-25 09:03:48 -07:00
jmdavis
dd3a0c20a2 Created std.ascii to replace std.ctype.
All of the new, properly camelcased functions in std.ctype have been
moved to std.ascii, and std.ctype has been scheduled for deprecation.
2011-06-14 04:06:54 -07:00
jmdavis
654f35a677 Replaced calls to std.string and std.ctype's tolower with their toLower counterparts. 2011-06-12 16:59:52 -07:00
jmdavis
19ae2b4998 Replace calls to std.ctype.isdigt with std.ctype.isDigit. 2011-06-12 16:59:51 -07:00
jmdavis
ba7d70b858 Fix for issue 6113.
I really should have made those static constructors shared in the first
place, since immutable class and global variables are implicitly shared.
2011-06-05 23:23:10 -07:00
jmdavis
3b628aeb50 Fix to get around issue# 6013. 2011-05-15 19:18:01 -07:00
jmdavis
cf497ec89a Made a public alias private like it should have been in the first place. 2011-05-15 04:06:28 -07:00
jmdavis
1077af7e27 Fixed a typo in my fix for typos. :( 2011-05-10 19:18:33 -07:00
jmdavis
a7d5e3889e Fixed some typos in std.datetime's documentation. 2011-05-10 19:15:11 -07:00