Record.is_record
You're seeing just the macro
is_record
, go back to Record module for more information.
Checks if the given data
is a record.
This is implemented as a macro so it can be used in guard clauses.
Examples
Record.is_record({User, "john", 27})
#=> true
Record.is_record({})
#=> false
Checks if the given data
is a record of kind kind
.
This is implemented as a macro so it can be used in guard clauses.
Examples
iex> record = {User, "john", 27}
iex> Record.is_record(record, User)
true