ding-young commented on code in PR #14086:
URL: https://github.com/apache/datafusion/pull/14086#discussion_r1916385249
##########
datafusion/macros/src/user_doc.rs:
##########
@@ -192,13 +186,18 @@ pub fn user_doc(args: TokenStream, input: TokenStream) ->
TokenStream {
let input = parse_macro_input!(input as DeriveInput);
let name = input.clone().ident;
- let doc_section_include: bool = if let Some(doc_section_include) =
doc_section_include
- {
- doc_section_include.value().parse().unwrap()
- } else {
- true
- };
-
+ if doc_section_lbl.is_none() {
+ eprintln!("label for doc_section should exist");
+ }
+ let label = doc_section_lbl.as_ref().unwrap().value();
+ // Try to find a predefined const by label first.
+ // If there is no match but label exists, default value will be used for
include and description
Review Comment:
I made the changes here
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]