def find_first_declaration(<EOL>declarations,<EOL>decl_type=None,<EOL>name=None,<EOL>parent=None,<EOL>recursive=True,<EOL>fullname=None):
decl_matcher = algorithm.match_declaration_t(<EOL>decl_type=decl_type,<EOL>name=name,<EOL>fullname=fullname,<EOL>parent=parent)<EOL>if recursive:<EOL><INDENT>decls = make_flatten(declarations)<EOL><DEDENT>else:<EOL><INDENT>decls = declarations<EOL><DEDENT>for decl in decls:<EOL><INDENT>if decl_matcher(decl):<EOL><INDENT>return decl<EOL><DEDENT><DEDENT>return None<EOL>
Returns first declaration that match criteria, defined by developer.

For more information about arguments see :class:`match_declaration_t`
class.

:rtype: matched declaration :class:`declaration_t` or None