Skip to content

Commit 14729ce

Browse files
committed
---
yaml --- r: 340922 b: refs/heads/rxwei-patch-1 c: ebe0e42 h: refs/heads/master
1 parent d21729d commit 14729ce

File tree

169 files changed

+1241
-2457
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

169 files changed

+1241
-2457
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1015,7 +1015,7 @@ refs/tags/swift-DEVELOPMENT-SNAPSHOT-2018-08-18-a: b10b1fce14385faa6d44f6b933e95
10151015
refs/heads/rdar-43033749-fix-batch-mode-no-diags-swift-5.0-branch: a14e64eaad30de89f0f5f0b2a782eed7ecdcb255
10161016
refs/heads/revert-19006-error-bridging-integer-type: 8a9065a3696535305ea53fe9b71f91cbe6702019
10171017
refs/heads/revert-19050-revert-19006-error-bridging-integer-type: ecf752d54b05dd0a20f510f0bfa54a3fec3bcaca
1018-
refs/heads/rxwei-patch-1: 7e8ce6ce4aa9a7c6a344e334ff200248adce646c
1018+
refs/heads/rxwei-patch-1: ebe0e42461659f73e942431cbc76a5483933709d
10191019
refs/heads/shahmishal-patch-1: e58ec0f7488258d42bef51bc3e6d7b3dc74d7b2a
10201020
refs/heads/typelist-existential: 4046359efd541fb5c72d69a92eefc0a784df8f5e
10211021
refs/tags/swift-4.2-DEVELOPMENT-SNAPSHOT-2018-08-20-a: 4319ba09e4fb8650ee86061075c74a016b6baab9

branches/rxwei-patch-1/CMakeLists.txt

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -621,9 +621,9 @@ endif()
621621
if(SWIFT_HOST_VARIANT_ARCH)
622622
set(SWIFT_HOST_VARIANT_ARCH_default "${SWIFT_HOST_VARIANT_ARCH}")
623623
else()
624-
if(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64|AMD64")
624+
if("${CMAKE_SYSTEM_PROCESSOR}" STREQUAL "x86_64")
625625
set(SWIFT_HOST_VARIANT_ARCH_default "x86_64")
626-
elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64|ARM64")
626+
elseif("${CMAKE_SYSTEM_PROCESSOR}" STREQUAL "aarch64")
627627
set(SWIFT_HOST_VARIANT_ARCH_default "aarch64")
628628
elseif("${CMAKE_SYSTEM_PROCESSOR}" STREQUAL "ppc64")
629629
set(SWIFT_HOST_VARIANT_ARCH_default "powerpc64")
@@ -636,6 +636,8 @@ else()
636636
set(SWIFT_HOST_VARIANT_ARCH_default "armv6")
637637
elseif("${CMAKE_SYSTEM_PROCESSOR}" MATCHES "armv7l|armv7-a")
638638
set(SWIFT_HOST_VARIANT_ARCH_default "armv7")
639+
elseif("${CMAKE_SYSTEM_PROCESSOR}" STREQUAL "AMD64")
640+
set(SWIFT_HOST_VARIANT_ARCH_default "x86_64")
639641
elseif("${CMAKE_SYSTEM_PROCESSOR}" STREQUAL "IA64")
640642
set(SWIFT_HOST_VARIANT_ARCH_default "itanium")
641643
elseif("${CMAKE_SYSTEM_PROCESSOR}" MATCHES "(x86|i686)")
@@ -1082,7 +1084,6 @@ else()
10821084
# ensure we build that when building tools.
10831085
if(SWIFT_INCLUDE_TOOLS)
10841086
add_subdirectory(stdlib/public/Reflection)
1085-
add_subdirectory(stdlib/public/SwiftShims)
10861087
endif()
10871088
endif()
10881089

branches/rxwei-patch-1/cmake/modules/SwiftSharedCMakeConfig.cmake

Lines changed: 25 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -63,36 +63,32 @@ macro(swift_common_standalone_build_config_llvm product)
6363
endif()
6464

6565
if(SWIFT_INCLUDE_TOOLS)
66-
if(LLVM_TABLEGEN)
67-
set(LLVM_TABLEGEN_EXE ${LLVM_TABLEGEN})
68-
else()
69-
if(CMAKE_CROSSCOMPILING)
70-
set(LLVM_NATIVE_BUILD_DIR "${LLVM_BINARY_DIR}/NATIVE")
71-
if(NOT EXISTS "${LLVM_NATIVE_BUILD_DIR}")
72-
message(FATAL_ERROR
73-
"Attempting to cross-compile swift standalone but no native LLVM build
74-
found. Please cross-compile LLVM as well.")
75-
endif()
76-
77-
if(CMAKE_HOST_SYSTEM_NAME MATCHES Windows)
78-
set(HOST_EXECUTABLE_SUFFIX ".exe")
79-
endif()
80-
81-
if(NOT CMAKE_CONFIGURATION_TYPES)
82-
set(LLVM_TABLEGEN_EXE
83-
"${LLVM_NATIVE_BUILD_DIR}/bin/llvm-tblgen${HOST_EXECUTABLE_SUFFIX}")
84-
else()
85-
# NOTE: LLVM NATIVE build is always built Release, as is specified in
86-
# CrossCompile.cmake
87-
set(LLVM_TABLEGEN_EXE
88-
"${LLVM_NATIVE_BUILD_DIR}/Release/bin/llvm-tblgen${HOST_EXECUTABLE_SUFFIX}")
89-
endif()
66+
if(CMAKE_CROSSCOMPILING)
67+
set(LLVM_NATIVE_BUILD_DIR "${LLVM_BINARY_DIR}/NATIVE")
68+
if(NOT EXISTS "${LLVM_NATIVE_BUILD_DIR}")
69+
message(FATAL_ERROR
70+
"Attempting to cross-compile swift standalone but no native LLVM build
71+
found. Please cross-compile LLVM as well.")
72+
endif()
73+
74+
if(CMAKE_HOST_SYSTEM_NAME MATCHES Windows)
75+
set(HOST_EXECUTABLE_SUFFIX ".exe")
76+
endif()
77+
78+
if(NOT CMAKE_CONFIGURATION_TYPES)
79+
set(LLVM_TABLEGEN_EXE
80+
"${LLVM_NATIVE_BUILD_DIR}/bin/llvm-tblgen${HOST_EXECUTABLE_SUFFIX}")
9081
else()
91-
find_program(LLVM_TABLEGEN_EXE "llvm-tblgen" HINTS ${LLVM_TOOLS_BINARY_DIR}
92-
NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH)
93-
if(LLVM_TABLEGEN_EXE STREQUAL "LLVM_TABLEGEN_EXE-NOTFOUND")
94-
message(FATAL_ERROR "Failed to find tablegen in ${LLVM_TOOLS_BINARY_DIR}")
95-
endif()
82+
# NOTE: LLVM NATIVE build is always built Release, as is specified in
83+
# CrossCompile.cmake
84+
set(LLVM_TABLEGEN_EXE
85+
"${LLVM_NATIVE_BUILD_DIR}/Release/bin/llvm-tblgen${HOST_EXECUTABLE_SUFFIX}")
86+
endif()
87+
else()
88+
find_program(LLVM_TABLEGEN_EXE "llvm-tblgen" HINTS ${LLVM_TOOLS_BINARY_DIR}
89+
NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH)
90+
if(LLVM_TABLEGEN_EXE STREQUAL "LLVM_TABLEGEN_EXE-NOTFOUND")
91+
message(FATAL_ERROR "Failed to find tablegen in ${LLVM_TOOLS_BINARY_DIR}")
9692
endif()
9793
endif()
9894
endif()

branches/rxwei-patch-1/include/swift/ABI/Class.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,4 +65,4 @@ inline ObjCClassFlags operator|(ObjCClassFlags lhs, ObjCClassFlags rhs) {
6565

6666
}
6767

68-
#endif // SWIFT_ABI_CLASS_H
68+
#endif /* SWIFT_ABI_CLASS_H */

branches/rxwei-patch-1/include/swift/ABI/HeapObject.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@
1414
//
1515
//===----------------------------------------------------------------------===//
1616

17-
#ifndef SWIFT_ABI_HEAPOBJECT_H
18-
#define SWIFT_ABI_HEAPOBJECT_H
17+
#ifndef __SWIFT_ABI_HEAPOBJECT_H__
18+
#define __SWIFT_ABI_HEAPOBJECT_H__
1919

2020
#include "../../../stdlib/public/SwiftShims/HeapObject.h"
2121

22-
#endif // SWIFT_ABI_HEAPOBJECT_H
22+
#endif // __SWIFT_ABI_HEAPOBJECT_H__

branches/rxwei-patch-1/include/swift/ABI/KeyPath.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@
1414
//
1515
//===----------------------------------------------------------------------===//
1616

17-
#ifndef SWIFT_ABI_KEYPATH_H
18-
#define SWIFT_ABI_KEYPATH_H
17+
#ifndef __SWIFT_ABI_KEYPATH_H__
18+
#define __SWIFT_ABI_KEYPATH_H__
1919

2020
// We include the basic constants in a shim header so that it can be shared with
2121
// the Swift implementation in the standard library.
@@ -235,4 +235,4 @@ class KeyPathComponentHeader {
235235

236236
}
237237

238-
#endif // SWIFT_ABI_KEYPATH_H
238+
#endif

branches/rxwei-patch-1/include/swift/ABI/Metadata.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4442,4 +4442,4 @@ class DynamicReplacementScope
44424442

44434443
#pragma clang diagnostic pop
44444444

4445-
#endif // SWIFT_ABI_METADATA_H
4445+
#endif /* SWIFT_ABI_METADATA_H */

branches/rxwei-patch-1/include/swift/ABI/MetadataValues.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1752,4 +1752,4 @@ class IntegerLiteralFlags {
17521752

17531753
} // end namespace swift
17541754

1755-
#endif // SWIFT_ABI_METADATAVALUES_H
1755+
#endif /* SWIFT_ABI_METADATAVALUES_H */

branches/rxwei-patch-1/include/swift/ABI/System.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@
1414
//
1515
//===----------------------------------------------------------------------===//
1616

17-
#ifndef SWIFT_ABI_SYSTEM_H
18-
#define SWIFT_ABI_SYSTEM_H
17+
#ifndef __SWIFT_ABI_SYSTEM_H__
18+
#define __SWIFT_ABI_SYSTEM_H__
1919

2020
#include "../../../stdlib/public/SwiftShims/System.h"
2121

22-
#endif // SWIFT_ABI_SYSTEM_H
22+
#endif // __SWIFT_ABI_SYSTEM_H__

branches/rxwei-patch-1/include/swift/ABI/TypeIdentity.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,4 +215,4 @@ class ParsedTypeIdentity {
215215

216216
} // end namespace swift
217217

218-
#endif // SWIFT_ABI_TYPEIDENTITY_H
218+
#endif /* SWIFT_ABI_TYPEIDENTITY_H */

branches/rxwei-patch-1/include/swift/AST/ASTDemangler.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
//
2020
//===----------------------------------------------------------------------===//
2121

22-
#ifndef SWIFT_AST_ASTDEMANGLER_H
23-
#define SWIFT_AST_ASTDEMANGLER_H
22+
#ifndef __SWIFT_AST_ASTDEMANGLER_H__
23+
#define __SWIFT_AST_ASTDEMANGLER_H__
2424

2525
#include "llvm/ADT/ArrayRef.h"
2626
#include "llvm/ADT/StringRef.h"
@@ -185,4 +185,4 @@ class ASTBuilder {
185185

186186
} // namespace swift
187187

188-
#endif // SWIFT_AST_ASTDEMANGLER_H
188+
#endif // __SWIFT_AST_ASTDEMANGLER_H__

branches/rxwei-patch-1/include/swift/AST/ASTMangler.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
//
1111
//===----------------------------------------------------------------------===//
1212

13-
#ifndef SWIFT_AST_ASTMANGLER_H
14-
#define SWIFT_AST_ASTMANGLER_H
13+
#ifndef __SWIFT_AST_ASTMANGLER_H__
14+
#define __SWIFT_AST_ASTMANGLER_H__
1515

1616
#include "swift/Basic/Mangler.h"
1717
#include "swift/AST/Types.h"
@@ -350,4 +350,4 @@ class ASTMangler : public Mangler {
350350
} // end namespace Mangle
351351
} // end namespace swift
352352

353-
#endif // SWIFT_AST_ASTMANGLER_H
353+
#endif // __SWIFT_AST_ASTMANGLER_H__

branches/rxwei-patch-1/include/swift/AST/ASTPrinter.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,7 @@ class ASTPrinter {
286286

287287
/// To sanitize a malformed utf8 string to a well-formed one.
288288
static std::string sanitizeUtf8(StringRef Text);
289+
static ValueDecl* findConformancesWithDocComment(ValueDecl *VD);
289290

290291
private:
291292
virtual void anchor();

branches/rxwei-patch-1/include/swift/AST/ASTTypeIDs.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,4 @@ class Type;
3838

3939
} // end namespace swift
4040

41-
#endif // SWIFT_AST_ASTTYPEIDS_H
41+
#endif /* SWIFT_AST_ASTTYPEIDS_H */

branches/rxwei-patch-1/include/swift/AST/Comment.h

Lines changed: 9 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -18,26 +18,20 @@
1818

1919
namespace swift {
2020
class Decl;
21-
class TypeDecl;
21+
class DocComment;
2222
struct RawComment;
2323

2424
class DocComment {
2525
const Decl *D;
26-
swift::markup::Document *Doc = nullptr;
27-
swift::markup::CommentParts Parts;
26+
const swift::markup::Document *Doc = nullptr;
27+
const swift::markup::CommentParts Parts;
2828

29+
public:
2930
DocComment(const Decl *D, swift::markup::Document *Doc,
3031
swift::markup::CommentParts Parts)
3132
: D(D), Doc(Doc), Parts(Parts) {}
3233

33-
public:
34-
static DocComment *create(const Decl *D, swift::markup::MarkupContext &MC,
35-
RawComment RC);
36-
37-
void addInheritanceNote(swift::markup::MarkupContext &MC, TypeDecl *base);
38-
3934
const Decl *getDecl() const { return D; }
40-
void setDecl(const Decl *D) { this->D = D; }
4135

4236
const swift::markup::Document *getDocument() const { return Doc; }
4337

@@ -93,23 +87,19 @@ class DocComment {
9387
};
9488

9589
/// Get a parsed documentation comment for the declaration, if there is one.
96-
DocComment *getSingleDocComment(swift::markup::MarkupContext &Context,
97-
const Decl *D);
98-
99-
const Decl *getDocCommentProvidingDecl(const Decl *D);
90+
Optional<DocComment *>getSingleDocComment(swift::markup::MarkupContext &Context,
91+
const Decl *D);
10092

10193
/// Attempt to get a doc comment from the declaration, or other inherited
10294
/// sources, like from base classes or protocols.
103-
DocComment *getCascadingDocComment(swift::markup::MarkupContext &MC,
104-
const Decl *D);
95+
Optional<DocComment *> getCascadingDocComment(swift::markup::MarkupContext &MC,
96+
const Decl *D);
10597

10698
/// Extract comments parts from the given Markup node.
10799
swift::markup::CommentParts
108100
extractCommentParts(swift::markup::MarkupContext &MC,
109101
swift::markup::MarkupASTNode *Node);
110-
111-
/// Extract brief comment from \p RC, and print it to \p OS .
112-
void printBriefComment(RawComment RC, llvm::raw_ostream &OS);
113102
} // namespace swift
114103

115104
#endif // LLVM_SWIFT_AST_COMMENT_H
105+

0 commit comments

Comments
 (0)