ソースを参照

fix(emqx_rule_utils): fix Dialyzer warnings

ayodele.akingbule 5 年 前
コミット
8ee98e3f20
1 ファイル変更2 行追加0 行削除
  1. 2 0
      apps/emqx_rule_engine/src/emqx_rule_utils.erl

+ 2 - 0
apps/emqx_rule_engine/src/emqx_rule_utils.erl

@@ -122,10 +122,12 @@ proc_cmd(Tokens, Data, Opts) ->
 
 %% preprocess SQL with place holders
 -spec(preproc_sql(Sql::binary()) -> {prepare_statement(), prepare_params()}).
+-dialyzer({nowarn_function,preproc_sql/1}).
 preproc_sql(Sql) ->
     preproc_sql(Sql, '?').
 
 -spec(preproc_sql(Sql::binary(), ReplaceWith :: '?' | '$n') -> {prepare_statement(), prepare_params()}).
+-dialyzer({nowarn_function,preproc_sql/2}).
 preproc_sql(Sql, ReplaceWith) ->
     case re:run(Sql, ?EX_PLACE_HOLDER, [{capture, all_but_first, binary}, global]) of
         {match, PlaceHolders} ->