blob: e4f706a2c2776e3270e6d9c9847c1981c8c5ebed [file] [log] [blame]
// Copyright 2018 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
package codegen
const syscallDescriptionTmpl = `
{{- define "GenerateSyscallDescription" -}}
# Copyright 2018 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
#
# WARNING: This file is machine generated by fidlgen.
include <{{ .HeaderPath }}>
{{- range .Enums }}
{{ .Name }} =
{{- range $index, $element := .Members -}}
{{- if $index -}},{{- end }} {{ $element }}
{{- end -}}
{{- end }}
{{- range .Bits }}
{{ .Name }} =
{{- range $index, $element := .Members -}}
{{- if $index -}},{{- end }} {{ $element }}
{{- end -}}
{{- end }}
{{- range .Structs }}
{{ template "StructDefinition" . }}
{{- end }}
{{- range .Unions }}
{{ template "UnionDefinition" . }}
{{- end }}
{{ range $protocol := .Protocols -}}
{{ template "ProtocolDefinition" $protocol }}
{{- end -}}
{{- end -}}
`