aboutsummaryrefslogtreecommitdiffstats
path: root/lib/dialyzer/src/dialyzer.hrl
diff options
context:
space:
mode:
authorKostis Sagonas <[email protected]>2011-01-20 19:12:01 +0200
committerKostis Sagonas <[email protected]>2011-01-20 19:12:01 +0200
commitb4c3711c6daa2f171f56b984235969e223ce8f9c (patch)
tree181f6ada7126a8e66ae0876578eb5af0c5346cce /lib/dialyzer/src/dialyzer.hrl
parentfaef041a446314bb228e0e8c88a09241df2798f1 (diff)
downloadotp-b4c3711c6daa2f171f56b984235969e223ce8f9c.tar.gz
otp-b4c3711c6daa2f171f56b984235969e223ce8f9c.tar.bz2
otp-b4c3711c6daa2f171f56b984235969e223ce8f9c.zip
Add a --fullpath option to Dialyzer
This change adds a --fullpath option to Dialyzer, which makes the warning messages contain the full path of the corresponding file. Original patch submitted by Magnus Henoch (legoscia) on 15/9/2010 and cooked to death in the 'pu' branch all this time. The patch was essentially correct and most of it has been used as is, but there have been some changes to make the code slightly prettier, avoid some code duplication, and add documentation to dialyzer's doc files and to its help message.
Diffstat (limited to 'lib/dialyzer/src/dialyzer.hrl')
-rw-r--r--lib/dialyzer/src/dialyzer.hrl14
1 files changed, 8 insertions, 6 deletions
diff --git a/lib/dialyzer/src/dialyzer.hrl b/lib/dialyzer/src/dialyzer.hrl
index 1d98574585..aa3f703af2 100644
--- a/lib/dialyzer/src/dialyzer.hrl
+++ b/lib/dialyzer/src/dialyzer.hrl
@@ -2,7 +2,7 @@
%%%
%%% %CopyrightBegin%
%%%
-%%% Copyright Ericsson AB 2006-2010. All Rights Reserved.
+%%% Copyright Ericsson AB 2006-2011. All Rights Reserved.
%%%
%%% The contents of this file are subject to the Erlang Public License,
%%% Version 1.1, (the "License"); you may not use this file except in
@@ -31,7 +31,7 @@
-define(RET_DISCREPANCIES, 2).
-type dial_ret() :: ?RET_NOTHING_SUSPICIOUS
- | ?RET_INTERNAL_ERROR
+ | ?RET_INTERNAL_ERROR
| ?RET_DISCREPANCIES.
%%--------------------------------------------------------------------
@@ -87,7 +87,7 @@
%%--------------------------------------------------------------------
%% THIS TYPE SHOULD ONE DAY DISAPPEAR -- IT DOES NOT BELONG HERE
%%--------------------------------------------------------------------
-
+
-type ordset(T) :: [T] . %% XXX: temporarily
%%--------------------------------------------------------------------
@@ -102,6 +102,8 @@
-type dial_define() :: {atom(), term()}.
-type dial_option() :: {atom(), term()}.
-type dial_options() :: [dial_option()].
+-type fopt() :: 'basename' | 'fullpath'.
+-type format() :: 'formatted' | 'raw'.
-type label() :: non_neg_integer().
-type rep_mode() :: 'quiet' | 'normal' | 'verbose'.
-type start_from() :: 'byte_code' | 'src_code'.
@@ -137,10 +139,10 @@
erlang_mode = false :: boolean(),
use_contracts = true :: boolean(),
output_file = none :: 'none' | file:filename(),
- output_format = formatted :: 'raw' | 'formatted',
+ output_format = formatted :: format(),
+ filename_opt = basename :: fopt(),
callgraph_file = "" :: file:filename(),
- check_plt = true :: boolean()
- }).
+ check_plt = true :: boolean()}).
-record(contract, {contracts = [] :: [contract_pair()],
args = [] :: [erl_types:erl_type()],