From 2736e5d471d4228714066c3caf71c860995082bd Mon Sep 17 00:00:00 2001 From: Kyle Date: Sat, 2 Aug 2025 17:56:44 +0800 Subject: [PATCH 1/6] Update OpenGraph_SPI to OpenGraphCxx --- Package.swift | 15 ++++++--------- README.md | 2 +- Scripts/gen_ag_interface_template.sh | 4 ++-- .../Attribute/Attribute/AnyAttribute.swift | 2 +- .../OpenGraph/Attribute/Attribute/Attribute.swift | 2 +- .../OpenGraph/Attribute/Body/AttributeBody.swift | 2 +- Sources/OpenGraph/Attribute/Rule/Rule.swift | 2 +- .../OpenGraph/Attribute/Rule/StatefulRule.swift | 2 +- .../Attribute/RuleContext/AnyRuleContext.swift | 2 +- .../Attribute/RuleContext/RuleContext.swift | 2 +- .../Attribute/Weak/AnyWeakAttribute.swift | 2 +- .../OpenGraph/Attribute/Weak/WeakAttribute.swift | 2 +- Sources/OpenGraph/Export.swift | 2 +- Sources/OpenGraph/Graph/Graph.swift | 2 +- Sources/OpenGraph/Graph/Subgraph.swift | 2 +- Sources/OpenGraph/Runtime/CompareValues.swift | 2 +- Sources/OpenGraph/Runtime/Metadata.swift | 2 +- .../OpenGraph/Runtime/OGTypeApplyEnumData.swift | 2 +- Sources/OpenGraph/Runtime/TupleType.swift | 2 +- .../Attribute/AttributeID.cpp | 0 .../Attribute/AttributeID.hpp | 0 .../Attribute/AttributeType.cpp | 0 .../Attribute/AttributeType.hpp | 0 .../Attribute/OGAttribute.cpp | 0 .../Attribute/OGWeakAttribute.cpp | 0 .../Comparison/OGComparison.cpp | 2 +- .../Comparison/OGComparisonPrivate.h | 2 +- .../Data/ClosureFunction.cpp | 0 .../Data/ClosureFunction.hpp | 0 .../Data/OGUniqueID.c | 2 +- .../{OpenGraph_SPI => OpenGraphCxx}/Data/page.hpp | 2 +- .../Data/page_const.hpp | 2 +- .../{OpenGraph_SPI => OpenGraphCxx}/Data/ptr.hpp | 2 +- .../Data/table.cpp | 2 +- .../{OpenGraph_SPI => OpenGraphCxx}/Data/zone.cpp | 2 +- .../{OpenGraph_SPI => OpenGraphCxx}/Data/zone.hpp | 2 +- .../Debug/OGDebugServer.cpp | 0 .../Debug/og-debug-server.hpp | 0 .../Debug/og-debug-server.mm | 0 .../Graph/Graph.cpp | 2 +- .../Graph/Graph.hpp | 2 +- .../Graph/Graph.mm | 2 +- .../Graph/GraphContext.cpp | 0 .../Graph/GraphDescription.cpp | 2 +- .../Graph/GraphDescription.mm | 2 +- .../Graph/OGGraph.cpp | 0 .../Graph/OGGraphContext.cpp | 0 .../Graph/OGGraphTracing.cpp | 2 +- .../Graph/OGSubgraph.cpp | 0 .../Graph/Subgraph.cpp | 0 .../Graph/Subgraph.hpp | 0 .../Private/CFRuntime.h | 0 .../Runtime/OGTupleType.cpp | 2 +- .../Runtime/OGTypeID.cpp | 2 +- .../Runtime/metadata.cpp | 2 +- .../Runtime/metadata.hpp | 2 +- .../Util/assert.cpp | 0 .../Util/assert.hpp | 2 +- .../{OpenGraph_SPI => OpenGraphCxx}/Util/env.hpp | 0 .../{OpenGraph_SPI => OpenGraphCxx}/Util/log.cpp | 0 .../{OpenGraph_SPI => OpenGraphCxx}/Util/log.hpp | 0 .../Util/realloc_vector.cpp | 0 .../Util/realloc_vector.hpp | 0 .../Vector/vector.hpp | 2 +- .../Vector/vector.tpp | 2 +- .../Version/OGVersion.c | 0 .../include/OGAttribute.h | 2 +- .../include/OGAttributeFlags.h | 2 +- .../include/OGAttributeInfo.h | 0 .../include/OGAttributeType.h | 2 +- .../include/OGAttributeTypeFlags.h | 2 +- .../include/OGBase.h | 2 +- .../include/OGCachedValueOptions.h | 2 +- .../include/OGChangedValueFlags.h | 2 +- .../include/OGComparison.h | 2 +- .../include/OGCounterQueryType.h | 2 +- .../include/OGDebugServer.h | 2 +- .../include/OGGraph.h | 2 +- .../include/OGGraphContext.h | 2 +- .../include/OGGraphDescription.h | 2 +- .../include/OGGraphTracing.h | 2 +- .../include/OGInputOptions.h | 2 +- .../include/OGSearchOptions.h | 2 +- .../include/OGSubgraph.h | 2 +- .../include/OGSwiftSupport.h | 2 +- .../include/OGTargetConditionals.h | 0 .../include/OGTupleType.h | 2 +- .../include/OGTypeID.h | 2 +- .../include/OGUniqueID.h | 2 +- .../include/OGValue.h | 2 +- .../include/OGValueOptions.h | 2 +- .../include/OGValueState.h | 2 +- .../include/OGVersion.h | 2 +- .../include/OGWeakAttribute.h | 2 +- .../include/OpenGraph-umbrella.h | 0 .../include/OpenGraphCxx/table.hpp | 2 +- .../include/module.modulemap | 4 ++-- .../OpenGraphCxxTests.swift} | 8 ++++---- Tests/OpenGraphCxxTests/README.md | 3 +++ Tests/OpenGraph_SPITests/README.md | 3 --- 100 files changed, 83 insertions(+), 86 deletions(-) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Attribute/AttributeID.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Attribute/AttributeID.hpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Attribute/AttributeType.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Attribute/AttributeType.hpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Attribute/OGAttribute.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Attribute/OGWeakAttribute.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Comparison/OGComparison.cpp (98%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Comparison/OGComparisonPrivate.h (98%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Data/ClosureFunction.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Data/ClosureFunction.hpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Data/OGUniqueID.c (92%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Data/page.hpp (94%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Data/page_const.hpp (95%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Data/ptr.hpp (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Data/table.cpp (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Data/zone.cpp (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Data/zone.hpp (98%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Debug/OGDebugServer.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Debug/og-debug-server.hpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Debug/og-debug-server.mm (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/Graph.cpp (98%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/Graph.hpp (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/Graph.mm (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/GraphContext.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/GraphDescription.cpp (97%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/GraphDescription.mm (96%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/OGGraph.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/OGGraphContext.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/OGGraphTracing.cpp (95%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/OGSubgraph.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/Subgraph.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Graph/Subgraph.hpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Private/CFRuntime.h (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Runtime/OGTupleType.cpp (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Runtime/OGTypeID.cpp (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Runtime/metadata.cpp (94%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Runtime/metadata.hpp (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Util/assert.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Util/assert.hpp (93%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Util/env.hpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Util/log.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Util/log.hpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Util/realloc_vector.cpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Util/realloc_vector.hpp (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Vector/vector.hpp (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Vector/vector.tpp (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/Version/OGVersion.c (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGAttribute.h (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGAttributeFlags.h (96%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGAttributeInfo.h (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGAttributeType.h (94%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGAttributeTypeFlags.h (96%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGBase.h (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGCachedValueOptions.h (95%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGChangedValueFlags.h (94%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGComparison.h (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGCounterQueryType.h (96%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGDebugServer.h (97%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGGraph.h (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGGraphContext.h (96%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGGraphDescription.h (98%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGGraphTracing.h (98%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGInputOptions.h (92%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGSearchOptions.h (92%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGSubgraph.h (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGSwiftSupport.h (98%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGTargetConditionals.h (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGTupleType.h (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGTypeID.h (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGUniqueID.h (94%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGValue.h (92%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGValueOptions.h (93%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGValueState.h (92%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGVersion.h (94%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OGWeakAttribute.h (97%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OpenGraph-umbrella.h (100%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/OpenGraphCxx/table.hpp (99%) rename Sources/{OpenGraph_SPI => OpenGraphCxx}/include/module.modulemap (78%) rename Tests/{OpenGraph_SPITests/OpenGraph_SPITests.swift => OpenGraphCxxTests/OpenGraphCxxTests.swift} (63%) create mode 100644 Tests/OpenGraphCxxTests/README.md delete mode 100644 Tests/OpenGraph_SPITests/README.md diff --git a/Package.swift b/Package.swift index b565cbf1..7ea8ae7c 100644 --- a/Package.swift +++ b/Package.swift @@ -136,7 +136,7 @@ if libraryEvolutionCondition { let openGraphTarget = Target.target( name: "OpenGraph", - dependencies: ["OpenGraph_SPI"], + dependencies: ["OpenGraphCxx"], cSettings: sharedCSettings, swiftSettings: sharedSwiftSettings ) @@ -144,7 +144,7 @@ let openGraphTarget = Target.target( // OpenGraph is a C++ & Swift mix target. // The SwiftPM support for such usage is still in progress. let openGraphSPITarget = Target.target( - name: "OpenGraph_SPI", + name: "OpenGraphCxx", cSettings: sharedCSettings + [ .define("__COREFOUNDATION_FORSWIFTFOUNDATIONONLY__", to: "1", .when(platforms: .nonDarwinPlatforms)), ], @@ -170,14 +170,11 @@ let openGraphTestTarget = Target.testTarget( swiftSettings: sharedSwiftSettings ) let openGraphSPITestTarget = Target.testTarget( - name: "OpenGraph_SPITests", + name: "OpenGraphCxxTests", dependencies: [ - "OpenGraph_SPI", + "OpenGraphCxx", ], exclude: ["README.md"], - cSettings: sharedCSettings + [ - .headerSearchPath("../../Sources/OpenGraph_SPI"), - ], swiftSettings: sharedSwiftSettings + [.interoperabilityMode(.Cxx)] ) let openGraphShimsTestTarget = Target.testTarget( @@ -204,8 +201,8 @@ let openGraphCompatibilityTestTarget = Target.testTarget( let package = Package( name: "OpenGraph", products: [ - .library(name: "OpenGraph", type: .dynamic, targets: ["OpenGraph", "OpenGraph_SPI"]), - .library(name: "OpenGraphShims", type: .dynamic, targets: ["OpenGraph", "OpenGraph_SPI", "OpenGraphShims"]), + .library(name: "OpenGraph", type: .dynamic, targets: ["OpenGraph", "OpenGraphCxx"]), + .library(name: "OpenGraphShims", type: .dynamic, targets: ["OpenGraph", "OpenGraphCxx", "OpenGraphShims"]), ], dependencies: [ .package(url: "https://github.com/apple/swift-numerics", from: "1.0.2"), diff --git a/README.md b/README.md index 1db2f5ae..281a58e9 100644 --- a/README.md +++ b/README.md @@ -31,7 +31,7 @@ The current suggested toolchain to build the project is Swift 6.1 / Xcode 16.3. ## Credits -OpenGraph_SPI's Data, Graph, Vector and more is modified based on [Compute](https://github.com/jcmosc/Compute)'s implementations. +OpenGraphCxx's Data, Graph, Vector and more is modified based on [Compute](https://github.com/jcmosc/Compute)'s implementations. ## License diff --git a/Scripts/gen_ag_interface_template.sh b/Scripts/gen_ag_interface_template.sh index ff59fa4f..68a816e7 100755 --- a/Scripts/gen_ag_interface_template.sh +++ b/Scripts/gen_ag_interface_template.sh @@ -14,8 +14,8 @@ swift build -c release -Xswiftc -emit-module-interface -Xswiftc -enable-library- cp .build/release/Modules/OpenGraph.swiftinterface ./template.swiftinterface sed -i '' '1,4d' ./template.swiftinterface -sed -i '' 's/@_exported public import OpenGraph_SPI/@_exported public import AttributeGraph/g' ./template.swiftinterface -sed -i '' 's/OpenGraph_SPI\.//g' ./template.swiftinterface +sed -i '' 's/@_exported public import OpenGraphCxx/@_exported public import AttributeGraph/g' ./template.swiftinterface +sed -i '' 's/OpenGraphCxx\.//g' ./template.swiftinterface sed -i '' 's/OpenGraph/AttributeGraph/g' ./template.swiftinterface sed -i '' 's/OG/AG/g' ./template.swiftinterface diff --git a/Sources/OpenGraph/Attribute/Attribute/AnyAttribute.swift b/Sources/OpenGraph/Attribute/Attribute/AnyAttribute.swift index a9eaef40..4fd87334 100644 --- a/Sources/OpenGraph/Attribute/Attribute/AnyAttribute.swift +++ b/Sources/OpenGraph/Attribute/Attribute/AnyAttribute.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: API complete -public import OpenGraph_SPI +public import OpenGraphCxx extension AnyAttribute { public typealias Flags = OGAttributeTypeFlags diff --git a/Sources/OpenGraph/Attribute/Attribute/Attribute.swift b/Sources/OpenGraph/Attribute/Attribute/Attribute.swift index cfcab2de..e92d2a92 100644 --- a/Sources/OpenGraph/Attribute/Attribute/Attribute.swift +++ b/Sources/OpenGraph/Attribute/Attribute/Attribute.swift @@ -1,4 +1,4 @@ -public import OpenGraph_SPI +public import OpenGraphCxx @frozen @propertyWrapper diff --git a/Sources/OpenGraph/Attribute/Body/AttributeBody.swift b/Sources/OpenGraph/Attribute/Body/AttributeBody.swift index e7919edd..373471cd 100644 --- a/Sources/OpenGraph/Attribute/Body/AttributeBody.swift +++ b/Sources/OpenGraph/Attribute/Body/AttributeBody.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: Complete -public import OpenGraph_SPI +public import OpenGraphCxx public protocol _AttributeBody { static func _destroySelf(_ pointer: UnsafeMutableRawPointer) diff --git a/Sources/OpenGraph/Attribute/Rule/Rule.swift b/Sources/OpenGraph/Attribute/Rule/Rule.swift index afb92e66..6f9df86f 100644 --- a/Sources/OpenGraph/Attribute/Rule/Rule.swift +++ b/Sources/OpenGraph/Attribute/Rule/Rule.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: Complete -public import OpenGraph_SPI +public import OpenGraphCxx public protocol Rule: _AttributeBody { associatedtype Value diff --git a/Sources/OpenGraph/Attribute/Rule/StatefulRule.swift b/Sources/OpenGraph/Attribute/Rule/StatefulRule.swift index 75d5c367..0812eba2 100644 --- a/Sources/OpenGraph/Attribute/Rule/StatefulRule.swift +++ b/Sources/OpenGraph/Attribute/Rule/StatefulRule.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: Complete -public import OpenGraph_SPI +public import OpenGraphCxx public protocol StatefulRule: _AttributeBody { associatedtype Value diff --git a/Sources/OpenGraph/Attribute/RuleContext/AnyRuleContext.swift b/Sources/OpenGraph/Attribute/RuleContext/AnyRuleContext.swift index 89139182..c676a250 100644 --- a/Sources/OpenGraph/Attribute/RuleContext/AnyRuleContext.swift +++ b/Sources/OpenGraph/Attribute/RuleContext/AnyRuleContext.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: Complete -public import OpenGraph_SPI +public import OpenGraphCxx @frozen public struct AnyRuleContext: Equatable { diff --git a/Sources/OpenGraph/Attribute/RuleContext/RuleContext.swift b/Sources/OpenGraph/Attribute/RuleContext/RuleContext.swift index b86c2006..702a9a0e 100644 --- a/Sources/OpenGraph/Attribute/RuleContext/RuleContext.swift +++ b/Sources/OpenGraph/Attribute/RuleContext/RuleContext.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: Complete -public import OpenGraph_SPI +public import OpenGraphCxx @frozen public struct RuleContext: Equatable { diff --git a/Sources/OpenGraph/Attribute/Weak/AnyWeakAttribute.swift b/Sources/OpenGraph/Attribute/Weak/AnyWeakAttribute.swift index a2849009..93bfb484 100644 --- a/Sources/OpenGraph/Attribute/Weak/AnyWeakAttribute.swift +++ b/Sources/OpenGraph/Attribute/Weak/AnyWeakAttribute.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: Complete -public import OpenGraph_SPI +public import OpenGraphCxx public typealias AnyWeakAttribute = OGWeakAttribute diff --git a/Sources/OpenGraph/Attribute/Weak/WeakAttribute.swift b/Sources/OpenGraph/Attribute/Weak/WeakAttribute.swift index eaa99f97..e0334b38 100644 --- a/Sources/OpenGraph/Attribute/Weak/WeakAttribute.swift +++ b/Sources/OpenGraph/Attribute/Weak/WeakAttribute.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: Complete -public import OpenGraph_SPI +public import OpenGraphCxx @frozen @propertyWrapper diff --git a/Sources/OpenGraph/Export.swift b/Sources/OpenGraph/Export.swift index 3c7bc4bf..bd56c5fb 100644 --- a/Sources/OpenGraph/Export.swift +++ b/Sources/OpenGraph/Export.swift @@ -1,4 +1,4 @@ -@_exported public import OpenGraph_SPI +@_exported public import OpenGraphCxx // Align the constant define behavior #if OPENGRAPH_RELEASE_2024 diff --git a/Sources/OpenGraph/Graph/Graph.swift b/Sources/OpenGraph/Graph/Graph.swift index 6c42100d..baec580c 100644 --- a/Sources/OpenGraph/Graph/Graph.swift +++ b/Sources/OpenGraph/Graph/Graph.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: WIP -public import OpenGraph_SPI +public import OpenGraphCxx extension Graph { public static func typeIndex( diff --git a/Sources/OpenGraph/Graph/Subgraph.swift b/Sources/OpenGraph/Graph/Subgraph.swift index f2a2c295..22e5639c 100644 --- a/Sources/OpenGraph/Graph/Subgraph.swift +++ b/Sources/OpenGraph/Graph/Subgraph.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: WIP -public import OpenGraph_SPI +public import OpenGraphCxx extension Subgraph { public func addObserver(_ observer: () -> Void) -> Int { diff --git a/Sources/OpenGraph/Runtime/CompareValues.swift b/Sources/OpenGraph/Runtime/CompareValues.swift index 74d9a330..a5accf54 100644 --- a/Sources/OpenGraph/Runtime/CompareValues.swift +++ b/Sources/OpenGraph/Runtime/CompareValues.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: Complete -public import OpenGraph_SPI +public import OpenGraphCxx @_silgen_name("OGCompareValues") private func OGCompareValues( diff --git a/Sources/OpenGraph/Runtime/Metadata.swift b/Sources/OpenGraph/Runtime/Metadata.swift index e602b40f..9596830a 100644 --- a/Sources/OpenGraph/Runtime/Metadata.swift +++ b/Sources/OpenGraph/Runtime/Metadata.swift @@ -5,7 +5,7 @@ // Audited for RELEASE_2021 // Status: WIP -public import OpenGraph_SPI +public import OpenGraphCxx #if canImport(ObjectiveC) public import Foundation #endif diff --git a/Sources/OpenGraph/Runtime/OGTypeApplyEnumData.swift b/Sources/OpenGraph/Runtime/OGTypeApplyEnumData.swift index bb232190..86392277 100644 --- a/Sources/OpenGraph/Runtime/OGTypeApplyEnumData.swift +++ b/Sources/OpenGraph/Runtime/OGTypeApplyEnumData.swift @@ -4,7 +4,7 @@ // // -// public import OpenGraph_SPI +// public import OpenGraphCxx @discardableResult public func withUnsafePointerToEnumCase( diff --git a/Sources/OpenGraph/Runtime/TupleType.swift b/Sources/OpenGraph/Runtime/TupleType.swift index 46b4685d..ab2e1139 100644 --- a/Sources/OpenGraph/Runtime/TupleType.swift +++ b/Sources/OpenGraph/Runtime/TupleType.swift @@ -5,7 +5,7 @@ // Audited for iOS 18.0 // Status: WIP -public import OpenGraph_SPI +public import OpenGraphCxx // MARK: TupleType diff --git a/Sources/OpenGraph_SPI/Attribute/AttributeID.cpp b/Sources/OpenGraphCxx/Attribute/AttributeID.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Attribute/AttributeID.cpp rename to Sources/OpenGraphCxx/Attribute/AttributeID.cpp diff --git a/Sources/OpenGraph_SPI/Attribute/AttributeID.hpp b/Sources/OpenGraphCxx/Attribute/AttributeID.hpp similarity index 100% rename from Sources/OpenGraph_SPI/Attribute/AttributeID.hpp rename to Sources/OpenGraphCxx/Attribute/AttributeID.hpp diff --git a/Sources/OpenGraph_SPI/Attribute/AttributeType.cpp b/Sources/OpenGraphCxx/Attribute/AttributeType.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Attribute/AttributeType.cpp rename to Sources/OpenGraphCxx/Attribute/AttributeType.cpp diff --git a/Sources/OpenGraph_SPI/Attribute/AttributeType.hpp b/Sources/OpenGraphCxx/Attribute/AttributeType.hpp similarity index 100% rename from Sources/OpenGraph_SPI/Attribute/AttributeType.hpp rename to Sources/OpenGraphCxx/Attribute/AttributeType.hpp diff --git a/Sources/OpenGraph_SPI/Attribute/OGAttribute.cpp b/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Attribute/OGAttribute.cpp rename to Sources/OpenGraphCxx/Attribute/OGAttribute.cpp diff --git a/Sources/OpenGraph_SPI/Attribute/OGWeakAttribute.cpp b/Sources/OpenGraphCxx/Attribute/OGWeakAttribute.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Attribute/OGWeakAttribute.cpp rename to Sources/OpenGraphCxx/Attribute/OGWeakAttribute.cpp diff --git a/Sources/OpenGraph_SPI/Comparison/OGComparison.cpp b/Sources/OpenGraphCxx/Comparison/OGComparison.cpp similarity index 98% rename from Sources/OpenGraph_SPI/Comparison/OGComparison.cpp rename to Sources/OpenGraphCxx/Comparison/OGComparison.cpp index fa497d51..57d2fff4 100644 --- a/Sources/OpenGraph_SPI/Comparison/OGComparison.cpp +++ b/Sources/OpenGraphCxx/Comparison/OGComparison.cpp @@ -1,6 +1,6 @@ // // OGCompareValues.cpp -// OpenGraph_SPI +// OpenGraphCxx #include "OGComparison.h" #include "OGComparisonPrivate.h" diff --git a/Sources/OpenGraph_SPI/Comparison/OGComparisonPrivate.h b/Sources/OpenGraphCxx/Comparison/OGComparisonPrivate.h similarity index 98% rename from Sources/OpenGraph_SPI/Comparison/OGComparisonPrivate.h rename to Sources/OpenGraphCxx/Comparison/OGComparisonPrivate.h index 2981b7e8..e4d408c9 100644 --- a/Sources/OpenGraph_SPI/Comparison/OGComparisonPrivate.h +++ b/Sources/OpenGraphCxx/Comparison/OGComparisonPrivate.h @@ -1,6 +1,6 @@ // // OGComparisonPrivate.h -// OpenGraph_SPI +// OpenGraphCxx // // Audited for 6.5.4 // Status: Complete diff --git a/Sources/OpenGraph_SPI/Data/ClosureFunction.cpp b/Sources/OpenGraphCxx/Data/ClosureFunction.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Data/ClosureFunction.cpp rename to Sources/OpenGraphCxx/Data/ClosureFunction.cpp diff --git a/Sources/OpenGraph_SPI/Data/ClosureFunction.hpp b/Sources/OpenGraphCxx/Data/ClosureFunction.hpp similarity index 100% rename from Sources/OpenGraph_SPI/Data/ClosureFunction.hpp rename to Sources/OpenGraphCxx/Data/ClosureFunction.hpp diff --git a/Sources/OpenGraph_SPI/Data/OGUniqueID.c b/Sources/OpenGraphCxx/Data/OGUniqueID.c similarity index 92% rename from Sources/OpenGraph_SPI/Data/OGUniqueID.c rename to Sources/OpenGraphCxx/Data/OGUniqueID.c index cf4fa810..478c3a91 100644 --- a/Sources/OpenGraph_SPI/Data/OGUniqueID.c +++ b/Sources/OpenGraphCxx/Data/OGUniqueID.c @@ -1,6 +1,6 @@ // // OGUniqueID.c -// OpenGraph_SPI +// OpenGraphCxx // // Audited for iOS 18.0 // Status: Complete diff --git a/Sources/OpenGraph_SPI/Data/page.hpp b/Sources/OpenGraphCxx/Data/page.hpp similarity index 94% rename from Sources/OpenGraph_SPI/Data/page.hpp rename to Sources/OpenGraphCxx/Data/page.hpp index 22c2ce41..23073351 100644 --- a/Sources/OpenGraph_SPI/Data/page.hpp +++ b/Sources/OpenGraphCxx/Data/page.hpp @@ -1,6 +1,6 @@ // // page.hpp -// OpenGraph_SPI +// OpenGraphCxx #ifndef page_hpp #define page_hpp diff --git a/Sources/OpenGraph_SPI/Data/page_const.hpp b/Sources/OpenGraphCxx/Data/page_const.hpp similarity index 95% rename from Sources/OpenGraph_SPI/Data/page_const.hpp rename to Sources/OpenGraphCxx/Data/page_const.hpp index b03ea77c..4cf48bfd 100644 --- a/Sources/OpenGraph_SPI/Data/page_const.hpp +++ b/Sources/OpenGraphCxx/Data/page_const.hpp @@ -1,6 +1,6 @@ // // page_const.hpp -// OpenGraph_SPI +// OpenGraphCxx #ifndef page_const_hpp #define page_const_hpp diff --git a/Sources/OpenGraph_SPI/Data/ptr.hpp b/Sources/OpenGraphCxx/Data/ptr.hpp similarity index 99% rename from Sources/OpenGraph_SPI/Data/ptr.hpp rename to Sources/OpenGraphCxx/Data/ptr.hpp index a96bd559..3feb216a 100644 --- a/Sources/OpenGraph_SPI/Data/ptr.hpp +++ b/Sources/OpenGraphCxx/Data/ptr.hpp @@ -1,6 +1,6 @@ // // ptr.hpp -// OpenGraph_SPI +// OpenGraphCxx // // Status: Complete // Modified from https://github.com/jcmosc/Compute/blob/0a6b21a4cdeb9bbdd95e7e914c4e18bed37a2456/Sources/ComputeCxx/Data/Pointer.h [MIT License] diff --git a/Sources/OpenGraph_SPI/Data/table.cpp b/Sources/OpenGraphCxx/Data/table.cpp similarity index 99% rename from Sources/OpenGraph_SPI/Data/table.cpp rename to Sources/OpenGraphCxx/Data/table.cpp index 955fbee1..11793fe5 100644 --- a/Sources/OpenGraph_SPI/Data/table.cpp +++ b/Sources/OpenGraphCxx/Data/table.cpp @@ -1,6 +1,6 @@ // // table.cpp -// OpenGraph_SPI +// OpenGraphCxx // // Audited for iOS 18.0 // Status: WIP diff --git a/Sources/OpenGraph_SPI/Data/zone.cpp b/Sources/OpenGraphCxx/Data/zone.cpp similarity index 99% rename from Sources/OpenGraph_SPI/Data/zone.cpp rename to Sources/OpenGraphCxx/Data/zone.cpp index a5a878e6..b4c89dcb 100644 --- a/Sources/OpenGraph_SPI/Data/zone.cpp +++ b/Sources/OpenGraphCxx/Data/zone.cpp @@ -1,6 +1,6 @@ // // zone.cpp -// OpenGraph_SPI +// OpenGraphCxx #include "zone.hpp" #include diff --git a/Sources/OpenGraph_SPI/Data/zone.hpp b/Sources/OpenGraphCxx/Data/zone.hpp similarity index 98% rename from Sources/OpenGraph_SPI/Data/zone.hpp rename to Sources/OpenGraphCxx/Data/zone.hpp index 5e5b5ca6..38cd5791 100644 --- a/Sources/OpenGraph_SPI/Data/zone.hpp +++ b/Sources/OpenGraphCxx/Data/zone.hpp @@ -1,6 +1,6 @@ // // zone.hpp -// OpenGraph_SPI +// OpenGraphCxx #ifndef zone_hpp #define zone_hpp diff --git a/Sources/OpenGraph_SPI/Debug/OGDebugServer.cpp b/Sources/OpenGraphCxx/Debug/OGDebugServer.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Debug/OGDebugServer.cpp rename to Sources/OpenGraphCxx/Debug/OGDebugServer.cpp diff --git a/Sources/OpenGraph_SPI/Debug/og-debug-server.hpp b/Sources/OpenGraphCxx/Debug/og-debug-server.hpp similarity index 100% rename from Sources/OpenGraph_SPI/Debug/og-debug-server.hpp rename to Sources/OpenGraphCxx/Debug/og-debug-server.hpp diff --git a/Sources/OpenGraph_SPI/Debug/og-debug-server.mm b/Sources/OpenGraphCxx/Debug/og-debug-server.mm similarity index 100% rename from Sources/OpenGraph_SPI/Debug/og-debug-server.mm rename to Sources/OpenGraphCxx/Debug/og-debug-server.mm diff --git a/Sources/OpenGraph_SPI/Graph/Graph.cpp b/Sources/OpenGraphCxx/Graph/Graph.cpp similarity index 98% rename from Sources/OpenGraph_SPI/Graph/Graph.cpp rename to Sources/OpenGraphCxx/Graph/Graph.cpp index 73c81a6f..55abe35b 100644 --- a/Sources/OpenGraph_SPI/Graph/Graph.cpp +++ b/Sources/OpenGraphCxx/Graph/Graph.cpp @@ -1,6 +1,6 @@ // // Graph.cpp -// OpenGraph_SPI +// OpenGraphCxx #include "Graph.hpp" #include "Subgraph.hpp" diff --git a/Sources/OpenGraph_SPI/Graph/Graph.hpp b/Sources/OpenGraphCxx/Graph/Graph.hpp similarity index 99% rename from Sources/OpenGraph_SPI/Graph/Graph.hpp rename to Sources/OpenGraphCxx/Graph/Graph.hpp index 5921b86d..c6511a37 100644 --- a/Sources/OpenGraph_SPI/Graph/Graph.hpp +++ b/Sources/OpenGraphCxx/Graph/Graph.hpp @@ -1,6 +1,6 @@ // // Graph.hpp -// OpenGraph_SPI +// OpenGraphCxx #ifndef Graph_hpp diff --git a/Sources/OpenGraph_SPI/Graph/Graph.mm b/Sources/OpenGraphCxx/Graph/Graph.mm similarity index 99% rename from Sources/OpenGraph_SPI/Graph/Graph.mm rename to Sources/OpenGraphCxx/Graph/Graph.mm index fd48afaa..b8df9392 100644 --- a/Sources/OpenGraph_SPI/Graph/Graph.mm +++ b/Sources/OpenGraphCxx/Graph/Graph.mm @@ -1,6 +1,6 @@ // // Graph.mm -// OpenGraph_SPI +// OpenGraphCxx #include "Graph.hpp" #include "OGGraphDescription.h" diff --git a/Sources/OpenGraph_SPI/Graph/GraphContext.cpp b/Sources/OpenGraphCxx/Graph/GraphContext.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Graph/GraphContext.cpp rename to Sources/OpenGraphCxx/Graph/GraphContext.cpp diff --git a/Sources/OpenGraph_SPI/Graph/GraphDescription.cpp b/Sources/OpenGraphCxx/Graph/GraphDescription.cpp similarity index 97% rename from Sources/OpenGraph_SPI/Graph/GraphDescription.cpp rename to Sources/OpenGraphCxx/Graph/GraphDescription.cpp index a3b03e7b..e2de2323 100644 --- a/Sources/OpenGraph_SPI/Graph/GraphDescription.cpp +++ b/Sources/OpenGraphCxx/Graph/GraphDescription.cpp @@ -1,6 +1,6 @@ // // GraphDescription.cpp -// OpenGraph_SPI +// OpenGraphCxx #include "OGGraphDescription.h" #include "OGGraph.h" diff --git a/Sources/OpenGraph_SPI/Graph/GraphDescription.mm b/Sources/OpenGraphCxx/Graph/GraphDescription.mm similarity index 96% rename from Sources/OpenGraph_SPI/Graph/GraphDescription.mm rename to Sources/OpenGraphCxx/Graph/GraphDescription.mm index e6f26b87..0c704a85 100644 --- a/Sources/OpenGraph_SPI/Graph/GraphDescription.mm +++ b/Sources/OpenGraphCxx/Graph/GraphDescription.mm @@ -1,6 +1,6 @@ // // GraphDescription.mm -// OpenGraph_SPI +// OpenGraphCxx #include "OGGraphDescription.h" #include "OGGraph.h" diff --git a/Sources/OpenGraph_SPI/Graph/OGGraph.cpp b/Sources/OpenGraphCxx/Graph/OGGraph.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Graph/OGGraph.cpp rename to Sources/OpenGraphCxx/Graph/OGGraph.cpp diff --git a/Sources/OpenGraph_SPI/Graph/OGGraphContext.cpp b/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Graph/OGGraphContext.cpp rename to Sources/OpenGraphCxx/Graph/OGGraphContext.cpp diff --git a/Sources/OpenGraph_SPI/Graph/OGGraphTracing.cpp b/Sources/OpenGraphCxx/Graph/OGGraphTracing.cpp similarity index 95% rename from Sources/OpenGraph_SPI/Graph/OGGraphTracing.cpp rename to Sources/OpenGraphCxx/Graph/OGGraphTracing.cpp index 94a1e40a..45fb3437 100644 --- a/Sources/OpenGraph_SPI/Graph/OGGraphTracing.cpp +++ b/Sources/OpenGraphCxx/Graph/OGGraphTracing.cpp @@ -1,6 +1,6 @@ // // OGGraphTracing.mm -// OpenGraph_SPI +// OpenGraphCxx #include "OGGraphTracing.h" diff --git a/Sources/OpenGraph_SPI/Graph/OGSubgraph.cpp b/Sources/OpenGraphCxx/Graph/OGSubgraph.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Graph/OGSubgraph.cpp rename to Sources/OpenGraphCxx/Graph/OGSubgraph.cpp diff --git a/Sources/OpenGraph_SPI/Graph/Subgraph.cpp b/Sources/OpenGraphCxx/Graph/Subgraph.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Graph/Subgraph.cpp rename to Sources/OpenGraphCxx/Graph/Subgraph.cpp diff --git a/Sources/OpenGraph_SPI/Graph/Subgraph.hpp b/Sources/OpenGraphCxx/Graph/Subgraph.hpp similarity index 100% rename from Sources/OpenGraph_SPI/Graph/Subgraph.hpp rename to Sources/OpenGraphCxx/Graph/Subgraph.hpp diff --git a/Sources/OpenGraph_SPI/Private/CFRuntime.h b/Sources/OpenGraphCxx/Private/CFRuntime.h similarity index 100% rename from Sources/OpenGraph_SPI/Private/CFRuntime.h rename to Sources/OpenGraphCxx/Private/CFRuntime.h diff --git a/Sources/OpenGraph_SPI/Runtime/OGTupleType.cpp b/Sources/OpenGraphCxx/Runtime/OGTupleType.cpp similarity index 99% rename from Sources/OpenGraph_SPI/Runtime/OGTupleType.cpp rename to Sources/OpenGraphCxx/Runtime/OGTupleType.cpp index 22b95809..793c18ee 100644 --- a/Sources/OpenGraph_SPI/Runtime/OGTupleType.cpp +++ b/Sources/OpenGraphCxx/Runtime/OGTupleType.cpp @@ -1,6 +1,6 @@ // // OGTupleType.cpp -// OpenGraph_SPI +// OpenGraphCxx // // Audited for iOS 18.0 // Status: Complete diff --git a/Sources/OpenGraph_SPI/Runtime/OGTypeID.cpp b/Sources/OpenGraphCxx/Runtime/OGTypeID.cpp similarity index 99% rename from Sources/OpenGraph_SPI/Runtime/OGTypeID.cpp rename to Sources/OpenGraphCxx/Runtime/OGTypeID.cpp index 47832805..0394525f 100644 --- a/Sources/OpenGraph_SPI/Runtime/OGTypeID.cpp +++ b/Sources/OpenGraphCxx/Runtime/OGTypeID.cpp @@ -1,6 +1,6 @@ // // OGTypeID.cpp -// OpenGraph_SPI +// OpenGraphCxx // // Audited for iOS 18.0 // Status: WIP diff --git a/Sources/OpenGraph_SPI/Runtime/metadata.cpp b/Sources/OpenGraphCxx/Runtime/metadata.cpp similarity index 94% rename from Sources/OpenGraph_SPI/Runtime/metadata.cpp rename to Sources/OpenGraphCxx/Runtime/metadata.cpp index 0c00d54c..320eb629 100644 --- a/Sources/OpenGraph_SPI/Runtime/metadata.cpp +++ b/Sources/OpenGraphCxx/Runtime/metadata.cpp @@ -1,6 +1,6 @@ // // metadata.cpp -// OpenGraph_SPI +// OpenGraphCxx // // Audited for iOS 18.0 // Status: WIP diff --git a/Sources/OpenGraph_SPI/Runtime/metadata.hpp b/Sources/OpenGraphCxx/Runtime/metadata.hpp similarity index 99% rename from Sources/OpenGraph_SPI/Runtime/metadata.hpp rename to Sources/OpenGraphCxx/Runtime/metadata.hpp index 4bdc860f..dfa51510 100644 --- a/Sources/OpenGraph_SPI/Runtime/metadata.hpp +++ b/Sources/OpenGraphCxx/Runtime/metadata.hpp @@ -1,6 +1,6 @@ // // metadata.hpp -// OpenGraph_SPI +// OpenGraphCxx // // Audited for iOS 18.0 // Status: WIP diff --git a/Sources/OpenGraph_SPI/Util/assert.cpp b/Sources/OpenGraphCxx/Util/assert.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Util/assert.cpp rename to Sources/OpenGraphCxx/Util/assert.cpp diff --git a/Sources/OpenGraph_SPI/Util/assert.hpp b/Sources/OpenGraphCxx/Util/assert.hpp similarity index 93% rename from Sources/OpenGraph_SPI/Util/assert.hpp rename to Sources/OpenGraphCxx/Util/assert.hpp index 525187b8..a2381a53 100644 --- a/Sources/OpenGraph_SPI/Util/assert.hpp +++ b/Sources/OpenGraphCxx/Util/assert.hpp @@ -1,6 +1,6 @@ // // assert.hpp -// OpenGraph_SPI +// OpenGraphCxx #ifndef assert_hpp #define assert_hpp diff --git a/Sources/OpenGraph_SPI/Util/env.hpp b/Sources/OpenGraphCxx/Util/env.hpp similarity index 100% rename from Sources/OpenGraph_SPI/Util/env.hpp rename to Sources/OpenGraphCxx/Util/env.hpp diff --git a/Sources/OpenGraph_SPI/Util/log.cpp b/Sources/OpenGraphCxx/Util/log.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Util/log.cpp rename to Sources/OpenGraphCxx/Util/log.cpp diff --git a/Sources/OpenGraph_SPI/Util/log.hpp b/Sources/OpenGraphCxx/Util/log.hpp similarity index 100% rename from Sources/OpenGraph_SPI/Util/log.hpp rename to Sources/OpenGraphCxx/Util/log.hpp diff --git a/Sources/OpenGraph_SPI/Util/realloc_vector.cpp b/Sources/OpenGraphCxx/Util/realloc_vector.cpp similarity index 100% rename from Sources/OpenGraph_SPI/Util/realloc_vector.cpp rename to Sources/OpenGraphCxx/Util/realloc_vector.cpp diff --git a/Sources/OpenGraph_SPI/Util/realloc_vector.hpp b/Sources/OpenGraphCxx/Util/realloc_vector.hpp similarity index 100% rename from Sources/OpenGraph_SPI/Util/realloc_vector.hpp rename to Sources/OpenGraphCxx/Util/realloc_vector.hpp diff --git a/Sources/OpenGraph_SPI/Vector/vector.hpp b/Sources/OpenGraphCxx/Vector/vector.hpp similarity index 99% rename from Sources/OpenGraph_SPI/Vector/vector.hpp rename to Sources/OpenGraphCxx/Vector/vector.hpp index 161c6968..331c8adb 100644 --- a/Sources/OpenGraph_SPI/Vector/vector.hpp +++ b/Sources/OpenGraphCxx/Vector/vector.hpp @@ -1,6 +1,6 @@ // // vector.hpp -// OpenGraph_SPI +// OpenGraphCxx // // Status: Complete // Modified from https://github.com/jcmosc/Compute/blob/00dfebc2c5852144ac5aada8ebe896b78e5f622a/Sources/ComputeCxx/Vector/Vector.h [MIT License] diff --git a/Sources/OpenGraph_SPI/Vector/vector.tpp b/Sources/OpenGraphCxx/Vector/vector.tpp similarity index 99% rename from Sources/OpenGraph_SPI/Vector/vector.tpp rename to Sources/OpenGraphCxx/Vector/vector.tpp index f11be1e3..98a9a8b7 100644 --- a/Sources/OpenGraph_SPI/Vector/vector.tpp +++ b/Sources/OpenGraphCxx/Vector/vector.tpp @@ -1,6 +1,6 @@ // // vector.hpp -// OpenGraph_SPI +// OpenGraphCxx // // Status: Complete // Modified from https://github.com/jcmosc/Compute/blob/00dfebc2c5852144ac5aada8ebe896b78e5f622a/Sources/ComputeCxx/Vector/Vector.tpp [MIT Lisence] diff --git a/Sources/OpenGraph_SPI/Version/OGVersion.c b/Sources/OpenGraphCxx/Version/OGVersion.c similarity index 100% rename from Sources/OpenGraph_SPI/Version/OGVersion.c rename to Sources/OpenGraphCxx/Version/OGVersion.c diff --git a/Sources/OpenGraph_SPI/include/OGAttribute.h b/Sources/OpenGraphCxx/include/OGAttribute.h similarity index 99% rename from Sources/OpenGraph_SPI/include/OGAttribute.h rename to Sources/OpenGraphCxx/include/OGAttribute.h index 628ac6dd..4514c878 100644 --- a/Sources/OpenGraph_SPI/include/OGAttribute.h +++ b/Sources/OpenGraphCxx/include/OGAttribute.h @@ -1,6 +1,6 @@ // // OGAttribute.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGAttribute_h #define OGAttribute_h diff --git a/Sources/OpenGraph_SPI/include/OGAttributeFlags.h b/Sources/OpenGraphCxx/include/OGAttributeFlags.h similarity index 96% rename from Sources/OpenGraph_SPI/include/OGAttributeFlags.h rename to Sources/OpenGraphCxx/include/OGAttributeFlags.h index 03c89dd6..a73730de 100644 --- a/Sources/OpenGraph_SPI/include/OGAttributeFlags.h +++ b/Sources/OpenGraphCxx/include/OGAttributeFlags.h @@ -1,6 +1,6 @@ // // OGAttributeFlags.h -// OpenGraph_SPI +// OpenGraphCxx // // Audited for RELEASE_2021 // Status: Complete diff --git a/Sources/OpenGraph_SPI/include/OGAttributeInfo.h b/Sources/OpenGraphCxx/include/OGAttributeInfo.h similarity index 100% rename from Sources/OpenGraph_SPI/include/OGAttributeInfo.h rename to Sources/OpenGraphCxx/include/OGAttributeInfo.h diff --git a/Sources/OpenGraph_SPI/include/OGAttributeType.h b/Sources/OpenGraphCxx/include/OGAttributeType.h similarity index 94% rename from Sources/OpenGraph_SPI/include/OGAttributeType.h rename to Sources/OpenGraphCxx/include/OGAttributeType.h index b2c03ab3..0a3dab5e 100644 --- a/Sources/OpenGraph_SPI/include/OGAttributeType.h +++ b/Sources/OpenGraphCxx/include/OGAttributeType.h @@ -1,6 +1,6 @@ // // OGAttributeType.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGAttributeType_h #define OGAttributeType_h diff --git a/Sources/OpenGraph_SPI/include/OGAttributeTypeFlags.h b/Sources/OpenGraphCxx/include/OGAttributeTypeFlags.h similarity index 96% rename from Sources/OpenGraph_SPI/include/OGAttributeTypeFlags.h rename to Sources/OpenGraphCxx/include/OGAttributeTypeFlags.h index 61c09a4f..8382df17 100644 --- a/Sources/OpenGraph_SPI/include/OGAttributeTypeFlags.h +++ b/Sources/OpenGraphCxx/include/OGAttributeTypeFlags.h @@ -1,6 +1,6 @@ // // OGAttributeTypeFlags.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGAttributeTypeFlags_h #define OGAttributeTypeFlags_h diff --git a/Sources/OpenGraph_SPI/include/OGBase.h b/Sources/OpenGraphCxx/include/OGBase.h similarity index 99% rename from Sources/OpenGraph_SPI/include/OGBase.h rename to Sources/OpenGraphCxx/include/OGBase.h index f77340a2..8cec261b 100644 --- a/Sources/OpenGraph_SPI/include/OGBase.h +++ b/Sources/OpenGraphCxx/include/OGBase.h @@ -1,6 +1,6 @@ // // OGBase.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGBase_h #define OGBase_h diff --git a/Sources/OpenGraph_SPI/include/OGCachedValueOptions.h b/Sources/OpenGraphCxx/include/OGCachedValueOptions.h similarity index 95% rename from Sources/OpenGraph_SPI/include/OGCachedValueOptions.h rename to Sources/OpenGraphCxx/include/OGCachedValueOptions.h index b53de723..06721b3b 100644 --- a/Sources/OpenGraph_SPI/include/OGCachedValueOptions.h +++ b/Sources/OpenGraphCxx/include/OGCachedValueOptions.h @@ -1,6 +1,6 @@ // // OGCachedValueOptions.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGCachedValueOptions_h #define OGCachedValueOptions_h diff --git a/Sources/OpenGraph_SPI/include/OGChangedValueFlags.h b/Sources/OpenGraphCxx/include/OGChangedValueFlags.h similarity index 94% rename from Sources/OpenGraph_SPI/include/OGChangedValueFlags.h rename to Sources/OpenGraphCxx/include/OGChangedValueFlags.h index cd7af2a4..5fc347c5 100644 --- a/Sources/OpenGraph_SPI/include/OGChangedValueFlags.h +++ b/Sources/OpenGraphCxx/include/OGChangedValueFlags.h @@ -1,6 +1,6 @@ // // OGChangedValueFlags.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGChangedValueFlags_h #define OGChangedValueFlags_h diff --git a/Sources/OpenGraph_SPI/include/OGComparison.h b/Sources/OpenGraphCxx/include/OGComparison.h similarity index 99% rename from Sources/OpenGraph_SPI/include/OGComparison.h rename to Sources/OpenGraphCxx/include/OGComparison.h index 22e63ab2..271584bf 100644 --- a/Sources/OpenGraph_SPI/include/OGComparison.h +++ b/Sources/OpenGraphCxx/include/OGComparison.h @@ -1,6 +1,6 @@ // // OGComparison.h -// OpenGraph_SPI +// OpenGraphCxx // // Audited for 6.5.4 // Status: Complete diff --git a/Sources/OpenGraph_SPI/include/OGCounterQueryType.h b/Sources/OpenGraphCxx/include/OGCounterQueryType.h similarity index 96% rename from Sources/OpenGraph_SPI/include/OGCounterQueryType.h rename to Sources/OpenGraphCxx/include/OGCounterQueryType.h index ad87b096..d38cb422 100644 --- a/Sources/OpenGraph_SPI/include/OGCounterQueryType.h +++ b/Sources/OpenGraphCxx/include/OGCounterQueryType.h @@ -1,6 +1,6 @@ // // OGCounterQueryType.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGCounterQueryType_h #define OGCounterQueryType_h diff --git a/Sources/OpenGraph_SPI/include/OGDebugServer.h b/Sources/OpenGraphCxx/include/OGDebugServer.h similarity index 97% rename from Sources/OpenGraph_SPI/include/OGDebugServer.h rename to Sources/OpenGraphCxx/include/OGDebugServer.h index 6cc209a7..69a10c41 100644 --- a/Sources/OpenGraph_SPI/include/OGDebugServer.h +++ b/Sources/OpenGraphCxx/include/OGDebugServer.h @@ -1,6 +1,6 @@ // // OGDebugServer.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGDebugServer_h #define OGDebugServer_h diff --git a/Sources/OpenGraph_SPI/include/OGGraph.h b/Sources/OpenGraphCxx/include/OGGraph.h similarity index 99% rename from Sources/OpenGraph_SPI/include/OGGraph.h rename to Sources/OpenGraphCxx/include/OGGraph.h index 49c67a72..9cd6831e 100644 --- a/Sources/OpenGraph_SPI/include/OGGraph.h +++ b/Sources/OpenGraphCxx/include/OGGraph.h @@ -1,6 +1,6 @@ // // OGGraph.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGGraph_h #define OGGraph_h diff --git a/Sources/OpenGraph_SPI/include/OGGraphContext.h b/Sources/OpenGraphCxx/include/OGGraphContext.h similarity index 96% rename from Sources/OpenGraph_SPI/include/OGGraphContext.h rename to Sources/OpenGraphCxx/include/OGGraphContext.h index b078e42b..43faf5ae 100644 --- a/Sources/OpenGraph_SPI/include/OGGraphContext.h +++ b/Sources/OpenGraphCxx/include/OGGraphContext.h @@ -1,6 +1,6 @@ // // OGGraphContext.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGGraphContext_h #define OGGraphContext_h diff --git a/Sources/OpenGraph_SPI/include/OGGraphDescription.h b/Sources/OpenGraphCxx/include/OGGraphDescription.h similarity index 98% rename from Sources/OpenGraph_SPI/include/OGGraphDescription.h rename to Sources/OpenGraphCxx/include/OGGraphDescription.h index b755d784..cc07e1c9 100644 --- a/Sources/OpenGraph_SPI/include/OGGraphDescription.h +++ b/Sources/OpenGraphCxx/include/OGGraphDescription.h @@ -1,6 +1,6 @@ // // OGGraphDescription.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGGraphDescription_h #define OGGraphDescription_h diff --git a/Sources/OpenGraph_SPI/include/OGGraphTracing.h b/Sources/OpenGraphCxx/include/OGGraphTracing.h similarity index 98% rename from Sources/OpenGraph_SPI/include/OGGraphTracing.h rename to Sources/OpenGraphCxx/include/OGGraphTracing.h index 647afb1a..d6b876f0 100644 --- a/Sources/OpenGraph_SPI/include/OGGraphTracing.h +++ b/Sources/OpenGraphCxx/include/OGGraphTracing.h @@ -1,6 +1,6 @@ // // OGGraphTracing.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGGraphTracing_hpp #define OGGraphTracing_hpp diff --git a/Sources/OpenGraph_SPI/include/OGInputOptions.h b/Sources/OpenGraphCxx/include/OGInputOptions.h similarity index 92% rename from Sources/OpenGraph_SPI/include/OGInputOptions.h rename to Sources/OpenGraphCxx/include/OGInputOptions.h index d71741fc..6c2607d0 100644 --- a/Sources/OpenGraph_SPI/include/OGInputOptions.h +++ b/Sources/OpenGraphCxx/include/OGInputOptions.h @@ -1,6 +1,6 @@ // // OGInputOptions.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGInputOptions_h #define OGInputOptions_h diff --git a/Sources/OpenGraph_SPI/include/OGSearchOptions.h b/Sources/OpenGraphCxx/include/OGSearchOptions.h similarity index 92% rename from Sources/OpenGraph_SPI/include/OGSearchOptions.h rename to Sources/OpenGraphCxx/include/OGSearchOptions.h index 4e9c2f03..99c601ee 100644 --- a/Sources/OpenGraph_SPI/include/OGSearchOptions.h +++ b/Sources/OpenGraphCxx/include/OGSearchOptions.h @@ -1,6 +1,6 @@ // // OGSearchOptions.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGSearchOptions_h #define OGSearchOptions_h diff --git a/Sources/OpenGraph_SPI/include/OGSubgraph.h b/Sources/OpenGraphCxx/include/OGSubgraph.h similarity index 99% rename from Sources/OpenGraph_SPI/include/OGSubgraph.h rename to Sources/OpenGraphCxx/include/OGSubgraph.h index 598c9915..417f0b3d 100644 --- a/Sources/OpenGraph_SPI/include/OGSubgraph.h +++ b/Sources/OpenGraphCxx/include/OGSubgraph.h @@ -1,6 +1,6 @@ // // OGSubgraph.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGSubgraph_h #define OGSubgraph_h diff --git a/Sources/OpenGraph_SPI/include/OGSwiftSupport.h b/Sources/OpenGraphCxx/include/OGSwiftSupport.h similarity index 98% rename from Sources/OpenGraph_SPI/include/OGSwiftSupport.h rename to Sources/OpenGraphCxx/include/OGSwiftSupport.h index 46efbb26..82c52787 100644 --- a/Sources/OpenGraph_SPI/include/OGSwiftSupport.h +++ b/Sources/OpenGraphCxx/include/OGSwiftSupport.h @@ -1,6 +1,6 @@ // // OGSwiftSupport.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGSwiftSupport_h #define OGSwiftSupport_h diff --git a/Sources/OpenGraph_SPI/include/OGTargetConditionals.h b/Sources/OpenGraphCxx/include/OGTargetConditionals.h similarity index 100% rename from Sources/OpenGraph_SPI/include/OGTargetConditionals.h rename to Sources/OpenGraphCxx/include/OGTargetConditionals.h diff --git a/Sources/OpenGraph_SPI/include/OGTupleType.h b/Sources/OpenGraphCxx/include/OGTupleType.h similarity index 99% rename from Sources/OpenGraph_SPI/include/OGTupleType.h rename to Sources/OpenGraphCxx/include/OGTupleType.h index f62eba74..0ce2c3ba 100644 --- a/Sources/OpenGraph_SPI/include/OGTupleType.h +++ b/Sources/OpenGraphCxx/include/OGTupleType.h @@ -1,6 +1,6 @@ // // OGTupleType.h -// OpenGraph_SPI +// OpenGraphCxx // // Audited for iOS 18.0 // Status: Complete diff --git a/Sources/OpenGraph_SPI/include/OGTypeID.h b/Sources/OpenGraphCxx/include/OGTypeID.h similarity index 99% rename from Sources/OpenGraph_SPI/include/OGTypeID.h rename to Sources/OpenGraphCxx/include/OGTypeID.h index 2d718c6d..23b2fa58 100644 --- a/Sources/OpenGraph_SPI/include/OGTypeID.h +++ b/Sources/OpenGraphCxx/include/OGTypeID.h @@ -1,6 +1,6 @@ // // OGTypeID.h -// OpenGraph_SPI +// OpenGraphCxx // // Audited for iOS 18.0 // Status: Complete diff --git a/Sources/OpenGraph_SPI/include/OGUniqueID.h b/Sources/OpenGraphCxx/include/OGUniqueID.h similarity index 94% rename from Sources/OpenGraph_SPI/include/OGUniqueID.h rename to Sources/OpenGraphCxx/include/OGUniqueID.h index f0348c92..745c4d12 100644 --- a/Sources/OpenGraph_SPI/include/OGUniqueID.h +++ b/Sources/OpenGraphCxx/include/OGUniqueID.h @@ -1,6 +1,6 @@ // // OGMakeUniqueID.h -// OpenGraph_SPI +// OpenGraphCxx // // Audited for iOS 18.0 // Status: Complete diff --git a/Sources/OpenGraph_SPI/include/OGValue.h b/Sources/OpenGraphCxx/include/OGValue.h similarity index 92% rename from Sources/OpenGraph_SPI/include/OGValue.h rename to Sources/OpenGraphCxx/include/OGValue.h index cea55304..af0f1835 100644 --- a/Sources/OpenGraph_SPI/include/OGValue.h +++ b/Sources/OpenGraphCxx/include/OGValue.h @@ -1,6 +1,6 @@ // // OGValue.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGValue_h #define OGValue_h diff --git a/Sources/OpenGraph_SPI/include/OGValueOptions.h b/Sources/OpenGraphCxx/include/OGValueOptions.h similarity index 93% rename from Sources/OpenGraph_SPI/include/OGValueOptions.h rename to Sources/OpenGraphCxx/include/OGValueOptions.h index 652dd407..1dc57fcc 100644 --- a/Sources/OpenGraph_SPI/include/OGValueOptions.h +++ b/Sources/OpenGraphCxx/include/OGValueOptions.h @@ -1,6 +1,6 @@ // // OGValueOptions.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGValueOptions_h #define OGValueOptions_h diff --git a/Sources/OpenGraph_SPI/include/OGValueState.h b/Sources/OpenGraphCxx/include/OGValueState.h similarity index 92% rename from Sources/OpenGraph_SPI/include/OGValueState.h rename to Sources/OpenGraphCxx/include/OGValueState.h index aa4b81ad..21f33f9e 100644 --- a/Sources/OpenGraph_SPI/include/OGValueState.h +++ b/Sources/OpenGraphCxx/include/OGValueState.h @@ -1,6 +1,6 @@ // // OGValueState.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGValueState_h #define OGValueState_h diff --git a/Sources/OpenGraph_SPI/include/OGVersion.h b/Sources/OpenGraphCxx/include/OGVersion.h similarity index 94% rename from Sources/OpenGraph_SPI/include/OGVersion.h rename to Sources/OpenGraphCxx/include/OGVersion.h index 13f094db..725a4fd5 100644 --- a/Sources/OpenGraph_SPI/include/OGVersion.h +++ b/Sources/OpenGraphCxx/include/OGVersion.h @@ -1,6 +1,6 @@ // // OGVersion.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGVersion_h #define OGVersion_h diff --git a/Sources/OpenGraph_SPI/include/OGWeakAttribute.h b/Sources/OpenGraphCxx/include/OGWeakAttribute.h similarity index 97% rename from Sources/OpenGraph_SPI/include/OGWeakAttribute.h rename to Sources/OpenGraphCxx/include/OGWeakAttribute.h index 7b2472e6..385c5c26 100644 --- a/Sources/OpenGraph_SPI/include/OGWeakAttribute.h +++ b/Sources/OpenGraphCxx/include/OGWeakAttribute.h @@ -1,6 +1,6 @@ // // OGWeakAttribute.h -// OpenGraph_SPI +// OpenGraphCxx #ifndef OGWeakAttribute_hpp #define OGWeakAttribute_hpp diff --git a/Sources/OpenGraph_SPI/include/OpenGraph-umbrella.h b/Sources/OpenGraphCxx/include/OpenGraph-umbrella.h similarity index 100% rename from Sources/OpenGraph_SPI/include/OpenGraph-umbrella.h rename to Sources/OpenGraphCxx/include/OpenGraph-umbrella.h diff --git a/Sources/OpenGraph_SPI/include/OpenGraphCxx/table.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/table.hpp similarity index 99% rename from Sources/OpenGraph_SPI/include/OpenGraphCxx/table.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/table.hpp index de51d153..f43a40ab 100644 --- a/Sources/OpenGraph_SPI/include/OpenGraphCxx/table.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/table.hpp @@ -1,6 +1,6 @@ // // table.hpp -// OpenGraph_SPI +// OpenGraphCxx #ifndef table_hpp #define table_hpp diff --git a/Sources/OpenGraph_SPI/include/module.modulemap b/Sources/OpenGraphCxx/include/module.modulemap similarity index 78% rename from Sources/OpenGraph_SPI/include/module.modulemap rename to Sources/OpenGraphCxx/include/module.modulemap index c97b982d..9c02b4f1 100644 --- a/Sources/OpenGraph_SPI/include/module.modulemap +++ b/Sources/OpenGraphCxx/include/module.modulemap @@ -1,10 +1,10 @@ -module OpenGraph_SPI { +module OpenGraphCxx { header "OpenGraph-umbrella.h" export * } // TODO: Change to module OpenGraphCxx and OpenGraphCxx.Internal -module OpenGraph_SPI.Cxx { +module OpenGraphCxx.Cxx { requires cplusplus umbrella "OpenGraphCxx" export * diff --git a/Tests/OpenGraph_SPITests/OpenGraph_SPITests.swift b/Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift similarity index 63% rename from Tests/OpenGraph_SPITests/OpenGraph_SPITests.swift rename to Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift index 218cc8f3..6f5e06bb 100644 --- a/Tests/OpenGraph_SPITests/OpenGraph_SPITests.swift +++ b/Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift @@ -1,11 +1,11 @@ // -// OpenGraph_SPITests.swift -// OpenGraph +// OpenGraphCxxTests.swift +// OpenGraphCxxTests -import OpenGraph_SPI.Cxx +import OpenGraphCxx.Cxx import Testing -struct OpenGraph_SPITests { +struct OpenGraphCxxTests { #if canImport(Darwin) // table() is not implemented on Linux yet. @Test func table() { diff --git a/Tests/OpenGraphCxxTests/README.md b/Tests/OpenGraphCxxTests/README.md new file mode 100644 index 00000000..ca665656 --- /dev/null +++ b/Tests/OpenGraphCxxTests/README.md @@ -0,0 +1,3 @@ +## OpenGraphCxxTests + +Test internal C++ API of OpenGraphCxx diff --git a/Tests/OpenGraph_SPITests/README.md b/Tests/OpenGraph_SPITests/README.md deleted file mode 100644 index 4230328b..00000000 --- a/Tests/OpenGraph_SPITests/README.md +++ /dev/null @@ -1,3 +0,0 @@ -## OpenGraph_SPITests - -Test C++ API of OpenGraph_SPI From 1b1b90a895c209db00ebbe02786580a7e63063d8 Mon Sep 17 00:00:00 2001 From: Kyle Date: Sat, 2 Aug 2025 18:00:24 +0800 Subject: [PATCH 2/6] Change to OpenGraphCxx.Internal --- Sources/OpenGraphCxx/Data/ptr.hpp | 2 +- Sources/OpenGraphCxx/Data/table.cpp | 2 +- Sources/OpenGraphCxx/Data/zone.cpp | 2 +- .../include/OpenGraphCxx/{ => Internal}/table.hpp | 0 Sources/OpenGraphCxx/include/module.modulemap | 4 ++-- Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) rename Sources/OpenGraphCxx/include/OpenGraphCxx/{ => Internal}/table.hpp (100%) diff --git a/Sources/OpenGraphCxx/Data/ptr.hpp b/Sources/OpenGraphCxx/Data/ptr.hpp index 3feb216a..6de1814b 100644 --- a/Sources/OpenGraphCxx/Data/ptr.hpp +++ b/Sources/OpenGraphCxx/Data/ptr.hpp @@ -9,7 +9,7 @@ #define ptr_hpp #include "OGBase.h" -#include "OpenGraphCxx/table.hpp" +#include #include #include "page_const.hpp" diff --git a/Sources/OpenGraphCxx/Data/table.cpp b/Sources/OpenGraphCxx/Data/table.cpp index 11793fe5..5bd8c205 100644 --- a/Sources/OpenGraphCxx/Data/table.cpp +++ b/Sources/OpenGraphCxx/Data/table.cpp @@ -6,7 +6,7 @@ // Status: WIP // Modified from https://github.com/jcmosc/Compute/blob/0a6b21a4cdeb9bbdd95e7e914c4e18bed37a2456/Sources/ComputeCxx/Data/Table.cpp [MIT License] -#include +#include #include "page.hpp" #include "page_const.hpp" #include "zone.hpp" diff --git a/Sources/OpenGraphCxx/Data/zone.cpp b/Sources/OpenGraphCxx/Data/zone.cpp index b4c89dcb..7a224815 100644 --- a/Sources/OpenGraphCxx/Data/zone.cpp +++ b/Sources/OpenGraphCxx/Data/zone.cpp @@ -3,7 +3,7 @@ // OpenGraphCxx #include "zone.hpp" -#include +#include #include "page.hpp" #include "../Util/assert.hpp" #if OG_TARGET_OS_DARWIN diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/table.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/table.hpp similarity index 100% rename from Sources/OpenGraphCxx/include/OpenGraphCxx/table.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/table.hpp diff --git a/Sources/OpenGraphCxx/include/module.modulemap b/Sources/OpenGraphCxx/include/module.modulemap index 9c02b4f1..ba27dfc2 100644 --- a/Sources/OpenGraphCxx/include/module.modulemap +++ b/Sources/OpenGraphCxx/include/module.modulemap @@ -4,8 +4,8 @@ module OpenGraphCxx { } // TODO: Change to module OpenGraphCxx and OpenGraphCxx.Internal -module OpenGraphCxx.Cxx { +module OpenGraphCxx.Internal { requires cplusplus - umbrella "OpenGraphCxx" + umbrella "OpenGraphCxx/Internal" export * } diff --git a/Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift b/Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift index 6f5e06bb..f34e1c4f 100644 --- a/Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift +++ b/Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift @@ -2,7 +2,7 @@ // OpenGraphCxxTests.swift // OpenGraphCxxTests -import OpenGraphCxx.Cxx +import OpenGraphCxx.Internal import Testing struct OpenGraphCxxTests { From 70e18947463d54eac73c275c4d381c6e6c876241 Mon Sep 17 00:00:00 2001 From: Kyle Date: Sat, 2 Aug 2025 18:09:47 +0800 Subject: [PATCH 3/6] Add OpenGraphCxx Private submodule --- Sources/OpenGraphCxx/Attribute/AttributeID.cpp | 7 ++----- Sources/OpenGraphCxx/Attribute/OGAttribute.cpp | 3 +-- Sources/OpenGraphCxx/Comparison/OGComparison.cpp | 2 +- Sources/OpenGraphCxx/Graph/Graph.hpp | 2 +- Sources/OpenGraphCxx/Graph/OGGraphContext.cpp | 2 +- Sources/OpenGraphCxx/Graph/Subgraph.hpp | 2 +- Sources/OpenGraphCxx/include/OGGraph.h | 2 +- Sources/OpenGraphCxx/include/OGSubgraph.h | 2 +- .../OpenGraphCxx/Internal}/AttributeID.hpp | 0 .../OpenGraphCxx/Internal}/AttributeType.hpp | 7 ++----- .../{ => include/OpenGraphCxx}/Private/CFRuntime.h | 0 .../OpenGraphCxx/Private}/OGComparisonPrivate.h | 0 Sources/OpenGraphCxx/include/module.modulemap | 7 ++++++- 13 files changed, 17 insertions(+), 19 deletions(-) rename Sources/OpenGraphCxx/{Attribute => include/OpenGraphCxx/Internal}/AttributeID.hpp (100%) rename Sources/OpenGraphCxx/{Attribute => include/OpenGraphCxx/Internal}/AttributeType.hpp (72%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Private/CFRuntime.h (100%) rename Sources/OpenGraphCxx/{Comparison => include/OpenGraphCxx/Private}/OGComparisonPrivate.h (100%) diff --git a/Sources/OpenGraphCxx/Attribute/AttributeID.cpp b/Sources/OpenGraphCxx/Attribute/AttributeID.cpp index 10f09a85..1cc43c42 100644 --- a/Sources/OpenGraphCxx/Attribute/AttributeID.cpp +++ b/Sources/OpenGraphCxx/Attribute/AttributeID.cpp @@ -1,8 +1,5 @@ // // AttributeID.cpp -// -// -// Created by Kyle on 2024/2/16. -// +// OpenGraphCxx -#include "AttributeID.hpp" +#include \ No newline at end of file diff --git a/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp b/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp index 2008742d..e02d1605 100644 --- a/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp +++ b/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp @@ -6,8 +6,7 @@ // #include "OGAttribute.h" -#include "AttributeID.hpp" -#include "../Attribute/AttributeID.hpp" +#include #include "../Util/assert.hpp" #include diff --git a/Sources/OpenGraphCxx/Comparison/OGComparison.cpp b/Sources/OpenGraphCxx/Comparison/OGComparison.cpp index 57d2fff4..73601545 100644 --- a/Sources/OpenGraphCxx/Comparison/OGComparison.cpp +++ b/Sources/OpenGraphCxx/Comparison/OGComparison.cpp @@ -3,7 +3,7 @@ // OpenGraphCxx #include "OGComparison.h" -#include "OGComparisonPrivate.h" +#include const void *OGComparisonStateGetDestination(OGComparisonState state) { return ((const OGComparisonStateStorage *)state)->destination; diff --git a/Sources/OpenGraphCxx/Graph/Graph.hpp b/Sources/OpenGraphCxx/Graph/Graph.hpp index c6511a37..90a0ae6a 100644 --- a/Sources/OpenGraphCxx/Graph/Graph.hpp +++ b/Sources/OpenGraphCxx/Graph/Graph.hpp @@ -9,7 +9,7 @@ #include "OGBase.h" #include "OGGraph.h" #include "OGUniqueID.h" -#include "../Private/CFRuntime.h" +#include #include "../Data/ClosureFunction.hpp" OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp b/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp index af442f95..ec1ea2a7 100644 --- a/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp +++ b/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp @@ -6,7 +6,7 @@ // #include "OGGraphContext.h" -#include "../Private/CFRuntime.h" +#include OGGraphRef OGGraphContextGetGraph(OGGraphContextRef context) { return reinterpret_cast(reinterpret_cast(context) - sizeof(CFRuntimeBase)); diff --git a/Sources/OpenGraphCxx/Graph/Subgraph.hpp b/Sources/OpenGraphCxx/Graph/Subgraph.hpp index 9fa62e5e..03a7b605 100644 --- a/Sources/OpenGraphCxx/Graph/Subgraph.hpp +++ b/Sources/OpenGraphCxx/Graph/Subgraph.hpp @@ -10,7 +10,7 @@ #include "OGBase.h" #include "Graph.hpp" -#include "../Attribute/AttributeID.hpp" +#include #include "../Data/ClosureFunction.hpp" #include "../Runtime/metadata.hpp" #include diff --git a/Sources/OpenGraphCxx/include/OGGraph.h b/Sources/OpenGraphCxx/include/OGGraph.h index 9cd6831e..beecbf96 100644 --- a/Sources/OpenGraphCxx/include/OGGraph.h +++ b/Sources/OpenGraphCxx/include/OGGraph.h @@ -6,7 +6,7 @@ #define OGGraph_h #include "OGBase.h" -#include "../Private/CFRuntime.h" +#include #include "OGCounterQueryType.h" // Note: Place all structure declaration in a single place to avoid header cycle dependency diff --git a/Sources/OpenGraphCxx/include/OGSubgraph.h b/Sources/OpenGraphCxx/include/OGSubgraph.h index 417f0b3d..814bb46b 100644 --- a/Sources/OpenGraphCxx/include/OGSubgraph.h +++ b/Sources/OpenGraphCxx/include/OGSubgraph.h @@ -10,7 +10,7 @@ #include "OGBase.h" #include "OGGraph.h" #include "OGUniqueID.h" -#include "../Private/CFRuntime.h" +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/Attribute/AttributeID.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/AttributeID.hpp similarity index 100% rename from Sources/OpenGraphCxx/Attribute/AttributeID.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/AttributeID.hpp diff --git a/Sources/OpenGraphCxx/Attribute/AttributeType.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/AttributeType.hpp similarity index 72% rename from Sources/OpenGraphCxx/Attribute/AttributeType.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/AttributeType.hpp index 8deffb3b..a9fd2421 100644 --- a/Sources/OpenGraphCxx/Attribute/AttributeType.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/AttributeType.hpp @@ -1,9 +1,6 @@ // // AttributeType.hpp -// -// -// Created by Kyle on 2024/2/17. -// +// OpenGraphCxx #ifndef AttributeType_hpp #define AttributeType_hpp @@ -16,4 +13,4 @@ struct AttributeType { OGAttributeType storage; }; } -#endif /* AttributeType_2_hpp */ +#endif /* AttributeType_hpp */ diff --git a/Sources/OpenGraphCxx/Private/CFRuntime.h b/Sources/OpenGraphCxx/include/OpenGraphCxx/Private/CFRuntime.h similarity index 100% rename from Sources/OpenGraphCxx/Private/CFRuntime.h rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Private/CFRuntime.h diff --git a/Sources/OpenGraphCxx/Comparison/OGComparisonPrivate.h b/Sources/OpenGraphCxx/include/OpenGraphCxx/Private/OGComparisonPrivate.h similarity index 100% rename from Sources/OpenGraphCxx/Comparison/OGComparisonPrivate.h rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Private/OGComparisonPrivate.h diff --git a/Sources/OpenGraphCxx/include/module.modulemap b/Sources/OpenGraphCxx/include/module.modulemap index ba27dfc2..8871033b 100644 --- a/Sources/OpenGraphCxx/include/module.modulemap +++ b/Sources/OpenGraphCxx/include/module.modulemap @@ -3,9 +3,14 @@ module OpenGraphCxx { export * } -// TODO: Change to module OpenGraphCxx and OpenGraphCxx.Internal module OpenGraphCxx.Internal { requires cplusplus umbrella "OpenGraphCxx/Internal" export * } + +module OpenGraphCxx.Private { + requires cplusplus + umbrella "OpenGraphCxx/Private" + export * +} From ccaed2a7928733b05621bb64bcea3ddde25466f8 Mon Sep 17 00:00:00 2001 From: Kyle Date: Sat, 2 Aug 2025 18:22:02 +0800 Subject: [PATCH 4/6] Add module.private.modulemap --- .../OpenGraphCxx/Attribute/AttributeID.cpp | 2 +- .../OpenGraphCxx/Attribute/OGAttribute.cpp | 2 +- .../OpenGraphCxx/Comparison/OGComparison.cpp | 2 +- Sources/OpenGraphCxx/Data/ptr.hpp | 2 +- Sources/OpenGraphCxx/Data/table.cpp | 2 +- Sources/OpenGraphCxx/Data/zone.cpp | 2 +- Sources/OpenGraphCxx/Graph/Graph.hpp | 2 +- Sources/OpenGraphCxx/Graph/OGGraphContext.cpp | 2 +- Sources/OpenGraphCxx/Graph/Subgraph.hpp | 2 +- .../OpenGraphCxx => }/Private/CFRuntime.h | 0 Sources/OpenGraphCxx/include/OGGraph.h | 2 +- Sources/OpenGraphCxx/include/OGSubgraph.h | 2 +- .../{Internal => Attribute}/AttributeID.hpp | 0 .../{Internal => Attribute}/AttributeType.hpp | 0 .../OGComparisonPrivate.h | 0 .../OpenGraphCxx/{Internal => Data}/table.hpp | 0 Sources/OpenGraphCxx/include/module.modulemap | 12 ----------- .../include/module.private.modulemap | 21 +++++++++++++++++++ .../OpenGraphCxxTests/OpenGraphCxxTests.swift | 2 +- 19 files changed, 33 insertions(+), 24 deletions(-) rename Sources/OpenGraphCxx/{include/OpenGraphCxx => }/Private/CFRuntime.h (100%) rename Sources/OpenGraphCxx/include/OpenGraphCxx/{Internal => Attribute}/AttributeID.hpp (100%) rename Sources/OpenGraphCxx/include/OpenGraphCxx/{Internal => Attribute}/AttributeType.hpp (100%) rename Sources/OpenGraphCxx/include/OpenGraphCxx/{Private => Comparison}/OGComparisonPrivate.h (100%) rename Sources/OpenGraphCxx/include/OpenGraphCxx/{Internal => Data}/table.hpp (100%) create mode 100644 Sources/OpenGraphCxx/include/module.private.modulemap diff --git a/Sources/OpenGraphCxx/Attribute/AttributeID.cpp b/Sources/OpenGraphCxx/Attribute/AttributeID.cpp index 1cc43c42..261db98b 100644 --- a/Sources/OpenGraphCxx/Attribute/AttributeID.cpp +++ b/Sources/OpenGraphCxx/Attribute/AttributeID.cpp @@ -2,4 +2,4 @@ // AttributeID.cpp // OpenGraphCxx -#include \ No newline at end of file +#include diff --git a/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp b/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp index e02d1605..6e9708a4 100644 --- a/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp +++ b/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp @@ -6,7 +6,7 @@ // #include "OGAttribute.h" -#include +#include #include "../Util/assert.hpp" #include diff --git a/Sources/OpenGraphCxx/Comparison/OGComparison.cpp b/Sources/OpenGraphCxx/Comparison/OGComparison.cpp index 73601545..892a356a 100644 --- a/Sources/OpenGraphCxx/Comparison/OGComparison.cpp +++ b/Sources/OpenGraphCxx/Comparison/OGComparison.cpp @@ -3,7 +3,7 @@ // OpenGraphCxx #include "OGComparison.h" -#include +#include const void *OGComparisonStateGetDestination(OGComparisonState state) { return ((const OGComparisonStateStorage *)state)->destination; diff --git a/Sources/OpenGraphCxx/Data/ptr.hpp b/Sources/OpenGraphCxx/Data/ptr.hpp index 6de1814b..ab0a04a2 100644 --- a/Sources/OpenGraphCxx/Data/ptr.hpp +++ b/Sources/OpenGraphCxx/Data/ptr.hpp @@ -9,7 +9,7 @@ #define ptr_hpp #include "OGBase.h" -#include +#include #include #include "page_const.hpp" diff --git a/Sources/OpenGraphCxx/Data/table.cpp b/Sources/OpenGraphCxx/Data/table.cpp index 5bd8c205..c7b141b7 100644 --- a/Sources/OpenGraphCxx/Data/table.cpp +++ b/Sources/OpenGraphCxx/Data/table.cpp @@ -6,7 +6,7 @@ // Status: WIP // Modified from https://github.com/jcmosc/Compute/blob/0a6b21a4cdeb9bbdd95e7e914c4e18bed37a2456/Sources/ComputeCxx/Data/Table.cpp [MIT License] -#include +#include #include "page.hpp" #include "page_const.hpp" #include "zone.hpp" diff --git a/Sources/OpenGraphCxx/Data/zone.cpp b/Sources/OpenGraphCxx/Data/zone.cpp index 7a224815..01c9226e 100644 --- a/Sources/OpenGraphCxx/Data/zone.cpp +++ b/Sources/OpenGraphCxx/Data/zone.cpp @@ -3,7 +3,7 @@ // OpenGraphCxx #include "zone.hpp" -#include +#include #include "page.hpp" #include "../Util/assert.hpp" #if OG_TARGET_OS_DARWIN diff --git a/Sources/OpenGraphCxx/Graph/Graph.hpp b/Sources/OpenGraphCxx/Graph/Graph.hpp index 90a0ae6a..c6511a37 100644 --- a/Sources/OpenGraphCxx/Graph/Graph.hpp +++ b/Sources/OpenGraphCxx/Graph/Graph.hpp @@ -9,7 +9,7 @@ #include "OGBase.h" #include "OGGraph.h" #include "OGUniqueID.h" -#include +#include "../Private/CFRuntime.h" #include "../Data/ClosureFunction.hpp" OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp b/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp index ec1ea2a7..af442f95 100644 --- a/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp +++ b/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp @@ -6,7 +6,7 @@ // #include "OGGraphContext.h" -#include +#include "../Private/CFRuntime.h" OGGraphRef OGGraphContextGetGraph(OGGraphContextRef context) { return reinterpret_cast(reinterpret_cast(context) - sizeof(CFRuntimeBase)); diff --git a/Sources/OpenGraphCxx/Graph/Subgraph.hpp b/Sources/OpenGraphCxx/Graph/Subgraph.hpp index 03a7b605..6d358d17 100644 --- a/Sources/OpenGraphCxx/Graph/Subgraph.hpp +++ b/Sources/OpenGraphCxx/Graph/Subgraph.hpp @@ -10,7 +10,7 @@ #include "OGBase.h" #include "Graph.hpp" -#include +#include #include "../Data/ClosureFunction.hpp" #include "../Runtime/metadata.hpp" #include diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Private/CFRuntime.h b/Sources/OpenGraphCxx/Private/CFRuntime.h similarity index 100% rename from Sources/OpenGraphCxx/include/OpenGraphCxx/Private/CFRuntime.h rename to Sources/OpenGraphCxx/Private/CFRuntime.h diff --git a/Sources/OpenGraphCxx/include/OGGraph.h b/Sources/OpenGraphCxx/include/OGGraph.h index beecbf96..9cd6831e 100644 --- a/Sources/OpenGraphCxx/include/OGGraph.h +++ b/Sources/OpenGraphCxx/include/OGGraph.h @@ -6,7 +6,7 @@ #define OGGraph_h #include "OGBase.h" -#include +#include "../Private/CFRuntime.h" #include "OGCounterQueryType.h" // Note: Place all structure declaration in a single place to avoid header cycle dependency diff --git a/Sources/OpenGraphCxx/include/OGSubgraph.h b/Sources/OpenGraphCxx/include/OGSubgraph.h index 814bb46b..417f0b3d 100644 --- a/Sources/OpenGraphCxx/include/OGSubgraph.h +++ b/Sources/OpenGraphCxx/include/OGSubgraph.h @@ -10,7 +10,7 @@ #include "OGBase.h" #include "OGGraph.h" #include "OGUniqueID.h" -#include +#include "../Private/CFRuntime.h" OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/AttributeID.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeID.hpp similarity index 100% rename from Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/AttributeID.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeID.hpp diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/AttributeType.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeType.hpp similarity index 100% rename from Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/AttributeType.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeType.hpp diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Private/OGComparisonPrivate.h b/Sources/OpenGraphCxx/include/OpenGraphCxx/Comparison/OGComparisonPrivate.h similarity index 100% rename from Sources/OpenGraphCxx/include/OpenGraphCxx/Private/OGComparisonPrivate.h rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Comparison/OGComparisonPrivate.h diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/table.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/table.hpp similarity index 100% rename from Sources/OpenGraphCxx/include/OpenGraphCxx/Internal/table.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Data/table.hpp diff --git a/Sources/OpenGraphCxx/include/module.modulemap b/Sources/OpenGraphCxx/include/module.modulemap index 8871033b..308f9ee9 100644 --- a/Sources/OpenGraphCxx/include/module.modulemap +++ b/Sources/OpenGraphCxx/include/module.modulemap @@ -2,15 +2,3 @@ module OpenGraphCxx { header "OpenGraph-umbrella.h" export * } - -module OpenGraphCxx.Internal { - requires cplusplus - umbrella "OpenGraphCxx/Internal" - export * -} - -module OpenGraphCxx.Private { - requires cplusplus - umbrella "OpenGraphCxx/Private" - export * -} diff --git a/Sources/OpenGraphCxx/include/module.private.modulemap b/Sources/OpenGraphCxx/include/module.private.modulemap new file mode 100644 index 00000000..006b447a --- /dev/null +++ b/Sources/OpenGraphCxx/include/module.private.modulemap @@ -0,0 +1,21 @@ +module OpenGraphCxx_Private { + export * +} + +module OpenGraphCxx_Private.Attribute { + requires cplusplus + umbrella "OpenGraphCxx/Attribute" + export * +} + +module OpenGraphCxx_Private.Data { + requires cplusplus + umbrella "OpenGraphCxx/Data" + export * +} + +module OpenGraphCxx_Private.Comparison { + requires cplusplus + umbrella "OpenGraphCxx/Comparison" + export * +} diff --git a/Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift b/Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift index f34e1c4f..91837d7f 100644 --- a/Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift +++ b/Tests/OpenGraphCxxTests/OpenGraphCxxTests.swift @@ -2,7 +2,7 @@ // OpenGraphCxxTests.swift // OpenGraphCxxTests -import OpenGraphCxx.Internal +import OpenGraphCxx_Private import Testing struct OpenGraphCxxTests { From 553c93e80e94abec51a42b7d95ceeef0696f3d9c Mon Sep 17 00:00:00 2001 From: Kyle Date: Sat, 2 Aug 2025 18:36:18 +0800 Subject: [PATCH 5/6] Refactor all hpp headers --- .../OpenGraphCxx/Attribute/OGAttribute.cpp | 2 +- Sources/OpenGraphCxx/Data/ClosureFunction.cpp | 2 +- Sources/OpenGraphCxx/Data/table.cpp | 8 +- Sources/OpenGraphCxx/Data/zone.cpp | 6 +- .../{Debug => DebugServer}/OGDebugServer.cpp | 2 +- .../{Debug => DebugServer}/og-debug-server.mm | 8 +- Sources/OpenGraphCxx/Graph/Graph.cpp | 4 +- Sources/OpenGraphCxx/Graph/Graph.mm | 2 +- Sources/OpenGraphCxx/Graph/GraphContext.cpp | 4 +- .../OpenGraphCxx/Graph/GraphDescription.cpp | 4 +- .../OpenGraphCxx/Graph/GraphDescription.mm | 4 +- Sources/OpenGraphCxx/Graph/OGGraph.cpp | 6 +- Sources/OpenGraphCxx/Graph/OGSubgraph.cpp | 6 +- Sources/OpenGraphCxx/Graph/Subgraph.cpp | 2 +- Sources/OpenGraphCxx/Graph/Subgraph.hpp | 6 +- Sources/OpenGraphCxx/Runtime/OGTupleType.cpp | 4 +- Sources/OpenGraphCxx/Runtime/OGTypeID.cpp | 4 +- Sources/OpenGraphCxx/Runtime/metadata.cpp | 2 +- Sources/OpenGraphCxx/Util/assert.cpp | 4 +- Sources/OpenGraphCxx/Util/log.cpp | 2 +- Sources/OpenGraphCxx/Util/realloc_vector.cpp | 4 +- .../OpenGraphCxx/Attribute/AttributeID.hpp | 2 +- .../OpenGraphCxx}/Data/ClosureFunction.hpp | 0 .../{ => include/OpenGraphCxx}/Data/page.hpp | 2 +- .../OpenGraphCxx}/Data/page_const.hpp | 0 .../{ => include/OpenGraphCxx}/Data/ptr.hpp | 2 +- .../include/OpenGraphCxx/Data/table.hpp | 2 +- .../{ => include/OpenGraphCxx}/Data/zone.hpp | 2 +- .../DebugServer}/og-debug-server.hpp | 2 +- .../OpenGraphCxx}/Graph/Graph.hpp | 2 +- .../include/OpenGraphCxx/Graph/Subgraph.hpp | 112 ++++++++++++++++++ .../OpenGraphCxx}/Runtime/metadata.hpp | 0 .../OpenGraphCxx}/Util/assert.hpp | 0 .../{ => include/OpenGraphCxx}/Util/env.hpp | 0 .../{ => include/OpenGraphCxx}/Util/log.hpp | 0 .../OpenGraphCxx}/Util/realloc_vector.hpp | 0 .../OpenGraphCxx}/Vector/vector.hpp | 0 .../OpenGraphCxx}/Vector/vector.tpp | 4 +- 38 files changed, 164 insertions(+), 52 deletions(-) rename Sources/OpenGraphCxx/{Debug => DebugServer}/OGDebugServer.cpp (92%) rename Sources/OpenGraphCxx/{Debug => DebugServer}/og-debug-server.mm (98%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Data/ClosureFunction.hpp (100%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Data/page.hpp (89%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Data/page_const.hpp (100%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Data/ptr.hpp (98%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Data/zone.hpp (97%) rename Sources/OpenGraphCxx/{Debug => include/OpenGraphCxx/DebugServer}/og-debug-server.hpp (97%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Graph/Graph.hpp (98%) create mode 100644 Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Subgraph.hpp rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Runtime/metadata.hpp (100%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Util/assert.hpp (100%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Util/env.hpp (100%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Util/log.hpp (100%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Util/realloc_vector.hpp (100%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Vector/vector.hpp (100%) rename Sources/OpenGraphCxx/{ => include/OpenGraphCxx}/Vector/vector.tpp (99%) diff --git a/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp b/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp index 6e9708a4..70b9b96f 100644 --- a/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp +++ b/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp @@ -7,7 +7,7 @@ #include "OGAttribute.h" #include -#include "../Util/assert.hpp" +#include #include const OGAttribute OGAttributeNil = OGAttribute(OG::AttributeID::Kind::Null); diff --git a/Sources/OpenGraphCxx/Data/ClosureFunction.cpp b/Sources/OpenGraphCxx/Data/ClosureFunction.cpp index 10284101..7c4a02e0 100644 --- a/Sources/OpenGraphCxx/Data/ClosureFunction.cpp +++ b/Sources/OpenGraphCxx/Data/ClosureFunction.cpp @@ -5,4 +5,4 @@ // Created by Kyle on 2024/3/6. // -#include "ClosureFunction.hpp" +#include diff --git a/Sources/OpenGraphCxx/Data/table.cpp b/Sources/OpenGraphCxx/Data/table.cpp index c7b141b7..e916fa25 100644 --- a/Sources/OpenGraphCxx/Data/table.cpp +++ b/Sources/OpenGraphCxx/Data/table.cpp @@ -7,10 +7,10 @@ // Modified from https://github.com/jcmosc/Compute/blob/0a6b21a4cdeb9bbdd95e7e914c4e18bed37a2456/Sources/ComputeCxx/Data/Table.cpp [MIT License] #include -#include "page.hpp" -#include "page_const.hpp" -#include "zone.hpp" -#include "../Util/assert.hpp" +#include +#include +#include +#include #include #include #if OG_TARGET_OS_DARWIN diff --git a/Sources/OpenGraphCxx/Data/zone.cpp b/Sources/OpenGraphCxx/Data/zone.cpp index 01c9226e..eb072c3f 100644 --- a/Sources/OpenGraphCxx/Data/zone.cpp +++ b/Sources/OpenGraphCxx/Data/zone.cpp @@ -2,10 +2,10 @@ // zone.cpp // OpenGraphCxx -#include "zone.hpp" +#include #include -#include "page.hpp" -#include "../Util/assert.hpp" +#include +#include #if OG_TARGET_OS_DARWIN #include #else diff --git a/Sources/OpenGraphCxx/Debug/OGDebugServer.cpp b/Sources/OpenGraphCxx/DebugServer/OGDebugServer.cpp similarity index 92% rename from Sources/OpenGraphCxx/Debug/OGDebugServer.cpp rename to Sources/OpenGraphCxx/DebugServer/OGDebugServer.cpp index 3bd3cff9..b516880b 100644 --- a/Sources/OpenGraphCxx/Debug/OGDebugServer.cpp +++ b/Sources/OpenGraphCxx/DebugServer/OGDebugServer.cpp @@ -6,7 +6,7 @@ // #include "OGDebugServer.h" -#include "og-debug-server.hpp" +#include #if OG_TARGET_OS_DARWIN diff --git a/Sources/OpenGraphCxx/Debug/og-debug-server.mm b/Sources/OpenGraphCxx/DebugServer/og-debug-server.mm similarity index 98% rename from Sources/OpenGraphCxx/Debug/og-debug-server.mm rename to Sources/OpenGraphCxx/DebugServer/og-debug-server.mm index 1b5e6a56..e4d64957 100644 --- a/Sources/OpenGraphCxx/Debug/og-debug-server.mm +++ b/Sources/OpenGraphCxx/DebugServer/og-debug-server.mm @@ -5,13 +5,13 @@ // Created by Kyle on 2024/1/11. // Audited for 2021 Release -#include "og-debug-server.hpp" +#include #if OG_TARGET_OS_DARWIN #include "OGGraphDescription.h" -#include "../Util/log.hpp" -#include "../Util/assert.hpp" -#include "../Graph/Graph.hpp" +#include +#include +#include #include #include diff --git a/Sources/OpenGraphCxx/Graph/Graph.cpp b/Sources/OpenGraphCxx/Graph/Graph.cpp index 55abe35b..871edb2b 100644 --- a/Sources/OpenGraphCxx/Graph/Graph.cpp +++ b/Sources/OpenGraphCxx/Graph/Graph.cpp @@ -2,8 +2,8 @@ // Graph.cpp // OpenGraphCxx -#include "Graph.hpp" -#include "Subgraph.hpp" +#include +#include #include "OGGraphDescription.h" #if !OG_TARGET_OS_WASI diff --git a/Sources/OpenGraphCxx/Graph/Graph.mm b/Sources/OpenGraphCxx/Graph/Graph.mm index b8df9392..aa8ac034 100644 --- a/Sources/OpenGraphCxx/Graph/Graph.mm +++ b/Sources/OpenGraphCxx/Graph/Graph.mm @@ -2,7 +2,7 @@ // Graph.mm // OpenGraphCxx -#include "Graph.hpp" +#include #include "OGGraphDescription.h" #if OG_OBJC_FOUNDATION diff --git a/Sources/OpenGraphCxx/Graph/GraphContext.cpp b/Sources/OpenGraphCxx/Graph/GraphContext.cpp index b9b7b192..a87e8bf5 100644 --- a/Sources/OpenGraphCxx/Graph/GraphContext.cpp +++ b/Sources/OpenGraphCxx/Graph/GraphContext.cpp @@ -5,9 +5,9 @@ // Created by Kyle on 2024/2/16. // -#include "Graph.hpp" +#include #include "OGGraph.h" -#include "../Util/assert.hpp" +#include OG::Graph::Context &OG::Graph::Context::from_cf(OGGraphRef storage) OG_NOEXCEPT { if (storage->context.isInvalid()) { diff --git a/Sources/OpenGraphCxx/Graph/GraphDescription.cpp b/Sources/OpenGraphCxx/Graph/GraphDescription.cpp index e2de2323..6cbd088c 100644 --- a/Sources/OpenGraphCxx/Graph/GraphDescription.cpp +++ b/Sources/OpenGraphCxx/Graph/GraphDescription.cpp @@ -4,8 +4,8 @@ #include "OGGraphDescription.h" #include "OGGraph.h" -#include "Graph.hpp" -#include "../Util/assert.hpp" +#include +#include CFTypeRef OGGraphDescription(OGGraphRef graph, CFDictionaryRef options) { #if OG_OBJC_FOUNDATION diff --git a/Sources/OpenGraphCxx/Graph/GraphDescription.mm b/Sources/OpenGraphCxx/Graph/GraphDescription.mm index 0c704a85..e0abc8bb 100644 --- a/Sources/OpenGraphCxx/Graph/GraphDescription.mm +++ b/Sources/OpenGraphCxx/Graph/GraphDescription.mm @@ -4,8 +4,8 @@ #include "OGGraphDescription.h" #include "OGGraph.h" -#include "Graph.hpp" -#include "../Util/assert.hpp" +#include +#include #if OG_OBJC_FOUNDATION diff --git a/Sources/OpenGraphCxx/Graph/OGGraph.cpp b/Sources/OpenGraphCxx/Graph/OGGraph.cpp index dde22526..9f3c48d4 100644 --- a/Sources/OpenGraphCxx/Graph/OGGraph.cpp +++ b/Sources/OpenGraphCxx/Graph/OGGraph.cpp @@ -6,9 +6,9 @@ // #include "OGGraph.h" -#include "Graph.hpp" -#include "../Util/assert.hpp" -#include "../Data/ClosureFunction.hpp" +#include +#include +#include #include OGGraphRef OGGraphCreate() { diff --git a/Sources/OpenGraphCxx/Graph/OGSubgraph.cpp b/Sources/OpenGraphCxx/Graph/OGSubgraph.cpp index 8aaa4b76..13423d26 100644 --- a/Sources/OpenGraphCxx/Graph/OGSubgraph.cpp +++ b/Sources/OpenGraphCxx/Graph/OGSubgraph.cpp @@ -7,10 +7,10 @@ #include "OGSubgraph.h" #include "OGGraph.h" -#include "Subgraph.hpp" +#include #include "OGGraphContext.h" -#include "../Util/assert.hpp" -#include "../Util/env.hpp" +#include +#include #include #if !OG_TARGET_OS_WASI #include diff --git a/Sources/OpenGraphCxx/Graph/Subgraph.cpp b/Sources/OpenGraphCxx/Graph/Subgraph.cpp index 43588802..ad2b626a 100644 --- a/Sources/OpenGraphCxx/Graph/Subgraph.cpp +++ b/Sources/OpenGraphCxx/Graph/Subgraph.cpp @@ -5,7 +5,7 @@ // Created by Kyle on 2024/2/15. // -#include "Subgraph.hpp" +#include #include "OGSubgraph.h" pthread_key_t OG::Subgraph::_current_subgraph_key; diff --git a/Sources/OpenGraphCxx/Graph/Subgraph.hpp b/Sources/OpenGraphCxx/Graph/Subgraph.hpp index 6d358d17..9f196391 100644 --- a/Sources/OpenGraphCxx/Graph/Subgraph.hpp +++ b/Sources/OpenGraphCxx/Graph/Subgraph.hpp @@ -9,10 +9,10 @@ #define Subgraph_hpp #include "OGBase.h" -#include "Graph.hpp" +#include #include -#include "../Data/ClosureFunction.hpp" -#include "../Runtime/metadata.hpp" +#include +#include #include typedef struct OG_BRIDGED_TYPE(id) OGSubgraphStorage * OGSubgraphRef; diff --git a/Sources/OpenGraphCxx/Runtime/OGTupleType.cpp b/Sources/OpenGraphCxx/Runtime/OGTupleType.cpp index 793c18ee..353929ad 100644 --- a/Sources/OpenGraphCxx/Runtime/OGTupleType.cpp +++ b/Sources/OpenGraphCxx/Runtime/OGTupleType.cpp @@ -6,8 +6,8 @@ // Status: Complete #include "OGTupleType.h" -#include "metadata.hpp" -#include "../Util/assert.hpp" +#include +#include #ifdef OPENGRAPH_SWIFT_TOOLCHAIN_SUPPORTED #include diff --git a/Sources/OpenGraphCxx/Runtime/OGTypeID.cpp b/Sources/OpenGraphCxx/Runtime/OGTypeID.cpp index 0394525f..356471e4 100644 --- a/Sources/OpenGraphCxx/Runtime/OGTypeID.cpp +++ b/Sources/OpenGraphCxx/Runtime/OGTypeID.cpp @@ -6,8 +6,8 @@ // Status: WIP #include "OGTypeID.h" -#include "metadata.hpp" -#include "../Util/assert.hpp" +#include +#include #ifdef OPENGRAPH_SWIFT_TOOLCHAIN_SUPPORTED #include diff --git a/Sources/OpenGraphCxx/Runtime/metadata.cpp b/Sources/OpenGraphCxx/Runtime/metadata.cpp index 320eb629..dd7217f5 100644 --- a/Sources/OpenGraphCxx/Runtime/metadata.cpp +++ b/Sources/OpenGraphCxx/Runtime/metadata.cpp @@ -5,7 +5,7 @@ // Audited for iOS 18.0 // Status: WIP -#include "metadata.hpp" +#include #ifdef OPENGRAPH_SWIFT_TOOLCHAIN_SUPPORTED diff --git a/Sources/OpenGraphCxx/Util/assert.cpp b/Sources/OpenGraphCxx/Util/assert.cpp index e6b64df2..21cbccc3 100644 --- a/Sources/OpenGraphCxx/Util/assert.cpp +++ b/Sources/OpenGraphCxx/Util/assert.cpp @@ -5,8 +5,8 @@ // Created by Kyle on 2024/1/21. // -#include "assert.hpp" -#include "log.hpp" +#include +#include #include #include diff --git a/Sources/OpenGraphCxx/Util/log.cpp b/Sources/OpenGraphCxx/Util/log.cpp index ea52f1ee..80428465 100644 --- a/Sources/OpenGraphCxx/Util/log.cpp +++ b/Sources/OpenGraphCxx/Util/log.cpp @@ -5,7 +5,7 @@ // Created by Kyle on 2024/1/12. // Audited for 2021 Release -#include "log.hpp" +#include #if OG_TARGET_OS_DARWIN diff --git a/Sources/OpenGraphCxx/Util/realloc_vector.cpp b/Sources/OpenGraphCxx/Util/realloc_vector.cpp index 2dff26d3..be8b1daa 100644 --- a/Sources/OpenGraphCxx/Util/realloc_vector.cpp +++ b/Sources/OpenGraphCxx/Util/realloc_vector.cpp @@ -5,8 +5,8 @@ // Created by Kyle on 2024/1/17. // -#include "realloc_vector.hpp" -#include "assert.hpp" +#include +#include #if OG_TARGET_OS_DARWIN #include diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeID.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeID.hpp index de4138ca..2d6a6db8 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeID.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeID.hpp @@ -10,7 +10,7 @@ #include "OGBase.h" #include "OGAttribute.h" -#include "../Util/assert.hpp" +#include namespace OG { class AttributeID final { diff --git a/Sources/OpenGraphCxx/Data/ClosureFunction.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ClosureFunction.hpp similarity index 100% rename from Sources/OpenGraphCxx/Data/ClosureFunction.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ClosureFunction.hpp diff --git a/Sources/OpenGraphCxx/Data/page.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page.hpp similarity index 89% rename from Sources/OpenGraphCxx/Data/page.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page.hpp index 23073351..a741d356 100644 --- a/Sources/OpenGraphCxx/Data/page.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page.hpp @@ -6,7 +6,7 @@ #define page_hpp #include "OGBase.h" -#include "ptr.hpp" +#include namespace OG { namespace data { diff --git a/Sources/OpenGraphCxx/Data/page_const.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page_const.hpp similarity index 100% rename from Sources/OpenGraphCxx/Data/page_const.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page_const.hpp diff --git a/Sources/OpenGraphCxx/Data/ptr.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ptr.hpp similarity index 98% rename from Sources/OpenGraphCxx/Data/ptr.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ptr.hpp index ab0a04a2..7b0e4897 100644 --- a/Sources/OpenGraphCxx/Data/ptr.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ptr.hpp @@ -11,7 +11,7 @@ #include "OGBase.h" #include #include -#include "page_const.hpp" +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/table.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/table.hpp index f43a40ab..0cd94593 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/table.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/table.hpp @@ -6,7 +6,7 @@ #define table_hpp #include "OGBase.h" -#include "../Vector/vector.hpp" +#include #if OG_TARGET_OS_DARWIN #include #else diff --git a/Sources/OpenGraphCxx/Data/zone.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/zone.hpp similarity index 97% rename from Sources/OpenGraphCxx/Data/zone.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Data/zone.hpp index 38cd5791..fde33bc0 100644 --- a/Sources/OpenGraphCxx/Data/zone.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/zone.hpp @@ -6,7 +6,7 @@ #define zone_hpp #include "OGBase.h" -#include "ptr.hpp" +#include namespace OG { namespace data { diff --git a/Sources/OpenGraphCxx/Debug/og-debug-server.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/DebugServer/og-debug-server.hpp similarity index 97% rename from Sources/OpenGraphCxx/Debug/og-debug-server.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/DebugServer/og-debug-server.hpp index f0522912..1bec2730 100644 --- a/Sources/OpenGraphCxx/Debug/og-debug-server.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/DebugServer/og-debug-server.hpp @@ -11,7 +11,7 @@ #include "OGBase.h" #if OG_TARGET_OS_DARWIN #include "OGDebugServer.h" -#include "../Vector/vector.hpp" +#include #include #include diff --git a/Sources/OpenGraphCxx/Graph/Graph.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Graph.hpp similarity index 98% rename from Sources/OpenGraphCxx/Graph/Graph.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Graph.hpp index c6511a37..bec4147a 100644 --- a/Sources/OpenGraphCxx/Graph/Graph.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Graph.hpp @@ -10,7 +10,7 @@ #include "OGGraph.h" #include "OGUniqueID.h" #include "../Private/CFRuntime.h" -#include "../Data/ClosureFunction.hpp" +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Subgraph.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Subgraph.hpp new file mode 100644 index 00000000..9f196391 --- /dev/null +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Subgraph.hpp @@ -0,0 +1,112 @@ +// +// Subgraph.hpp +// +// +// Created by Kyle on 2024/2/15. +// + +#ifndef Subgraph_hpp +#define Subgraph_hpp + +#include "OGBase.h" +#include +#include +#include +#include +#include + +typedef struct OG_BRIDGED_TYPE(id) OGSubgraphStorage * OGSubgraphRef; + +namespace OG { +class SubgraphObject; + +class Subgraph final { +private: + OGSubgraphRef _cf_subgraph; + OGGraphContextStorage& _context; + // TODO + bool _isInvalid; + static pthread_key_t _current_subgraph_key; +public: + // MARK: - CF related + + static Subgraph *from_cf(OGSubgraphRef cf_subgraph) OG_NOEXCEPT; + + OGSubgraphRef to_cf() const OG_NOEXCEPT { + return _cf_subgraph; + } + + // MARK: - pthread related + + OG_INLINE + const static void make_current_subgraph_key() OG_NOEXCEPT { + pthread_key_create(&_current_subgraph_key, nullptr); + } + + OG_INLINE OG_CONSTEXPR + const static pthread_key_t& current_key() OG_NOEXCEPT { + return _current_subgraph_key; + } + + OG_INLINE OG_CONSTEXPR + static Subgraph *get_current() OG_NOEXCEPT { + return (OG::Subgraph*)pthread_getspecific(OG::Subgraph::current_key()); + } + + OG_INLINE OG_CONSTEXPR + static int set_current(Subgraph *subgraph) OG_NOEXCEPT { + return pthread_setspecific(OG::Subgraph::current_key(), subgraph); + } + + // MARK: - Public API + void clear_object() const OG_NOEXCEPT; + void invalidate_and_delete_(bool) const OG_NOEXCEPT; + + void apply(OGAttributeFlags flags, OG::ClosureFunction body) const OG_NOEXCEPT; + + OGUniqueID add_observer(OG::ClosureFunction observer) const OG_NOEXCEPT; + + void begin_tree(OG::AttributeID id, OG::swift::metadata const *type, uint32_t flags) const OG_NOEXCEPT; + void add_tree_value(OG::AttributeID id, OG::swift::metadata const *type, const char* key, uint32_t flags) const OG_NOEXCEPT; + void end_tree(OG::AttributeID id) const OG_NOEXCEPT; + + // MARK: - Init and deinit + + Subgraph(SubgraphObject*, OG::Graph::Context&, OG::AttributeID); + + // MARK: - Getter and setter + + OG_INLINE OG_CONSTEXPR + const OGGraphContextRef get_context() const OG_NOEXCEPT { + return &_context; + } + + OG_INLINE OG_CONSTEXPR + OGGraphContextRef get_context() OG_NOEXCEPT { + return &_context; + } + + OG_INLINE OG_CONSTEXPR + const bool isInvalid() const OG_NOEXCEPT { + return _isInvalid; + } + + OG_INLINE OG_CONSTEXPR + void setInvalid(bool invalid) OG_NOEXCEPT { + _isInvalid = invalid; + } +}; /* Subgraph */ +} /* OG */ + +struct OGSubgraphStorage { + CFRuntimeBase base; + OG::Subgraph *subgraph; +}; + +namespace OG { +class SubgraphObject final { + OGSubgraphStorage storage; +}; +} + +#endif /* Subgraph_hpp */ diff --git a/Sources/OpenGraphCxx/Runtime/metadata.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Runtime/metadata.hpp similarity index 100% rename from Sources/OpenGraphCxx/Runtime/metadata.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Runtime/metadata.hpp diff --git a/Sources/OpenGraphCxx/Util/assert.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/assert.hpp similarity index 100% rename from Sources/OpenGraphCxx/Util/assert.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Util/assert.hpp diff --git a/Sources/OpenGraphCxx/Util/env.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/env.hpp similarity index 100% rename from Sources/OpenGraphCxx/Util/env.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Util/env.hpp diff --git a/Sources/OpenGraphCxx/Util/log.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/log.hpp similarity index 100% rename from Sources/OpenGraphCxx/Util/log.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Util/log.hpp diff --git a/Sources/OpenGraphCxx/Util/realloc_vector.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/realloc_vector.hpp similarity index 100% rename from Sources/OpenGraphCxx/Util/realloc_vector.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Util/realloc_vector.hpp diff --git a/Sources/OpenGraphCxx/Vector/vector.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Vector/vector.hpp similarity index 100% rename from Sources/OpenGraphCxx/Vector/vector.hpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Vector/vector.hpp diff --git a/Sources/OpenGraphCxx/Vector/vector.tpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Vector/vector.tpp similarity index 99% rename from Sources/OpenGraphCxx/Vector/vector.tpp rename to Sources/OpenGraphCxx/include/OpenGraphCxx/Vector/vector.tpp index 98a9a8b7..4e4598fa 100644 --- a/Sources/OpenGraphCxx/Vector/vector.tpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Vector/vector.tpp @@ -5,8 +5,8 @@ // Status: Complete // Modified from https://github.com/jcmosc/Compute/blob/00dfebc2c5852144ac5aada8ebe896b78e5f622a/Sources/ComputeCxx/Vector/Vector.tpp [MIT Lisence] -#include "vector.hpp" -#include "../Util/assert.hpp" +#include +#include #include #if OG_TARGET_OS_DARWIN From 02ed6a549ae3b613f2246207f6d7d707c0412264 Mon Sep 17 00:00:00 2001 From: Kyle Date: Sat, 2 Aug 2025 18:49:00 +0800 Subject: [PATCH 6/6] Update OpenGraphC module --- .../OpenGraphCxx/Attribute/AttributeType.cpp | 2 +- .../OpenGraphCxx/Attribute/OGAttribute.cpp | 2 +- .../Attribute/OGWeakAttribute.cpp | 2 +- .../OpenGraphCxx/Comparison/OGComparison.cpp | 2 +- Sources/OpenGraphCxx/Data/OGUniqueID.c | 2 +- .../DebugServer/OGDebugServer.cpp | 2 +- .../DebugServer/og-debug-server.mm | 2 +- Sources/OpenGraphCxx/Graph/Graph.cpp | 2 +- Sources/OpenGraphCxx/Graph/Graph.mm | 2 +- Sources/OpenGraphCxx/Graph/GraphContext.cpp | 2 +- .../OpenGraphCxx/Graph/GraphDescription.cpp | 4 +-- .../OpenGraphCxx/Graph/GraphDescription.mm | 4 +-- Sources/OpenGraphCxx/Graph/OGGraph.cpp | 2 +- Sources/OpenGraphCxx/Graph/OGGraphContext.cpp | 4 +-- Sources/OpenGraphCxx/Graph/OGGraphTracing.cpp | 2 +- Sources/OpenGraphCxx/Graph/OGSubgraph.cpp | 6 ++-- Sources/OpenGraphCxx/Graph/Subgraph.cpp | 2 +- Sources/OpenGraphCxx/Runtime/OGTupleType.cpp | 2 +- Sources/OpenGraphCxx/Runtime/OGTypeID.cpp | 2 +- Sources/OpenGraphCxx/Version/OGVersion.c | 4 +-- .../OpenGraphCxx/include/OpenGraph-umbrella.h | 29 ------------------- .../include/{ => OpenGraphC}/OGAttribute.h | 20 ++++++------- .../{ => OpenGraphC}/OGAttributeFlags.h | 2 +- .../{ => OpenGraphC}/OGAttributeInfo.h | 4 +-- .../{ => OpenGraphC}/OGAttributeType.h | 4 +-- .../{ => OpenGraphC}/OGAttributeTypeFlags.h | 2 +- .../include/{ => OpenGraphC}/OGBase.h | 0 .../{ => OpenGraphC}/OGCachedValueOptions.h | 2 +- .../{ => OpenGraphC}/OGChangedValueFlags.h | 2 +- .../include/{ => OpenGraphC}/OGComparison.h | 4 +-- .../{ => OpenGraphC}/OGCounterQueryType.h | 2 +- .../include/{ => OpenGraphC}/OGDebugServer.h | 2 +- .../include/{ => OpenGraphC}/OGGraph.h | 6 ++-- .../include/{ => OpenGraphC}/OGGraphContext.h | 4 +-- .../{ => OpenGraphC}/OGGraphDescription.h | 4 +-- .../include/{ => OpenGraphC}/OGGraphTracing.h | 4 +-- .../include/{ => OpenGraphC}/OGInputOptions.h | 2 +- .../{ => OpenGraphC}/OGSearchOptions.h | 2 +- .../include/{ => OpenGraphC}/OGSubgraph.h | 12 ++++---- .../include/{ => OpenGraphC}/OGSwiftSupport.h | 0 .../{ => OpenGraphC}/OGTargetConditionals.h | 0 .../include/{ => OpenGraphC}/OGTupleType.h | 4 +-- .../include/{ => OpenGraphC}/OGTypeID.h | 4 +-- .../include/{ => OpenGraphC}/OGUniqueID.h | 2 +- .../include/{ => OpenGraphC}/OGValue.h | 2 +- .../include/{ => OpenGraphC}/OGValueOptions.h | 2 +- .../include/{ => OpenGraphC}/OGValueState.h | 2 +- .../include/{ => OpenGraphC}/OGVersion.h | 2 +- .../{ => OpenGraphC}/OGWeakAttribute.h | 4 +-- .../include/OpenGraphC/OpenGraph-umbrella.h | 29 +++++++++++++++++++ .../OpenGraphC}/Private/CFRuntime.h | 2 +- .../OpenGraphCxx/Attribute/AttributeID.hpp | 4 +-- .../OpenGraphCxx/Attribute/AttributeType.hpp | 4 +-- .../Comparison/OGComparisonPrivate.h | 6 ++-- .../OpenGraphCxx/Data/ClosureFunction.hpp | 2 +- .../include/OpenGraphCxx/Data/page.hpp | 2 +- .../include/OpenGraphCxx/Data/page_const.hpp | 2 +- .../include/OpenGraphCxx/Data/ptr.hpp | 2 +- .../include/OpenGraphCxx/Data/table.hpp | 2 +- .../include/OpenGraphCxx/Data/zone.hpp | 2 +- .../DebugServer/og-debug-server.hpp | 4 +-- .../include/OpenGraphCxx/Graph/Graph.hpp | 8 ++--- .../include/OpenGraphCxx/Graph/Subgraph.hpp | 2 +- .../include/OpenGraphCxx/Runtime/metadata.hpp | 2 +- .../include/OpenGraphCxx/Util/assert.hpp | 2 +- .../include/OpenGraphCxx/Util/env.hpp | 2 +- .../include/OpenGraphCxx/Util/log.hpp | 2 +- .../OpenGraphCxx/Util/realloc_vector.hpp | 2 +- .../include/OpenGraphCxx/Vector/vector.hpp | 2 +- Sources/OpenGraphCxx/include/module.modulemap | 6 +++- 70 files changed, 137 insertions(+), 133 deletions(-) delete mode 100644 Sources/OpenGraphCxx/include/OpenGraph-umbrella.h rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGAttribute.h (93%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGAttributeFlags.h (93%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGAttributeInfo.h (81%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGAttributeType.h (81%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGAttributeTypeFlags.h (93%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGBase.h (100%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGCachedValueOptions.h (93%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGChangedValueFlags.h (90%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGComparison.h (98%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGCounterQueryType.h (93%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGDebugServer.h (96%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGGraph.h (96%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGGraphContext.h (87%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGGraphDescription.h (95%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGGraphTracing.h (93%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGInputOptions.h (87%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGSearchOptions.h (87%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGSubgraph.h (94%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGSwiftSupport.h (100%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGTargetConditionals.h (100%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGTupleType.h (97%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGTypeID.h (97%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGUniqueID.h (91%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGValue.h (88%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGValueOptions.h (89%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGValueState.h (87%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGVersion.h (91%) rename Sources/OpenGraphCxx/include/{ => OpenGraphC}/OGWeakAttribute.h (90%) create mode 100644 Sources/OpenGraphCxx/include/OpenGraphC/OpenGraph-umbrella.h rename Sources/OpenGraphCxx/{ => include/OpenGraphC}/Private/CFRuntime.h (99%) diff --git a/Sources/OpenGraphCxx/Attribute/AttributeType.cpp b/Sources/OpenGraphCxx/Attribute/AttributeType.cpp index 91c8ede1..c66428ce 100644 --- a/Sources/OpenGraphCxx/Attribute/AttributeType.cpp +++ b/Sources/OpenGraphCxx/Attribute/AttributeType.cpp @@ -5,4 +5,4 @@ // Created by Kyle on 2024/2/17. // -#include "OGAttributeType.h" +#include diff --git a/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp b/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp index 70b9b96f..4f307832 100644 --- a/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp +++ b/Sources/OpenGraphCxx/Attribute/OGAttribute.cpp @@ -5,7 +5,7 @@ // Created by Kyle on 2024/2/16. // -#include "OGAttribute.h" +#include #include #include #include diff --git a/Sources/OpenGraphCxx/Attribute/OGWeakAttribute.cpp b/Sources/OpenGraphCxx/Attribute/OGWeakAttribute.cpp index 686c5474..faad5166 100644 --- a/Sources/OpenGraphCxx/Attribute/OGWeakAttribute.cpp +++ b/Sources/OpenGraphCxx/Attribute/OGWeakAttribute.cpp @@ -5,7 +5,7 @@ // Created by Kyle on 2024/2/27. // -#include "OGWeakAttribute.h" +#include OGWeakAttribute OGCreateWeakAttribute(OGAttribute attribute) { // TODO diff --git a/Sources/OpenGraphCxx/Comparison/OGComparison.cpp b/Sources/OpenGraphCxx/Comparison/OGComparison.cpp index 892a356a..a284e759 100644 --- a/Sources/OpenGraphCxx/Comparison/OGComparison.cpp +++ b/Sources/OpenGraphCxx/Comparison/OGComparison.cpp @@ -2,7 +2,7 @@ // OGCompareValues.cpp // OpenGraphCxx -#include "OGComparison.h" +#include #include const void *OGComparisonStateGetDestination(OGComparisonState state) { diff --git a/Sources/OpenGraphCxx/Data/OGUniqueID.c b/Sources/OpenGraphCxx/Data/OGUniqueID.c index 478c3a91..0657681c 100644 --- a/Sources/OpenGraphCxx/Data/OGUniqueID.c +++ b/Sources/OpenGraphCxx/Data/OGUniqueID.c @@ -5,7 +5,7 @@ // Audited for iOS 18.0 // Status: Complete -#include "OGUniqueID.h" +#include #include OGUniqueID OGMakeUniqueID(void) { diff --git a/Sources/OpenGraphCxx/DebugServer/OGDebugServer.cpp b/Sources/OpenGraphCxx/DebugServer/OGDebugServer.cpp index b516880b..407c0f7c 100644 --- a/Sources/OpenGraphCxx/DebugServer/OGDebugServer.cpp +++ b/Sources/OpenGraphCxx/DebugServer/OGDebugServer.cpp @@ -5,7 +5,7 @@ // Created by Kyle on 2024/2/17. // -#include "OGDebugServer.h" +#include #include #if OG_TARGET_OS_DARWIN diff --git a/Sources/OpenGraphCxx/DebugServer/og-debug-server.mm b/Sources/OpenGraphCxx/DebugServer/og-debug-server.mm index e4d64957..7f301d13 100644 --- a/Sources/OpenGraphCxx/DebugServer/og-debug-server.mm +++ b/Sources/OpenGraphCxx/DebugServer/og-debug-server.mm @@ -8,7 +8,7 @@ #include #if OG_TARGET_OS_DARWIN -#include "OGGraphDescription.h" +#include #include #include #include diff --git a/Sources/OpenGraphCxx/Graph/Graph.cpp b/Sources/OpenGraphCxx/Graph/Graph.cpp index 871edb2b..36d40f6a 100644 --- a/Sources/OpenGraphCxx/Graph/Graph.cpp +++ b/Sources/OpenGraphCxx/Graph/Graph.cpp @@ -4,7 +4,7 @@ #include #include -#include "OGGraphDescription.h" +#include #if !OG_TARGET_OS_WASI #include diff --git a/Sources/OpenGraphCxx/Graph/Graph.mm b/Sources/OpenGraphCxx/Graph/Graph.mm index aa8ac034..06c6e887 100644 --- a/Sources/OpenGraphCxx/Graph/Graph.mm +++ b/Sources/OpenGraphCxx/Graph/Graph.mm @@ -3,7 +3,7 @@ // OpenGraphCxx #include -#include "OGGraphDescription.h" +#include #if OG_OBJC_FOUNDATION #include diff --git a/Sources/OpenGraphCxx/Graph/GraphContext.cpp b/Sources/OpenGraphCxx/Graph/GraphContext.cpp index a87e8bf5..cf21346a 100644 --- a/Sources/OpenGraphCxx/Graph/GraphContext.cpp +++ b/Sources/OpenGraphCxx/Graph/GraphContext.cpp @@ -6,7 +6,7 @@ // #include -#include "OGGraph.h" +#include #include OG::Graph::Context &OG::Graph::Context::from_cf(OGGraphRef storage) OG_NOEXCEPT { diff --git a/Sources/OpenGraphCxx/Graph/GraphDescription.cpp b/Sources/OpenGraphCxx/Graph/GraphDescription.cpp index 6cbd088c..44139547 100644 --- a/Sources/OpenGraphCxx/Graph/GraphDescription.cpp +++ b/Sources/OpenGraphCxx/Graph/GraphDescription.cpp @@ -2,8 +2,8 @@ // GraphDescription.cpp // OpenGraphCxx -#include "OGGraphDescription.h" -#include "OGGraph.h" +#include +#include #include #include diff --git a/Sources/OpenGraphCxx/Graph/GraphDescription.mm b/Sources/OpenGraphCxx/Graph/GraphDescription.mm index e0abc8bb..e9773085 100644 --- a/Sources/OpenGraphCxx/Graph/GraphDescription.mm +++ b/Sources/OpenGraphCxx/Graph/GraphDescription.mm @@ -2,8 +2,8 @@ // GraphDescription.mm // OpenGraphCxx -#include "OGGraphDescription.h" -#include "OGGraph.h" +#include +#include #include #include diff --git a/Sources/OpenGraphCxx/Graph/OGGraph.cpp b/Sources/OpenGraphCxx/Graph/OGGraph.cpp index 9f3c48d4..c0087070 100644 --- a/Sources/OpenGraphCxx/Graph/OGGraph.cpp +++ b/Sources/OpenGraphCxx/Graph/OGGraph.cpp @@ -5,7 +5,7 @@ // Created by Kyle on 2024/2/15. // -#include "OGGraph.h" +#include #include #include #include diff --git a/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp b/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp index af442f95..b876c752 100644 --- a/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp +++ b/Sources/OpenGraphCxx/Graph/OGGraphContext.cpp @@ -5,8 +5,8 @@ // Created by Kyle on 2024/2/16. // -#include "OGGraphContext.h" -#include "../Private/CFRuntime.h" +#include +#include OGGraphRef OGGraphContextGetGraph(OGGraphContextRef context) { return reinterpret_cast(reinterpret_cast(context) - sizeof(CFRuntimeBase)); diff --git a/Sources/OpenGraphCxx/Graph/OGGraphTracing.cpp b/Sources/OpenGraphCxx/Graph/OGGraphTracing.cpp index 45fb3437..f6071f3f 100644 --- a/Sources/OpenGraphCxx/Graph/OGGraphTracing.cpp +++ b/Sources/OpenGraphCxx/Graph/OGGraphTracing.cpp @@ -2,7 +2,7 @@ // OGGraphTracing.mm // OpenGraphCxx -#include "OGGraphTracing.h" +#include void OGGraphStartTracing(_Nullable OGGraphRef graph, OGGraphTraceFlags options) { OGGraphStartTracing2(graph, options, NULL); diff --git a/Sources/OpenGraphCxx/Graph/OGSubgraph.cpp b/Sources/OpenGraphCxx/Graph/OGSubgraph.cpp index 13423d26..daad1a88 100644 --- a/Sources/OpenGraphCxx/Graph/OGSubgraph.cpp +++ b/Sources/OpenGraphCxx/Graph/OGSubgraph.cpp @@ -5,10 +5,10 @@ // Created by Kyle on 2024/2/15. // -#include "OGSubgraph.h" -#include "OGGraph.h" +#include +#include #include -#include "OGGraphContext.h" +#include #include #include #include diff --git a/Sources/OpenGraphCxx/Graph/Subgraph.cpp b/Sources/OpenGraphCxx/Graph/Subgraph.cpp index ad2b626a..82ad4dc1 100644 --- a/Sources/OpenGraphCxx/Graph/Subgraph.cpp +++ b/Sources/OpenGraphCxx/Graph/Subgraph.cpp @@ -6,7 +6,7 @@ // #include -#include "OGSubgraph.h" +#include pthread_key_t OG::Subgraph::_current_subgraph_key; diff --git a/Sources/OpenGraphCxx/Runtime/OGTupleType.cpp b/Sources/OpenGraphCxx/Runtime/OGTupleType.cpp index 353929ad..23b4dd1e 100644 --- a/Sources/OpenGraphCxx/Runtime/OGTupleType.cpp +++ b/Sources/OpenGraphCxx/Runtime/OGTupleType.cpp @@ -5,7 +5,7 @@ // Audited for iOS 18.0 // Status: Complete -#include "OGTupleType.h" +#include #include #include diff --git a/Sources/OpenGraphCxx/Runtime/OGTypeID.cpp b/Sources/OpenGraphCxx/Runtime/OGTypeID.cpp index 356471e4..3d4873eb 100644 --- a/Sources/OpenGraphCxx/Runtime/OGTypeID.cpp +++ b/Sources/OpenGraphCxx/Runtime/OGTypeID.cpp @@ -5,7 +5,7 @@ // Audited for iOS 18.0 // Status: WIP -#include "OGTypeID.h" +#include #include #include diff --git a/Sources/OpenGraphCxx/Version/OGVersion.c b/Sources/OpenGraphCxx/Version/OGVersion.c index 42e3d8de..00e51f39 100644 --- a/Sources/OpenGraphCxx/Version/OGVersion.c +++ b/Sources/OpenGraphCxx/Version/OGVersion.c @@ -2,8 +2,8 @@ // OGVersion.c // OpenGraph -#include "OGBase.h" -#include "OGVersion.h" +#include +#include #if OPENGRAPH_RELEASE == OPENGRAPH_RELEASE_2024 const double OpenGraphVersionNumber __attribute__ ((used)) = (double)6.0; diff --git a/Sources/OpenGraphCxx/include/OpenGraph-umbrella.h b/Sources/OpenGraphCxx/include/OpenGraph-umbrella.h deleted file mode 100644 index 046aabc1..00000000 --- a/Sources/OpenGraphCxx/include/OpenGraph-umbrella.h +++ /dev/null @@ -1,29 +0,0 @@ -#include "OGAttribute.h" -#include "OGAttributeFlags.h" -#include "OGAttributeInfo.h" -#include "OGAttributeType.h" -#include "OGAttributeTypeFlags.h" -#include "OGBase.h" -#include "OGCachedValueOptions.h" -#include "OGChangedValueFlags.h" -#include "OGComparison.h" -#include "OGCounterQueryType.h" -#include "OGDebugServer.h" -#include "OGGraph.h" -#include "OGGraphContext.h" -#include "OGGraphDescription.h" -#include "OGGraphTracing.h" -#include "OGInputOptions.h" -#include "OGSearchOptions.h" -#include "OGSubgraph.h" -#include "OGTupleType.h" -#include "OGTypeID.h" -#include "OGUniqueID.h" -#include "OGValue.h" -#include "OGValueOptions.h" -#include "OGValueState.h" -#include "OGVersion.h" -#include "OGWeakAttribute.h" - -OG_EXPORT double OpenGraphVersionNumber; -OG_EXPORT const unsigned char OpenGraphVersionString[]; diff --git a/Sources/OpenGraphCxx/include/OGAttribute.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGAttribute.h similarity index 93% rename from Sources/OpenGraphCxx/include/OGAttribute.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGAttribute.h index 4514c878..b3e0225a 100644 --- a/Sources/OpenGraphCxx/include/OGAttribute.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGAttribute.h @@ -5,16 +5,16 @@ #ifndef OGAttribute_h #define OGAttribute_h -#include "OGBase.h" -#include "OGAttributeInfo.h" -#include "OGAttributeFlags.h" -#include "OGCachedValueOptions.h" -#include "OGGraph.h" -#include "OGInputOptions.h" -#include "OGTypeID.h" -#include "OGValue.h" -#include "OGValueOptions.h" -#include "OGValueState.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGAttributeFlags.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeFlags.h similarity index 93% rename from Sources/OpenGraphCxx/include/OGAttributeFlags.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeFlags.h index a73730de..8f3958b3 100644 --- a/Sources/OpenGraphCxx/include/OGAttributeFlags.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeFlags.h @@ -8,7 +8,7 @@ #ifndef OGAttributeFlags_h #define OGAttributeFlags_h -#include "OGBase.h" +#include typedef OG_OPTIONS(uint32_t, OGAttributeFlags) { OGAttributeFlagsDefault = 0, diff --git a/Sources/OpenGraphCxx/include/OGAttributeInfo.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeInfo.h similarity index 81% rename from Sources/OpenGraphCxx/include/OGAttributeInfo.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeInfo.h index a9994df5..2bc54f07 100644 --- a/Sources/OpenGraphCxx/include/OGAttributeInfo.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeInfo.h @@ -8,8 +8,8 @@ #ifndef OGAttributeInfo_h #define OGAttributeInfo_h -#include "OGBase.h" -#include "OGAttributeType.h" +#include +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGAttributeType.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeType.h similarity index 81% rename from Sources/OpenGraphCxx/include/OGAttributeType.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeType.h index 0a3dab5e..e255b976 100644 --- a/Sources/OpenGraphCxx/include/OGAttributeType.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeType.h @@ -5,8 +5,8 @@ #ifndef OGAttributeType_h #define OGAttributeType_h -#include "OGBase.h" -#include "OGTypeID.h" +#include +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGAttributeTypeFlags.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeTypeFlags.h similarity index 93% rename from Sources/OpenGraphCxx/include/OGAttributeTypeFlags.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeTypeFlags.h index 8382df17..912d2351 100644 --- a/Sources/OpenGraphCxx/include/OGAttributeTypeFlags.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGAttributeTypeFlags.h @@ -5,7 +5,7 @@ #ifndef OGAttributeTypeFlags_h #define OGAttributeTypeFlags_h -#include "OGBase.h" +#include typedef OG_OPTIONS(uint32_t, OGAttributeTypeFlags) { OGAttributeTypeFlagsDefault = 0, diff --git a/Sources/OpenGraphCxx/include/OGBase.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGBase.h similarity index 100% rename from Sources/OpenGraphCxx/include/OGBase.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGBase.h diff --git a/Sources/OpenGraphCxx/include/OGCachedValueOptions.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGCachedValueOptions.h similarity index 93% rename from Sources/OpenGraphCxx/include/OGCachedValueOptions.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGCachedValueOptions.h index 06721b3b..f5185f31 100644 --- a/Sources/OpenGraphCxx/include/OGCachedValueOptions.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGCachedValueOptions.h @@ -5,7 +5,7 @@ #ifndef OGCachedValueOptions_h #define OGCachedValueOptions_h -#include "OGBase.h" +#include typedef OG_OPTIONS(uint32_t, OGCachedValueOptions) { OGCachedValueOptions_0 = 0, diff --git a/Sources/OpenGraphCxx/include/OGChangedValueFlags.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGChangedValueFlags.h similarity index 90% rename from Sources/OpenGraphCxx/include/OGChangedValueFlags.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGChangedValueFlags.h index 5fc347c5..a6b8d7dc 100644 --- a/Sources/OpenGraphCxx/include/OGChangedValueFlags.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGChangedValueFlags.h @@ -5,7 +5,7 @@ #ifndef OGChangedValueFlags_h #define OGChangedValueFlags_h -#include "OGBase.h" +#include typedef OG_OPTIONS(uint32_t, OGChangedValueFlags) { OGChangedValueFlags_1 = 1 << 0, diff --git a/Sources/OpenGraphCxx/include/OGComparison.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGComparison.h similarity index 98% rename from Sources/OpenGraphCxx/include/OGComparison.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGComparison.h index 271584bf..83b7b8b5 100644 --- a/Sources/OpenGraphCxx/include/OGComparison.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGComparison.h @@ -30,8 +30,8 @@ #ifndef OGComparison_h #define OGComparison_h -#include "OGBase.h" -#include "OGTypeID.h" +#include +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGCounterQueryType.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGCounterQueryType.h similarity index 93% rename from Sources/OpenGraphCxx/include/OGCounterQueryType.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGCounterQueryType.h index d38cb422..96e65295 100644 --- a/Sources/OpenGraphCxx/include/OGCounterQueryType.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGCounterQueryType.h @@ -5,7 +5,7 @@ #ifndef OGCounterQueryType_h #define OGCounterQueryType_h -#include "OGBase.h" +#include typedef OG_ENUM(uint32_t, OGCounterQueryType) { OGCounterQueryType_0, diff --git a/Sources/OpenGraphCxx/include/OGDebugServer.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGDebugServer.h similarity index 96% rename from Sources/OpenGraphCxx/include/OGDebugServer.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGDebugServer.h index 69a10c41..327295ea 100644 --- a/Sources/OpenGraphCxx/include/OGDebugServer.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGDebugServer.h @@ -5,7 +5,7 @@ #ifndef OGDebugServer_h #define OGDebugServer_h -#include "OGBase.h" +#include #if OG_TARGET_OS_DARWIN diff --git a/Sources/OpenGraphCxx/include/OGGraph.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGGraph.h similarity index 96% rename from Sources/OpenGraphCxx/include/OGGraph.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGGraph.h index 9cd6831e..f61896ca 100644 --- a/Sources/OpenGraphCxx/include/OGGraph.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGGraph.h @@ -5,9 +5,9 @@ #ifndef OGGraph_h #define OGGraph_h -#include "OGBase.h" -#include "../Private/CFRuntime.h" -#include "OGCounterQueryType.h" +#include +#include +#include // Note: Place all structure declaration in a single place to avoid header cycle dependency diff --git a/Sources/OpenGraphCxx/include/OGGraphContext.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGGraphContext.h similarity index 87% rename from Sources/OpenGraphCxx/include/OGGraphContext.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGGraphContext.h index 43faf5ae..19cf064a 100644 --- a/Sources/OpenGraphCxx/include/OGGraphContext.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGGraphContext.h @@ -5,8 +5,8 @@ #ifndef OGGraphContext_h #define OGGraphContext_h -#include "OGBase.h" -#include "OGGraph.h" +#include +#include // MARK: - Exported C functions diff --git a/Sources/OpenGraphCxx/include/OGGraphDescription.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGGraphDescription.h similarity index 95% rename from Sources/OpenGraphCxx/include/OGGraphDescription.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGGraphDescription.h index cc07e1c9..fd74e5e3 100644 --- a/Sources/OpenGraphCxx/include/OGGraphDescription.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGGraphDescription.h @@ -5,8 +5,8 @@ #ifndef OGGraphDescription_h #define OGGraphDescription_h -#include "OGBase.h" -#include "OGGraph.h" +#include +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGGraphTracing.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGGraphTracing.h similarity index 93% rename from Sources/OpenGraphCxx/include/OGGraphTracing.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGGraphTracing.h index d6b876f0..fc4c5633 100644 --- a/Sources/OpenGraphCxx/include/OGGraphTracing.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGGraphTracing.h @@ -5,8 +5,8 @@ #ifndef OGGraphTracing_hpp #define OGGraphTracing_hpp -#include "OGBase.h" -#include "OGGraph.h" +#include +#include typedef OG_OPTIONS(uint32_t, OGGraphTraceFlags) { OGGraphTraceFlags_0 = 0, diff --git a/Sources/OpenGraphCxx/include/OGInputOptions.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGInputOptions.h similarity index 87% rename from Sources/OpenGraphCxx/include/OGInputOptions.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGInputOptions.h index 6c2607d0..a49881a3 100644 --- a/Sources/OpenGraphCxx/include/OGInputOptions.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGInputOptions.h @@ -5,7 +5,7 @@ #ifndef OGInputOptions_h #define OGInputOptions_h -#include "OGBase.h" +#include typedef OG_OPTIONS(uint32_t, OGInputOptions) { OGInputOptions_0 = 0, diff --git a/Sources/OpenGraphCxx/include/OGSearchOptions.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGSearchOptions.h similarity index 87% rename from Sources/OpenGraphCxx/include/OGSearchOptions.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGSearchOptions.h index 99c601ee..aba0e1b9 100644 --- a/Sources/OpenGraphCxx/include/OGSearchOptions.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGSearchOptions.h @@ -5,7 +5,7 @@ #ifndef OGSearchOptions_h #define OGSearchOptions_h -#include "OGBase.h" +#include typedef OG_OPTIONS(uint32_t, OGSearchOptions) { OGSearchOptions_0 = 0, diff --git a/Sources/OpenGraphCxx/include/OGSubgraph.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGSubgraph.h similarity index 94% rename from Sources/OpenGraphCxx/include/OGSubgraph.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGSubgraph.h index 417f0b3d..6fb5b444 100644 --- a/Sources/OpenGraphCxx/include/OGSubgraph.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGSubgraph.h @@ -5,12 +5,12 @@ #ifndef OGSubgraph_h #define OGSubgraph_h -#include "OGAttribute.h" -#include "OGAttributeFlags.h" -#include "OGBase.h" -#include "OGGraph.h" -#include "OGUniqueID.h" -#include "../Private/CFRuntime.h" +#include +#include +#include +#include +#include +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGSwiftSupport.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGSwiftSupport.h similarity index 100% rename from Sources/OpenGraphCxx/include/OGSwiftSupport.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGSwiftSupport.h diff --git a/Sources/OpenGraphCxx/include/OGTargetConditionals.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGTargetConditionals.h similarity index 100% rename from Sources/OpenGraphCxx/include/OGTargetConditionals.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGTargetConditionals.h diff --git a/Sources/OpenGraphCxx/include/OGTupleType.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGTupleType.h similarity index 97% rename from Sources/OpenGraphCxx/include/OGTupleType.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGTupleType.h index 0ce2c3ba..460ec901 100644 --- a/Sources/OpenGraphCxx/include/OGTupleType.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGTupleType.h @@ -8,8 +8,8 @@ #ifndef OGTupleType_h #define OGTupleType_h -#include "OGBase.h" -#include "OGTypeID.h" +#include +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGTypeID.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGTypeID.h similarity index 97% rename from Sources/OpenGraphCxx/include/OGTypeID.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGTypeID.h index 23b2fa58..8ed9b4a6 100644 --- a/Sources/OpenGraphCxx/include/OGTypeID.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGTypeID.h @@ -8,8 +8,8 @@ #ifndef OGTypeID_h #define OGTypeID_h -#include "OGBase.h" -#include "OGVersion.h" +#include +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGUniqueID.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGUniqueID.h similarity index 91% rename from Sources/OpenGraphCxx/include/OGUniqueID.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGUniqueID.h index 745c4d12..220a4267 100644 --- a/Sources/OpenGraphCxx/include/OGUniqueID.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGUniqueID.h @@ -8,7 +8,7 @@ #ifndef OGMakeUniqueID_h #define OGMakeUniqueID_h -#include "OGBase.h" +#include typedef long OGUniqueID; OG_EXTERN_C_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGValue.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGValue.h similarity index 88% rename from Sources/OpenGraphCxx/include/OGValue.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGValue.h index af0f1835..f83a5226 100644 --- a/Sources/OpenGraphCxx/include/OGValue.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGValue.h @@ -5,7 +5,7 @@ #ifndef OGValue_h #define OGValue_h -#include "OGBase.h" +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGValueOptions.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGValueOptions.h similarity index 89% rename from Sources/OpenGraphCxx/include/OGValueOptions.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGValueOptions.h index 1dc57fcc..a12d9080 100644 --- a/Sources/OpenGraphCxx/include/OGValueOptions.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGValueOptions.h @@ -5,7 +5,7 @@ #ifndef OGValueOptions_h #define OGValueOptions_h -#include "OGBase.h" +#include typedef OG_OPTIONS(uint32_t, OGValueOptions) { OGValueOptions_0 = 0, diff --git a/Sources/OpenGraphCxx/include/OGValueState.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGValueState.h similarity index 87% rename from Sources/OpenGraphCxx/include/OGValueState.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGValueState.h index 21f33f9e..2a5ba371 100644 --- a/Sources/OpenGraphCxx/include/OGValueState.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGValueState.h @@ -5,7 +5,7 @@ #ifndef OGValueState_h #define OGValueState_h -#include "OGBase.h" +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OGVersion.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGVersion.h similarity index 91% rename from Sources/OpenGraphCxx/include/OGVersion.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGVersion.h index 725a4fd5..5fd7c6f2 100644 --- a/Sources/OpenGraphCxx/include/OGVersion.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGVersion.h @@ -5,7 +5,7 @@ #ifndef OGVersion_h #define OGVersion_h -#include "OGBase.h" +#include #define OPENGRAPH_RELEASE_2021 2021 #define OPENGRAPH_RELEASE_2024 2024 diff --git a/Sources/OpenGraphCxx/include/OGWeakAttribute.h b/Sources/OpenGraphCxx/include/OpenGraphC/OGWeakAttribute.h similarity index 90% rename from Sources/OpenGraphCxx/include/OGWeakAttribute.h rename to Sources/OpenGraphCxx/include/OpenGraphC/OGWeakAttribute.h index 385c5c26..ada838fc 100644 --- a/Sources/OpenGraphCxx/include/OGWeakAttribute.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OGWeakAttribute.h @@ -5,8 +5,8 @@ #ifndef OGWeakAttribute_hpp #define OGWeakAttribute_hpp -#include "OGBase.h" -#include "OGAttribute.h" +#include +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OpenGraphC/OpenGraph-umbrella.h b/Sources/OpenGraphCxx/include/OpenGraphC/OpenGraph-umbrella.h new file mode 100644 index 00000000..a434825f --- /dev/null +++ b/Sources/OpenGraphCxx/include/OpenGraphC/OpenGraph-umbrella.h @@ -0,0 +1,29 @@ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +OG_EXPORT double OpenGraphVersionNumber; +OG_EXPORT const unsigned char OpenGraphVersionString[]; diff --git a/Sources/OpenGraphCxx/Private/CFRuntime.h b/Sources/OpenGraphCxx/include/OpenGraphC/Private/CFRuntime.h similarity index 99% rename from Sources/OpenGraphCxx/Private/CFRuntime.h rename to Sources/OpenGraphCxx/include/OpenGraphC/Private/CFRuntime.h index 958c9d88..b9565aa0 100644 --- a/Sources/OpenGraphCxx/Private/CFRuntime.h +++ b/Sources/OpenGraphCxx/include/OpenGraphC/Private/CFRuntime.h @@ -1,4 +1,4 @@ -#include "OGBase.h" +#include #if OG_TARGET_OS_DARWIN // Copied from https://github.com/apple/swift-corelibs-foundation/blob/d8e8a8b92b3a8af8381a11155328c1bba1c6bd2c/CoreFoundation/Base.subproj/CFRuntime.h /* CFRuntime.h diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeID.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeID.hpp index 2d6a6db8..09bb09e9 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeID.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeID.hpp @@ -8,8 +8,8 @@ #ifndef AttributeID_hpp #define AttributeID_hpp -#include "OGBase.h" -#include "OGAttribute.h" +#include +#include #include namespace OG { diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeType.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeType.hpp index a9fd2421..05c8e494 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeType.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Attribute/AttributeType.hpp @@ -5,8 +5,8 @@ #ifndef AttributeType_hpp #define AttributeType_hpp -#include "OGBase.h" -#include "OGAttributeType.h" +#include +#include namespace OG { struct AttributeType { diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Comparison/OGComparisonPrivate.h b/Sources/OpenGraphCxx/include/OpenGraphCxx/Comparison/OGComparisonPrivate.h index e4d408c9..2595f6e2 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Comparison/OGComparisonPrivate.h +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Comparison/OGComparisonPrivate.h @@ -29,9 +29,9 @@ #ifndef OGComparisonPrivate_h #define OGComparisonPrivate_h -#include "OGBase.h" -#include "OGComparison.h" -#include "OGTypeID.h" +#include +#include +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ClosureFunction.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ClosureFunction.hpp index de905963..78147860 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ClosureFunction.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ClosureFunction.hpp @@ -8,7 +8,7 @@ #ifndef ClosureFunction_hpp #define ClosureFunction_hpp -#include "OGBase.h" +#include #include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page.hpp index a741d356..b72b6b09 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page.hpp @@ -5,7 +5,7 @@ #ifndef page_hpp #define page_hpp -#include "OGBase.h" +#include #include namespace OG { diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page_const.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page_const.hpp index 4cf48bfd..ff75537b 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page_const.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/page_const.hpp @@ -5,7 +5,7 @@ #ifndef page_const_hpp #define page_const_hpp -#include "OGBase.h" +#include namespace OG { namespace data { diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ptr.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ptr.hpp index 7b0e4897..604fd3fd 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ptr.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/ptr.hpp @@ -8,7 +8,7 @@ #ifndef ptr_hpp #define ptr_hpp -#include "OGBase.h" +#include #include #include #include diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/table.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/table.hpp index 0cd94593..1b6f8ed0 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/table.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/table.hpp @@ -5,7 +5,7 @@ #ifndef table_hpp #define table_hpp -#include "OGBase.h" +#include #include #if OG_TARGET_OS_DARWIN #include diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/zone.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/zone.hpp index fde33bc0..c2c83a3e 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/zone.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Data/zone.hpp @@ -5,7 +5,7 @@ #ifndef zone_hpp #define zone_hpp -#include "OGBase.h" +#include #include namespace OG { diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/DebugServer/og-debug-server.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/DebugServer/og-debug-server.hpp index 1bec2730..efa57d99 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/DebugServer/og-debug-server.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/DebugServer/og-debug-server.hpp @@ -8,9 +8,9 @@ #ifndef og_debug_server_hpp #define og_debug_server_hpp -#include "OGBase.h" +#include #if OG_TARGET_OS_DARWIN -#include "OGDebugServer.h" +#include #include #include #include diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Graph.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Graph.hpp index bec4147a..4db8d92a 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Graph.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Graph.hpp @@ -6,10 +6,10 @@ #ifndef Graph_hpp #define Graph_hpp -#include "OGBase.h" -#include "OGGraph.h" -#include "OGUniqueID.h" -#include "../Private/CFRuntime.h" +#include +#include +#include +#include #include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Subgraph.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Subgraph.hpp index 9f196391..c55cc08d 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Subgraph.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Graph/Subgraph.hpp @@ -8,7 +8,7 @@ #ifndef Subgraph_hpp #define Subgraph_hpp -#include "OGBase.h" +#include #include #include #include diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Runtime/metadata.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Runtime/metadata.hpp index dfa51510..b27912a8 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Runtime/metadata.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Runtime/metadata.hpp @@ -8,7 +8,7 @@ #ifndef metadata_hpp #define metadata_hpp -#include "OGBase.h" +#include #ifdef OPENGRAPH_SWIFT_TOOLCHAIN_SUPPORTED #include diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/assert.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/assert.hpp index a2381a53..683c9c7f 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/assert.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/assert.hpp @@ -5,7 +5,7 @@ #ifndef assert_hpp #define assert_hpp -#include "OGBase.h" +#include namespace OG { void precondition_failure(const char *format, ...) __cold __dead2; diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/env.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/env.hpp index c7eb5dab..ae562f38 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/env.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/env.hpp @@ -8,7 +8,7 @@ #ifndef env_hpp #define env_hpp -#include "OGBase.h" +#include namespace OG { OG_INLINE diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/log.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/log.hpp index e661d669..ef2bc5c6 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/log.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/log.hpp @@ -8,7 +8,7 @@ #ifndef log_hpp #define log_hpp -#include "OGBase.h" +#include #if OG_TARGET_OS_DARWIN diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/realloc_vector.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/realloc_vector.hpp index 558067bf..ec1c006a 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/realloc_vector.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Util/realloc_vector.hpp @@ -8,7 +8,7 @@ #ifndef realloc_vector_hpp #define realloc_vector_hpp -#include "OGBase.h" +#include OG_ASSUME_NONNULL_BEGIN diff --git a/Sources/OpenGraphCxx/include/OpenGraphCxx/Vector/vector.hpp b/Sources/OpenGraphCxx/include/OpenGraphCxx/Vector/vector.hpp index 331c8adb..f785ac02 100644 --- a/Sources/OpenGraphCxx/include/OpenGraphCxx/Vector/vector.hpp +++ b/Sources/OpenGraphCxx/include/OpenGraphCxx/Vector/vector.hpp @@ -8,7 +8,7 @@ #ifndef vector_hpp #define vector_hpp -#include "OGBase.h" +#include #include #include #include diff --git a/Sources/OpenGraphCxx/include/module.modulemap b/Sources/OpenGraphCxx/include/module.modulemap index 308f9ee9..da511625 100644 --- a/Sources/OpenGraphCxx/include/module.modulemap +++ b/Sources/OpenGraphCxx/include/module.modulemap @@ -1,4 +1,8 @@ module OpenGraphCxx { - header "OpenGraph-umbrella.h" + export * +} + +module OpenGraphCxx.C { + umbrella header "OpenGraphC/OpenGraph-umbrella.h" export * }