mirror of
https://github.com/facebook/react-native.git
synced 2026-11-18 20:19:07 +00:00
Handle template variables in the API snapshot (#56068)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/56068 Changelog: [Internal] Adds support for templates in variable declaration to the c++ API snapshot generator Reviewed By: cipolleschi Differential Revision: D96279463 fbshipit-source-id: eb68f97f926e4a407d6c7fa2dda6edf7e43e23ba
This commit is contained in:
1 parent
4b4ae62e95
commit
882dbe0118
5 files changed
+38
-2
No files matched your search
@@ -249,7 +249,7 @@ def get_variable_member(
|
||||
if initializer_type == InitializerType.BRACE:
|
||||
is_brace_initializer = True
|
||||
|
||||
return VariableMember(
|
||||
member = VariableMember(
|
||||
variable_name,
|
||||
variable_type,
|
||||
visibility,
|
||||
@@ -263,6 +263,10 @@ def get_variable_member(
|
||||
is_brace_initializer,
|
||||
)
|
||||
|
||||
member.add_template(get_template_params(member_def))
|
||||
|
||||
return member
|
||||
|
||||
|
||||
def get_doxygen_params(
|
||||
function_def: compound.MemberdefType,
|
||||
|
||||
@@ -162,6 +162,9 @@ class VariableMember(Member):
|
||||
|
||||
result = " " * indent
|
||||
|
||||
if self.template_list is not None:
|
||||
result += self.template_list.to_string() + "\n" + " " * indent
|
||||
|
||||
if not hide_visibility:
|
||||
result += self.visibility + " "
|
||||
|
||||
|
||||
Reference in new issue
Block a user