1+ #![ cfg_attr( published_docs, feature( doc_cfg) ) ]
12/*
23 * Copyright (c) godot-rust; Bromeon and contributors.
34 * This Source Code Form is subject to the terms of the Mozilla Public
@@ -42,10 +43,10 @@ pub struct GodotVersion {
4243// Custom mode: Regenerate all files
4344
4445// This file is explicitly included in unit tests. Needs regex dependency.
45- #[ cfg( test) ]
46+ #[ cfg( test) ] # [ cfg_attr ( published_docs , doc ( cfg ( test ) ) ) ]
4647mod godot_version;
4748
48- #[ cfg( feature = "api-custom" ) ]
49+ #[ cfg( feature = "api-custom" ) ] # [ cfg_attr ( published_docs , doc ( cfg ( feature = "api-custom" ) ) ) ]
4950#[ path = "" ]
5051mod depend_on_custom {
5152 use std:: borrow:: Cow ;
@@ -64,7 +65,7 @@ mod depend_on_custom {
6465 godot_exe:: write_gdextension_headers ( h_path, rs_path, false , watch) ;
6566 }
6667
67- #[ cfg( feature = "api-custom-extheader" ) ]
68+ #[ cfg( feature = "api-custom-extheader" ) ] # [ cfg_attr ( published_docs , doc ( cfg ( feature = "api-custom-extheader" ) ) ) ]
6869 pub fn write_gdextension_headers_from_c ( h_path : & Path , rs_path : & Path , watch : & mut StopWatch ) {
6970 godot_exe:: write_gdextension_headers ( h_path, rs_path, true , watch) ;
7071 }
@@ -74,13 +75,13 @@ mod depend_on_custom {
7475 }
7576}
7677
77- #[ cfg( feature = "api-custom" ) ]
78+ #[ cfg( feature = "api-custom" ) ] # [ cfg_attr ( published_docs , doc ( cfg ( feature = "api-custom" ) ) ) ]
7879pub use depend_on_custom:: * ;
7980
8081// ----------------------------------------------------------------------------------------------------------------------------------------------
8182// Custom mode: Generate all files based on user provided JSON.
8283
83- #[ cfg( feature = "api-custom-json" ) ]
84+ #[ cfg( feature = "api-custom-json" ) ] # [ cfg_attr ( published_docs , doc ( cfg ( feature = "api-custom-json" ) ) ) ]
8485#[ path = "" ]
8586mod depend_on_custom_json {
8687 use std:: borrow:: Cow ;
@@ -106,13 +107,13 @@ mod depend_on_custom_json {
106107 }
107108}
108109
109- #[ cfg( feature = "api-custom-json" ) ]
110+ #[ cfg( feature = "api-custom-json" ) ] # [ cfg_attr ( published_docs , doc ( cfg ( feature = "api-custom-json" ) ) ) ]
110111pub use depend_on_custom_json:: * ;
111112
112113// ----------------------------------------------------------------------------------------------------------------------------------------------
113114// Prebuilt mode: Reuse existing files
114115
115- #[ cfg( not( any( feature = "api-custom" , feature = "api-custom-json" ) ) ) ]
116+ #[ cfg( not( any( feature = "api-custom" , feature = "api-custom-json" ) ) ) ] # [ cfg_attr ( published_docs , doc ( cfg ( not ( any ( feature = "api-custom" , feature = "api-custom-json" ) ) ) ) ) ]
116117#[ path = "" ]
117118mod depend_on_prebuilt {
118119 use super :: * ;
@@ -154,7 +155,7 @@ mod depend_on_prebuilt {
154155 }
155156}
156157
157- #[ cfg( not( any( feature = "api-custom" , feature = "api-custom-json" ) ) ) ]
158+ #[ cfg( not( any( feature = "api-custom" , feature = "api-custom-json" ) ) ) ] # [ cfg_attr ( published_docs , doc ( cfg ( not ( any ( feature = "api-custom" , feature = "api-custom-json" ) ) ) ) ) ]
158159pub use depend_on_prebuilt:: * ;
159160
160161// ----------------------------------------------------------------------------------------------------------------------------------------------
@@ -218,7 +219,7 @@ pub fn emit_wasm_nothreads_cfg() {
218219
219220 // The environment variable for target family has a list of applicable families separated by commas.
220221 // For Emscripten in particular, this can be "unix,wasm". Therefore, to check for the Wasm target, we must check each item in the list.
221- #[ cfg( feature = "experimental-wasm-nothreads" ) ]
222+ #[ cfg( feature = "experimental-wasm-nothreads" ) ] # [ cfg_attr ( published_docs , doc ( cfg ( feature = "experimental-wasm-nothreads" ) ) ) ]
222223 if std:: env:: var ( "CARGO_CFG_TARGET_FAMILY" )
223224 . expect ( "target family environment variable" )
224225 . split ( ',' )
0 commit comments