mirror of
https://github.com/justinian/j6-uefi-headers.git
synced 2025-12-10 00:24:32 -08:00
Move function pointer type defs down next to their related members
This commit is contained in:
@@ -25,18 +25,9 @@ namespace uefi {
|
|||||||
namespace protos {
|
namespace protos {
|
||||||
struct {{ name }};
|
struct {{ name }};
|
||||||
|
|
||||||
namespace {{ name }}_impl {
|
|
||||||
{%- for method in methods %}
|
|
||||||
using {{ method.name }} = uefi::status (*)(
|
|
||||||
{%- if not method.get("skip_this", false) -%}uefi::protos::{{ name }} *{%- endif -%}
|
|
||||||
{%- if not method.get("skip_this", false) and method.args %}, {% endif -%}
|
|
||||||
{{ method.args|join(', ', attribute='type') }});
|
|
||||||
{%- endfor %}
|
|
||||||
} // namespace {{ name }}_impl
|
|
||||||
|
|
||||||
struct {{ name }}
|
struct {{ name }}
|
||||||
{
|
{
|
||||||
static constexpr uefi::guid guid{ {{ guid }} };
|
{% if guid %}static constexpr uefi::guid guid{ {{ guid }} };{% endif %}
|
||||||
{% for method in methods %}
|
{% for method in methods %}
|
||||||
inline uefi::status {{ method.name }}(
|
inline uefi::status {{ method.name }}(
|
||||||
{%- for arg in method.args -%}
|
{%- for arg in method.args -%}
|
||||||
@@ -55,9 +46,12 @@ struct {{ name }}
|
|||||||
|
|
||||||
protected:
|
protected:
|
||||||
{%- for method in methods %}
|
{%- for method in methods %}
|
||||||
{{ name }}_impl::{{ method.name }} _{{ method.name }};
|
using _{{ method.name }}_def = uefi::status (*)(
|
||||||
{%- endfor %}
|
{%- if not method.get("skip_this", false) -%}uefi::protos::{{ name }} *{%- endif -%}
|
||||||
|
{%- if not method.get("skip_this", false) and method.args %}, {% endif -%}
|
||||||
|
{{ method.args|join(', ', attribute='type') }});
|
||||||
|
_{{ method.name }}_def _{{ method.name }};
|
||||||
|
{% endfor %}
|
||||||
public:
|
public:
|
||||||
{%- for datum in post_data %}
|
{%- for datum in post_data %}
|
||||||
{{ datum.type }} {{ datum.name }};
|
{{ datum.type }} {{ datum.name }};
|
||||||
|
|||||||
Reference in New Issue
Block a user