Skip to content

Commit

Permalink
adding public to flags and settings
Browse files Browse the repository at this point in the history
  • Loading branch information
leogdion committed Feb 1, 2025
1 parent 26f154a commit f1fb688
Show file tree
Hide file tree
Showing 514 changed files with 532 additions and 532 deletions.
4 changes: 2 additions & 2 deletions Scripts/soundness/features.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ create_feature_file() {
echo "///" >> "$output_directory/$feature_state_dir/${feature_name}.swift"
echo "/// - SeeAlso: [$proposal_title ($proposal_number)]($html_url)" >> "$output_directory/$feature_state_dir/${feature_name}.swift"
echo "///" >> "$output_directory/$feature_state_dir/${feature_name}.swift"
echo "struct $feature_name : SwiftSettingFeature {" >> "$output_directory/$feature_state_dir/${feature_name}.swift"
echo "public struct $feature_name : SwiftSettingFeature {" >> "$output_directory/$feature_state_dir/${feature_name}.swift"
echo " /// The current state of the feature." >> "$output_directory/$feature_state_dir/${feature_name}.swift"
echo " var featureState : FeatureState {" >> "$output_directory/$feature_state_dir/${feature_name}.swift"
echo " public var featureState : FeatureState {" >> "$output_directory/$feature_state_dir/${feature_name}.swift"
echo " return .$feature_state" >> "$output_directory/$feature_state_dir/${feature_name}.swift"
echo " }" >> "$output_directory/$feature_state_dir/${feature_name}.swift"
echo "}" >> "$output_directory/$feature_state_dir/${feature_name}.swift"
Expand Down
4 changes: 2 additions & 2 deletions Scripts/soundness/unsafeflags.sh
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ while IFS= read -r line; do
capitalized_desc=$(echo "$description" | sed 's/^[[:lower:]]/\U&/')
echo "/// $capitalized_desc"
fi
echo "struct $camel_case_flag: UnsafeFlag { }"
echo "public struct $camel_case_flag: UnsafeFlag { }"
} > "$output_directory/$camel_case_flag.swift"

echo "File '$output_directory/$camel_case_flag.swift' created."
Expand Down Expand Up @@ -138,7 +138,7 @@ while IFS= read -r line; do
capitalized_desc=$(echo "$description" | sed 's/^[[:lower:]]/\U&/')
echo "/// $capitalized_desc"
fi
echo "struct $camel_case_flag: FrontendFlag { }"
echo "public struct $camel_case_flag: FrontendFlag { }"
} > "$output_directory/Frontend/$camel_case_flag.swift"

echo "File '$output_directory/Frontend/$camel_case_flag.swift' created."
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
///
/// - SeeAlso: [Access-level modifiers on import declarations (SE-0409)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0409-access-level-on-imports.md)
///
struct AccessLevelOnImport : SwiftSettingFeature {
public struct AccessLevelOnImport : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .experimental
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
///
/// - SeeAlso: [Allow Protocols to be Nested in Non-Generic Contexts (SE-0404)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0404-nested-protocols.md)
///
struct NestedProtocols : SwiftSettingFeature {
public struct NestedProtocols : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .experimental
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
///
/// - SeeAlso: [Noncopyable Generics (SE-0427)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0427-noncopyable-generics.md)
///
struct NoncopyableGenerics : SwiftSettingFeature {
public struct NoncopyableGenerics : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .experimental
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
///
/// - SeeAlso: [Tuple of value pack expansion (SE-0399)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0399-tuple-of-value-pack-expansion.md)
///
struct VariadicGenerics : SwiftSettingFeature {
public struct VariadicGenerics : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .experimental
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
///
/// - SeeAlso: [Deprecate @UIApplicationMain and @NSApplicationMain (SE-0383)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0383-deprecate-uiapplicationmain-and-nsapplicationmain.md)
///
struct DeprecateApplicationMain : SwiftSettingFeature {
public struct DeprecateApplicationMain : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@
///
/// - SeeAlso: [Remove Actor Isolation Inference caused by Property Wrappers (SE-0401)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0401-remove-property-wrapper-isolation.md)
///
struct DisableOutwardActorInference : SwiftSettingFeature {
public struct DisableOutwardActorInference : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
///
/// - SeeAlso: [Dynamic actor isolation enforcement from non-strict-concurrency contexts (SE-0423)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0423-dynamic-actor-isolation.md)
///
struct DynamicActorIsolation : SwiftSettingFeature {
public struct DynamicActorIsolation : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
///
/// - SeeAlso: [Usability of global-actor-isolated types (SE-0434)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0434-global-actor-isolated-types-usability.md)
///
struct GlobalActorIsolatedTypesUsability : SwiftSettingFeature {
public struct GlobalActorIsolatedTypesUsability : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
///
/// - SeeAlso: [Strict concurrency for global variables (SE-0412)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0412-strict-concurrency-for-global-variables.md)
///
struct GlobalConcurrency : SwiftSettingFeature {
public struct GlobalConcurrency : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
///
/// - SeeAlso: [Importing Forward Declared Objective-C Interfaces and Protocols (SE-0384)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0384-importing-forward-declared-objc-interfaces-and-protocols.md)
///
struct ImportObjcForwardDeclarations : SwiftSettingFeature {
public struct ImportObjcForwardDeclarations : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
///
/// - SeeAlso: [Inferring `Sendable` for methods and key path literals (SE-0418)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0418-inferring-sendable-for-methods.md)
///
struct InferSendableFromCaptures : SwiftSettingFeature {
public struct InferSendableFromCaptures : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
///
/// - SeeAlso: [Access-level modifiers on import declarations (SE-0409)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0409-access-level-on-imports.md)
///
struct InternalImportsByDefault : SwiftSettingFeature {
public struct InternalImportsByDefault : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
///
/// - SeeAlso: [Isolated default value expressions (SE-0411)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0411-isolated-default-values.md)
///
struct IsolatedDefaultValues : SwiftSettingFeature {
public struct IsolatedDefaultValues : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
///
/// - SeeAlso: [Member import visibility (SE-0444)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0444-member-import-visibility.md)
///
struct MemberImportVisibility : SwiftSettingFeature {
public struct MemberImportVisibility : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
///
/// - SeeAlso: [Nonescapable Types (SE-0446)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0446-non-escapable.md)
///
struct NonescapableTypes : SwiftSettingFeature {
public struct NonescapableTypes : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@
///
/// - SeeAlso: [Region based Isolation (SE-0414)](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0414-region-based-isolation.md)
///
struct RegionBasedIsolation : SwiftSettingFeature {
public struct RegionBasedIsolation : SwiftSettingFeature {
/// The current state of the feature.
var featureState : FeatureState {
public var featureState : FeatureState {
return .upcoming
}
}
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-application-extension`
/// Restrict code to those available for App Extensions
struct ApplicationExtension: UnsafeFlag { }
public struct ApplicationExtension: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-application-extension-library`
/// Restrict code to those available for App Extension Libraries
struct ApplicationExtensionLibrary: UnsafeFlag { }
public struct ApplicationExtensionLibrary: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-assume-single-threaded`
/// Assume that code will be executed in a single-threaded environment
struct AssumeSingleThreaded: UnsafeFlag { }
public struct AssumeSingleThreaded: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-autolink-force-load`
/// Force ld to link against this module even if no symbols are used
struct AutolinkForceLoad: UnsafeFlag { }
public struct AutolinkForceLoad: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-avoid-emit-module-source-info`
/// don't emit Swift source info file
struct AvoidEmitModuleSourceInfo: UnsafeFlag { }
public struct AvoidEmitModuleSourceInfo: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-cache-compile-job`
/// Enable compiler caching
struct CacheCompileJob: UnsafeFlag { }
public struct CacheCompileJob: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-cache-disable-replay`
/// Skip loading the compilation result from cache
struct CacheDisableReplay: UnsafeFlag { }
public struct CacheDisableReplay: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-check-api-availability-only`
/// Deprecated, has no effect
struct CheckApiAvailabilityOnly: UnsafeFlag { }
public struct CheckApiAvailabilityOnly: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-color-diagnostics`
/// Print diagnostics in color
struct ColorDiagnostics: UnsafeFlag { }
public struct ColorDiagnostics: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-continue-building-after-errors`
/// Continue building, even after errors are encountered
struct ContinueBuildingAfterErrors: UnsafeFlag { }
public struct ContinueBuildingAfterErrors: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-cross-module-optimization`
/// Perform cross-module optimization
struct CrossModuleOptimization: UnsafeFlag { }
public struct CrossModuleOptimization: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-debug-diagnostic-names`
/// Include diagnostic names when printing
struct DebugDiagnosticNames: UnsafeFlag { }
public struct DebugDiagnosticNames: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-debug-info-store-invocation`
/// Emit the compiler invocation in the debug info.
struct DebugInfoStoreInvocation: UnsafeFlag { }
public struct DebugInfoStoreInvocation: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-actor-data-race-checks`
/// Disable runtime checks for actor data races
struct DisableActorDataRaceChecks: UnsafeFlag { }
public struct DisableActorDataRaceChecks: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-autolinking-runtime-compatibility`
/// Do not use autolinking for runtime compatibility libraries
struct DisableAutolinkingRuntimeCompatibility: UnsafeFlag { }
public struct DisableAutolinkingRuntimeCompatibility: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-autolinking-runtime-compatibility-concurrency`
/// Do not use autolinking for the concurrency runtime compatibility library
struct DisableAutolinkingRuntimeCompatibilityConcurrency: UnsafeFlag { }
public struct DisableAutolinkingRuntimeCompatibilityConcurrency: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-autolinking-runtime-compatibility-dynamic-replacements`
/// Do not use autolinking for the dynamic replacement runtime compatibility library
struct DisableAutolinkingRuntimeCompatibilityDynamicReplacements: UnsafeFlag { }
public struct DisableAutolinkingRuntimeCompatibilityDynamicReplacements: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-batch-mode`
/// Disable combining frontend jobs into batches
struct DisableBatchMode: UnsafeFlag { }
public struct DisableBatchMode: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-bridging-pch`
/// Disable automatic generation of bridging PCH files
struct DisableBridgingPch: UnsafeFlag { }
public struct DisableBridgingPch: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-clang-target`
/// Disable a separately specified target triple for Clang instance to use
struct DisableClangTarget: UnsafeFlag { }
public struct DisableClangTarget: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-cmo`
/// Disable cross-module optimization
struct DisableCmo: UnsafeFlag { }
public struct DisableCmo: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-dynamic-actor-isolation`
/// Disable dynamic actor isolation checks
struct DisableDynamicActorIsolation: UnsafeFlag { }
public struct DisableDynamicActorIsolation: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-incremental-imports`
/// Disable cross-module incremental build metadata and driver scheduling for Swift modules
struct DisableIncrementalImports: UnsafeFlag { }
public struct DisableIncrementalImports: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-migrator-fixits`
/// Disable the Migrator phase which automatically applies fix-its
struct DisableMigratorFixits: UnsafeFlag { }
public struct DisableMigratorFixits: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-only-one-dependency-file`
/// Disables incremental build optimization that only produces one dependencies file
struct DisableOnlyOneDependencyFile: UnsafeFlag { }
public struct DisableOnlyOneDependencyFile: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-sandbox`
/// Disable using the sandbox when executing subprocesses
struct DisableSandbox: UnsafeFlag { }
public struct DisableSandbox: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disable-swift-bridge-attr`
/// Disable using the swift bridge attribute
struct DisableSwiftBridgeAttr: UnsafeFlag { }
public struct DisableSwiftBridgeAttr: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-disallow-use-new-driver`
/// Disable using new swift-driver
struct DisallowUseNewDriver: UnsafeFlag { }
public struct DisallowUseNewDriver: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-driver-always-rebuild-dependents`
/// Always rebuild dependents of files that have been modified
struct DriverAlwaysRebuildDependents: UnsafeFlag { }
public struct DriverAlwaysRebuildDependents: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-driver-emit-fine-grained-dependency-dot-file-after-every-import`
/// Emit dot files every time driver imports an fine-grained swiftdeps file.
struct DriverEmitFineGrainedDependencyDotFileAfterEveryImport: UnsafeFlag { }
public struct DriverEmitFineGrainedDependencyDotFileAfterEveryImport: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-driver-force-response-files`
/// Force the use of response files for testing
struct DriverForceResponseFiles: UnsafeFlag { }
public struct DriverForceResponseFiles: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-driver-print-actions`
/// Dump list of actions to perform
struct DriverPrintActions: UnsafeFlag { }
public struct DriverPrintActions: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-driver-print-bindings`
/// Dump list of job inputs and outputs
struct DriverPrintBindings: UnsafeFlag { }
public struct DriverPrintBindings: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-driver-print-derived-output-file-map`
/// Dump the contents of the derived output file map
struct DriverPrintDerivedOutputFileMap: UnsafeFlag { }
public struct DriverPrintDerivedOutputFileMap: UnsafeFlag { }
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/// Passes the flag `-driver-print-graphviz`
/// Write the job graph as a graphviz file
struct DriverPrintGraphviz: UnsafeFlag { }
public struct DriverPrintGraphviz: UnsafeFlag { }
Loading

0 comments on commit f1fb688

Please sign in to comment.