Report a bug
If you spot a problem with this page, click here to create a Bugzilla issue.
Improve this page
Quickly fork, edit online, and submit a pull request for this page.
Requires a signed-in GitHub account. This works well for small changes.
If you'd like to make larger changes you may want to consider using
a local clone.
dmd.dstruct
Compiler implementation of the
D programming language.
Authors:
License:
Source dstruct.d
Documentation https://dlang.org/phobos/dmd_dstruct.html
- FuncDeclaration
search_toString(StructDeclarationsd); - Search sd for a member function of the form: extern (D) string toString();Parameters:
StructDeclaration sdstruct declaration to search Returns:FuncDeclaration of toString() if found, null if not - void
semanticTypeInfo(Scope*sc, Typet); - Request additional semantic analysis for TypeInfo generation.Parameters:
Scope* sccontext Type ttype that TypeInfo is being generated for - class
StructDeclaration: dmd.aggregate.AggregateDeclaration; - All struct declarations are an instance of this.
- final bool
fit(ref const Locloc, Scope*sc, Expressions*elements, Typestype); - Fit elements[] to the corresponding types of the struct's fields.Parameters:
Loc loclocation to use for error messages Scope* sccontext Expressions* elementsexplicit arguments used to construct object Type stypethe constructed object type. Returns:false if any errors occur, otherwise true and elements[] are rewritten for the output. - final bool
isPOD(); - Determine if struct is POD (Plain Old Data).POD is defined as:
- not nested
- no postblits, destructors, or assignment operators
- no ref fields or fields that are themselves non-POD
Returns:true if struct is POD
- class
UnionDeclaration: dmd.dstruct.StructDeclaration; - Unions are a variation on structs.
Copyright © 1999-2018 by the D Language Foundation | Page generated by
Ddoc on Thu Nov 1 12:28:19 2018