mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
37 lines
1.1 KiB
Swift
37 lines
1.1 KiB
Swift
//===----------------------------------------------------------------------===//
|
|
//
|
|
// This source file is part of the Swift.org open source project
|
|
//
|
|
// Copyright (c) 2021 Apple Inc. and the Swift project authors
|
|
// Licensed under Apache License v2.0 with Runtime Library Exception
|
|
//
|
|
// See https://swift.org/LICENSE.txt for license information
|
|
// See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
import GenUtils
|
|
|
|
func generateScalarProps(for platform: String) {
|
|
var result = readFile("Input/ScalarPropData.h")
|
|
|
|
generateBinaryProps(for: platform, into: &result)
|
|
generateNumericProps(into: &result)
|
|
generateNameAliasProp(into: &result)
|
|
generateMappingProps(for: platform, into: &result)
|
|
generateNameProp(into: &result)
|
|
generateAgeProp(into: &result)
|
|
generateGeneralCategory(into: &result)
|
|
|
|
result += """
|
|
#endif // #ifndef SCALAR_PROP_DATA_H
|
|
|
|
"""
|
|
|
|
write(result, to: "Output/\(platform)/ScalarPropData.h")
|
|
}
|
|
|
|
for platform in ["Common", "Apple"] {
|
|
generateScalarProps(for: platform)
|
|
}
|