File tree Expand file tree Collapse file tree 6 files changed +26
-8
lines changed
Expand file tree Collapse file tree 6 files changed +26
-8
lines changed Original file line number Diff line number Diff line change 2020
2121 - name : Get changed files in the codegen folder
2222 id : changed
23- uses : tj-actions/changed-files@v42
23+ uses : tj-actions/changed-files@v45
2424 with :
2525 files : |
2626 .github/workflows/build.yml
Original file line number Diff line number Diff line change 77 runs-on : ubuntu-latest
88 steps :
99 - name : Checkout repo
10- uses : actions/checkout@v3
10+ uses : actions/checkout@v4
1111
1212 - name : Restore cache
1313 id : codegen-cache
14- uses : actions/cache@v3
14+ uses : actions/cache@v4
1515 with :
1616 path : bin
1717 key : codegen-${{ hashFiles('codegen/**') }}
2424 cmake --install build
2525
2626 - name : Upload Codegen binary
27- uses : actions/upload-artifact@v3
27+ uses : actions/upload-artifact@v4
2828 with :
2929 name : Codegen
3030 path : bin/Codegen
@@ -34,10 +34,10 @@ jobs:
3434 needs : build
3535 steps :
3636 - name : Checkout repo
37- uses : actions/checkout@v3
37+ uses : actions/checkout@v4
3838
3939 - name : Download Codegen binary
40- uses : actions/download-artifact@v3
40+ uses : actions/download-artifact@v4
4141 with :
4242 name : Codegen
4343
@@ -128,7 +128,7 @@ jobs:
128128
129129 - name : Set up codegen binary cache
130130 id : codegen-cache
131- uses : actions/cache@v3
131+ uses : actions/cache@v4
132132 with :
133133 path : build/bindings/codegen
134134 # cache by os since for android32 and 64 the codegen binary is the same
Original file line number Diff line number Diff line change @@ -6,3 +6,4 @@ scripts/Bindings.json
66__optcall.xml
77__membercall.xml
88/.vs
9+ ** /.cache
Original file line number Diff line number Diff line change @@ -3388,6 +3388,11 @@ class cocos2d {
33883388 static float clampf (float, float, float);
33893389}
33903390
3391+ [[link (win, android)]]
3392+ void kmGLPushMatrix () = m1 0x1aba8c , imac 0x1f5fa0 ;
3393+ [[link (win, android)]]
3394+ void kmGLPopMatrix () = m1 0x1abad0 , imac 0x1f5fe0 ;
3395+
33913396[[link (win, android)]]
33923397class DS_Dictionary {
33933398 DS_Dictionary () = m1 0x135e9c , imac 0x169200 ;
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ project(Codegen LANGUAGES C CXX)
44include (../cmake/CPM.cmake)
55
66CPMAddPackage("gh:fmtlib/fmt#10.1.1" )
7- CPMAddPackage("gh:geode-sdk/Broma#4243065 " )
7+ CPMAddPackage("gh:geode-sdk/Broma#b8c49c8 " )
88CPMAddPackage("gh:geode-sdk/json#3a79c51" )
99
1010target_compile_definitions (fmt PUBLIC -DFMT_CONSTEVAL=)
Original file line number Diff line number Diff line change @@ -158,6 +158,10 @@ auto {function_name}({parameters}) -> decltype({function_name}({arguments})) {{
158158 }});
159159 return reinterpret_cast<FunctionType>(func)({arguments});
160160}}
161+ )GEN" ;
162+
163+ constexpr char const * declare_standalone_definition = R"GEN(
164+ {return} {function_name}({parameters}) {definition}
161165)GEN" ;
162166}}
163167
@@ -166,6 +170,14 @@ std::string generateBindingSource(Root const& root) {
166170
167171 for (auto & f : root.functions ) {
168172 if (codegen::getStatus (f) != BindStatus::NeedsBinding) {
173+ if (codegen::getStatus (f) == BindStatus::Inlined) {
174+ output += fmt::format (format_strings::declare_standalone_definition,
175+ fmt::arg (" return" , f.prototype .ret .name ),
176+ fmt::arg (" function_name" , f.prototype .name ),
177+ fmt::arg (" parameters" , codegen::getParameters (f.prototype )),
178+ fmt::arg (" definition" , f.inner )
179+ );
180+ }
169181 continue ;
170182 }
171183
You can’t perform that action at this time.
0 commit comments