blob: 33086415717eb881c89aaa87526520d8be4d75ea (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
%%%-------------------------------------------------------------------
%%% File : record_pat.erl
%%% Author : Tobias Lindahl <>
%%% Description : Emit warning if a pattern violates the record type
%%%
%%% Created : 21 Oct 2008 by Tobias Lindahl <>
%%%-------------------------------------------------------------------
-module(record_pat).
-export([t/1]).
-record(foo, {bar :: integer()}).
t(#foo{bar=baz}) -> no_way;
t(#foo{bar=1}) -> ok.
|