David Chisnall
018fab87bd
Missing part of the NSArray update.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33609 72102866-910b-0410-8b05-ffd578937521
2011-07-23 12:02:04 +00:00
David Chisnall
24d2d9bad2
Added ChangeLog entry from last commit
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33608 72102866-910b-0410-8b05-ffd578937521
2011-07-22 16:08:04 +00:00
David Chisnall
d323a291d8
Change id* -> id[] for OS X 10.7 compatibility in NSArray. This change is required for ARC: now, id* means pointer to a single object, id[] means array.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33607 72102866-910b-0410-8b05-ffd578937521
2011-07-22 16:07:23 +00:00
David Chisnall
2b6608b7fc
Added changelog for last string of commits.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33606 72102866-910b-0410-8b05-ffd578937521
2011-07-22 13:39:39 +00:00
David Chisnall
51446f39de
I give up. No brain left.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33605 72102866-910b-0410-8b05-ffd578937521
2011-07-22 13:37:38 +00:00
David Chisnall
df82f8b96c
Third try.
...
[NSException raise: GSNotEnoughCoffeeException];
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33604 72102866-910b-0410-8b05-ffd578937521
2011-07-22 13:34:08 +00:00
David Chisnall
eb32254242
Add missing #import.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33603 72102866-910b-0410-8b05-ffd578937521
2011-07-22 13:27:04 +00:00
David Chisnall
4b027a2106
Stub for NSRegularExpression when a compatible version of ICU is not present.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33602 72102866-910b-0410-8b05-ffd578937521
2011-07-22 13:23:11 +00:00
David Chisnall
6b632d32d4
Added ChangeLog entry from last commit
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33601 72102866-910b-0410-8b05-ffd578937521
2011-07-21 13:18:21 +00:00
David Chisnall
d9fda65728
Added NSRegularExpressionSearch (10.7) support to NSString.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33600 72102866-910b-0410-8b05-ffd578937521
2011-07-21 13:17:27 +00:00
Eric Wasylishen
5c802d5d57
* Source/NSNumberFormatter.m
...
(-attributedStringForObjectValue:withDefaultAttributes:):
Guard against initializing an NSAttributedString with a nil string.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33596 72102866-910b-0410-8b05-ffd578937521
2011-07-21 01:43:07 +00:00
Eric Wasylishen
e626936660
* Source/GSAttributedString.m: Throw an exception if the string object
...
passed to -initWithString:attributes: doesn't respond to -length, or if
it is nil. This is the same behaviour as OS X.
* Source/NSAttributedString.m (-init): Call -initWithString:attributes:
with @"" instead of nil, since passing nil now causes an exception
to be thrown.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33595 72102866-910b-0410-8b05-ffd578937521
2011-07-21 01:23:08 +00:00
Richard Frith-MacDonald
12dee189f3
try to ensure that including objc/runtime.h always works to get the new API.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33583 72102866-910b-0410-8b05-ffd578937521
2011-07-19 09:38:51 +00:00
Richard Frith-MacDonald
4a5cb96bef
For the avoidance of confusion, remove references to obsolete header.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33562 72102866-910b-0410-8b05-ffd578937521
2011-07-15 13:53:45 +00:00
Richard Frith-MacDonald
44979bb7f4
fix faulty assert
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33560 72102866-910b-0410-8b05-ffd578937521
2011-07-15 13:46:51 +00:00
Richard Frith-MacDonald
497cb2af93
ssh handshake improvements and consmetic tweaks
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33535 72102866-910b-0410-8b05-ffd578937521
2011-07-12 11:40:15 +00:00
David Chisnall
a64f21744d
Do the things from the last commit in the correct order.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33523 72102866-910b-0410-8b05-ffd578937521
2011-07-11 15:12:47 +00:00
David Chisnall
c2d351a0d2
Added ChangeLog entry from last commit
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33522 72102866-910b-0410-8b05-ffd578937521
2011-07-11 14:31:55 +00:00
David Chisnall
6893ce1a95
Lazily initialize POSIX threads, matching OS X behaviour and stopping us from crashing when calling autorelease from a thread that was not previously registered explicitly (yuck!)
...
Also do some quite hacky (and not totally correct) things to try to make sure that we aren't confused into thinking that the first NSThread is the main thread, if it's created on a separate thread. Currently only supported on FreeBSD and OpenBSD.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33521 72102866-910b-0410-8b05-ffd578937521
2011-07-11 14:31:36 +00:00
David Chisnall
72b55444fb
Added some tests for lazy allocated thread behaviour.
...
These show deviation from OS X behaviour (the first test passes by accident - it's actually doing the wrong thing in two different ways that cancel each other out).
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33520 72102866-910b-0410-8b05-ffd578937521
2011-07-11 14:07:16 +00:00
David Chisnall
c425bca5d4
Added ChangeLog entry from last commit
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33518 72102866-910b-0410-8b05-ffd578937521
2011-07-11 12:37:06 +00:00
David Chisnall
26b91d9bcd
[NSNumber -init] should not destroy itself when called as [super init]. This behaviour was breaking anything that subclassed NSNumber in user code (e.g. PyObjC).
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33517 72102866-910b-0410-8b05-ffd578937521
2011-07-11 12:36:04 +00:00
Fred Kiefer
866c1dfcb4
* Source/GSLocale.m (GSLanguageFromLocale): Handle local "C.UTF-8"
...
correctly. Needed for Cygwin.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33516 72102866-910b-0410-8b05-ffd578937521
2011-07-11 11:55:35 +00:00
Fred Kiefer
ef1ce8744b
* config/config.ffi.c: Move declaration of g_dbl to begin of function.
...
Patch by Sebastian Reitenbach <sebastia@l00-bugdead-prods.de>
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33515 72102866-910b-0410-8b05-ffd578937521
2011-07-11 11:30:50 +00:00
Fred Kiefer
9c39943894
Support the OpenSuse key TIMEZONE in /etc/sysconfig/clock.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33512 72102866-910b-0410-8b05-ffd578937521
2011-07-11 09:35:54 +00:00
Wolfgang Lux
f9f1f879f4
Override NSObject +zone to ensure that -zone returns a valid zone
...
pointer when it is called on a class object.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33498 72102866-910b-0410-8b05-ffd578937521
2011-07-10 14:48:26 +00:00
David Chisnall
6bf1350874
Silence type errors by declaring the correct superclass of GSPlaceholderString.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33481 72102866-910b-0410-8b05-ffd578937521
2011-07-07 12:32:59 +00:00
David Chisnall
540e690dc5
Don't DESTROY() the placeholder string - that doesn't destroy it (since it overrides -release to do nothing), it just makes it unreachable.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33480 72102866-910b-0410-8b05-ffd578937521
2011-07-07 12:32:05 +00:00
David Chisnall
99141c2dc1
Fix a memory leak that valgrind spotted.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33479 72102866-910b-0410-8b05-ffd578937521
2011-07-07 12:30:10 +00:00
David Chisnall
0618607b3a
Use -retainCount instead of NSExtraRefCount() in gs_weak_load() so we can support objects that define a custom retain / release mechanism in weak variables.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33478 72102866-910b-0410-8b05-ffd578937521
2011-07-07 12:29:54 +00:00
Fred Kiefer
1334a3b371
Remove references to obsolete directory Headers/Additions.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33462 72102866-910b-0410-8b05-ffd578937521
2011-07-05 08:40:34 +00:00
Fred Kiefer
c0fac74ded
* Headers/GNUstepBase/GNUstep.h: Define the __has_feature macro,
...
as this file may be used without preface.h being included first.
Fixes bug #33708 . Patch by Tim Kack <timkack@gmail.com>.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33461 72102866-910b-0410-8b05-ffd578937521
2011-07-05 08:20:10 +00:00
David Chisnall
35f66911a8
Fix typo NS -> GS. We don't actually want NSAllocateObject to call NSAllocateObject...
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33458 72102866-910b-0410-8b05-ffd578937521
2011-07-04 21:23:26 +00:00
David Chisnall
6fc0ff0ab8
Added ChangeLog entry from last commit
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33447 72102866-910b-0410-8b05-ffd578937521
2011-07-04 11:31:57 +00:00
David Chisnall
2a2d7339d1
Switch the order of the reference count and the zone so that the reference count (in reference counted mode) is always immediately in front of the object. Please test this!!
...
Opt NSObject into the fast path for ARC. ARC will now not call the retain / release / autorelease methods on NSObject or any classes that inherit their implementation of these methods from NSObject. In quick and dirty testing, this gives about a 10-20% speedup.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33446 72102866-910b-0410-8b05-ffd578937521
2011-07-04 11:31:28 +00:00
David Chisnall
38566d1888
Don't call c++ constructors when allocating a class with class_createInstance() - this function calls them itself, and calling them twice is a bad idea.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33436 72102866-910b-0410-8b05-ffd578937521
2011-07-03 11:04:04 +00:00
David Chisnall
05ccee0090
Added ChangeLog entry from last commit
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33426 72102866-910b-0410-8b05-ffd578937521
2011-06-30 14:45:47 +00:00
David Chisnall
56a002dae7
Rewrote NSProxy's -retain / -release to be the same as NSObject, not its own ad-hoc thing.
...
Added declaration of __bridge for use in non-ARC mode.
Tweaked arrayWithObjects:count: to take a const id* parameter, to avoid ARC
treating it as a write-back parameter.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33425 72102866-910b-0410-8b05-ffd578937521
2011-06-30 14:44:58 +00:00
David Chisnall
9d06beffdd
ASSIGN() / RETAIN() and so on macros break the ARC migration tool (it won't rewrite expressions in macros from external headers), so just make them expand to the same thing in ARC mode as in GC mode.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33413 72102866-910b-0410-8b05-ffd578937521
2011-06-29 15:29:40 +00:00
David Chisnall
f196d81788
Added ChangeLog entry from last commit
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33412 72102866-910b-0410-8b05-ffd578937521
2011-06-29 15:21:33 +00:00
David Chisnall
276046a76c
More ARC fixes. We don't want to be using __strong void* in ARC mode (it only makes sense in GC mode and is invalid in ARC mode).
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33411 72102866-910b-0410-8b05-ffd578937521
2011-06-29 15:21:02 +00:00
David Chisnall
faa2c2a63f
Added ChangeLog entry from last commit
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33409 72102866-910b-0410-8b05-ffd578937521
2011-06-29 13:13:37 +00:00
David Chisnall
46b12a71e8
Add support to NSObject for automatically zeroing __weak references when using ARC.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33408 72102866-910b-0410-8b05-ffd578937521
2011-06-29 13:13:15 +00:00
David Chisnall
0548d8b80f
Added ChangeLog entry from last commit
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33404 72102866-910b-0410-8b05-ffd578937521
2011-06-29 11:50:56 +00:00
David Chisnall
3f4dc9a72b
ARC-compatibility tweaks in the headers. ARC will not track objects inside structures and rejects code that uses object types that are not __unsafe_unretained qualified inside structures.
...
This quick fix just added this type qualifier on all such structures. Several of these should probably not be in headers at all.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33403 72102866-910b-0410-8b05-ffd578937521
2011-06-29 11:50:26 +00:00
David Chisnall
3f83dabfaa
Small tweaks to NSGarbageCollector.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33402 72102866-910b-0410-8b05-ffd578937521
2011-06-29 11:46:45 +00:00
Richard Frith-MacDonald
861d46e8db
remove non-portable includes
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33391 72102866-910b-0410-8b05-ffd578937521
2011-06-27 06:04:47 +00:00
Richard Frith-MacDonald
4a29a86319
move comment to be before the method it applies to
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33380 72102866-910b-0410-8b05-ffd578937521
2011-06-26 10:27:52 +00:00
Wolfgang Lux
5f044ea3ee
Fix implementation of NSString -getParagraphStart 🔚 contentsEnd:forRange:.
...
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33379 72102866-910b-0410-8b05-ffd578937521
2011-06-26 10:03:10 +00:00
Wolfgang Lux
5269ba015b
Fix the broken test whether libffi works. The test program always
...
failed, but this failure was masked by an incorrect use of AC_TRY_RUN.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@33376 72102866-910b-0410-8b05-ffd578937521
2011-06-26 09:05:32 +00:00