Skip to content

Commit 50faff5

Browse files
committed
Merge pull request swiftlang#29 from seabaylea/queue_concurrent
Initialise dispatch_queue_attr_concurrent on Linux
2 parents 06d7615 + 0ac830f commit 50faff5

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/init.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -260,6 +260,13 @@ const struct dispatch_queue_attr_s _dispatch_queue_attrs[]
260260
DISPATCH_QUEUE_ATTR_QOS_INITIALIZER(USER_INTERACTIVE),
261261
};
262262

263+
// _dispatch_queue_attr_concurrent is aliased using libdispatch.aliases
264+
// and the -alias_list linker option on Darwin but needs to be done manually
265+
// for other platforms.
266+
#ifndef __APPLE__
267+
extern struct dispatch_queue_attr_s _dispatch_queue_attr_concurrent
268+
__attribute__((__alias__("_dispatch_queue_attrs")));
269+
#endif
263270

264271
#pragma mark -
265272
#pragma mark dispatch_vtables

0 commit comments

Comments
 (0)