Skip to content

Commit 5b204e3

Browse files
committed
---
yaml --- r: 345135 b: refs/heads/master c: b4c67c2 h: refs/heads/master i: 345133: aff53f3 345131: 371b820 345127: db6936f 345119: d0a53df
1 parent cffdc08 commit 5b204e3

File tree

4 files changed

+25
-11
lines changed

4 files changed

+25
-11
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: 89ee9c6bcff40e1238d6af5b0b6be806ea4db41d
2+
refs/heads/master: b4c67c2d013a215ae8761944f6fea89900178aac
33
refs/heads/master-next: 203b3026584ecad859eb328b2e12490099409cd5
44
refs/tags/osx-passed: b6b74147ef8a386f532cf9357a1bde006e552c54
55
refs/tags/swift-2.2-SNAPSHOT-2015-12-01-a: 6bb18e013c2284f2b45f5f84f2df2887dc0f7dea

trunk/stdlib/public/runtime/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ set(swift_runtime_sources
5757
ImageInspectionELF.cpp
5858
ImageInspectionCOFF.cpp
5959
KnownMetadata.cpp
60+
LLVMSupport.cpp
6061
Metadata.cpp
6162
MetadataLookup.cpp
6263
MutexPThread.cpp
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
//===--- LLVMSupport.cpp - Swift Language ABI Metadata Support ------------===//
2+
//
3+
// This source file is part of the Swift.org open source project
4+
//
5+
// Copyright (c) 2014 - 2017 Apple Inc. and the Swift project authors
6+
// Licensed under Apache License v2.0 with Runtime Library Exception
7+
//
8+
// See https://swift.org/LICENSE.txt for license information
9+
// See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
10+
//
11+
//===----------------------------------------------------------------------===//
12+
13+
// ADT uses report_bad_alloc_error to report an error when it can't allocate
14+
// elements for a data structure. The swift runtime uses ADT without linking
15+
// against libSupport, so here we provide a stub to make sure we don't fail
16+
// to link.
17+
#if defined(swiftCore_EXPORTS)
18+
namespace llvm {
19+
void __attribute__((__weak__, __visibility__("hidden")))
20+
report_bad_alloc_error(const char *Reason, bool GenCrashDiag) {}
21+
} // end namespace llvm
22+
#endif
23+

trunk/stdlib/public/runtime/Private.h

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -333,14 +333,4 @@ class TypeInfo {
333333

334334
} // end namespace swift
335335

336-
// ADT uses report_bad_alloc_error to report an error when it can't allocate
337-
// elements for a data structure. The swift runtime uses ADT without linking
338-
// against libSupport, so here we provide a stub to make sure we don't fail
339-
// to link. Give it `weak` linkage so, in case the `strong` definition of
340-
// the function is available, that has precedence.
341-
namespace llvm {
342-
__attribute__((weak))
343-
void report_bad_alloc_error(const char *Reason, bool GenCrashDiag) {};
344-
} // end namespace llvm
345-
346336
#endif /* SWIFT_RUNTIME_PRIVATE_H */

0 commit comments

Comments
 (0)