~statik/ubuntu/maverick/erlang/erlang-merge-testing

« back to all changes in this revision

Viewing changes to lib/dialyzer/src/dialyzer_cl_parse.erl

  • Committer: Elliot Murphy
  • Date: 2010-06-08 03:55:44 UTC
  • mfrom: (3.5.6 squeeze)
  • Revision ID: elliot@elliotmurphy.com-20100608035544-dd8zh2swk7jr5rz2
* Merge with Debian unstable; remaining Ubuntu changes:
  - Drop libwxgtk2.8-dev build dependency. Wx isn't in main, and not
    supposed to. (LP #438365)
  - Drop erlang-wx binary.
  - Drop erlang-wx dependency from -megaco, -common-test, and -reltool, they
    do not really need wx. Also drop it from -debugger; the GUI needs wx,
    but it apparently has CLI bits as well, and is also needed by -megaco,
    so let's keep the package for now.
* Added missing symlinks to /usr/include for a few new header files.
* Fixed generation of ${erlang-base:Depends} and ${erlang-x11:Depends}
  substitution variables.
* Added a fix for a re:compile/2 crash on a long regular expression.
* Changed urgency to medium as the change fixes a security bug.
* Manpages in section 1 are needed even if only arch-dependent packages are
  built. So, re-enabled them.
* Fixed HiPE architecture recognition for powerpc Debian architecture.
* Moved xsltproc and fop to build-depends-indep and do not build
  documentation if only architecture-specific packages are built.
* Refreshed all patches.
* Made Emacs look in man5 and man7 for Erlang manpages and added code
  skeleton files to erlang-mode package.
* New upstream release.
* Moved manpages from incorrect sections 4 and 6 to correct 5 and 7
  (closes: #498492).
* Made manpages regexp in Emacs mode match only 3erl pages in section 3.
* Removed docb_gen script which is no longer needed to build manpages.
* Added erlang-doc package which contains documentation in HTML and PDF
  formats. This package replaces erlang-doc-html package and it's easier
  to synchronize it with the main Erlang packages as it's built from
  a single source package (closes: #558451).
* Removed RPATH from ssl and crypto application binaries as required by
  Debian policy.
* Added libwxgtk2.4-dev and libwxgtk2.6-dev to build conflicts.
* Added a few dpendencies for erlang-dialyzer, erlang-et, erlang-observer
  and erlang-examples packages which now call functions from more modules
  than in 1:13.b.3.
* Added a workaround which disables vfork() for hppa architecture
  (closes: #562218).
* Strictened check for JDK 1.5 adding a call to String(int[], int, int)
  because GCJ 4.4 doesn't implement it and OpenJDK isn't available for all
  architectures.
* Fixed erlang-manpages package section.
* Made erlang-depends add only substvars which are requested in
  debian/control file. This minimizes number of warnings from dh_gencontrol.
  Also, improved descriptions of the functions in erlang-depends escript.
* Added erlang-erl-docgen package to erlang-nox dependencies.
* Made dummy packages erlang-nox and erlang-x11 architecture all.
* Cleaned up working with custom substitution variables in debian/rules.
* Reorganized debian/rules to ensure that manpages arent built twice, and
  aren't built at all if only architecture-dependent packages are requested.
* Fixed project links in README.Debian.
* Added a new package erlang-jinterface which provides tools for
  communication of Java programs with Erlang processes. This adds build
  depandency on default-jdk and as a result enables Java module for IDL
  compiler.
* Bumped standards version to 3.8.4.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
%% -*- erlang-indent-level: 2 -*-
2
2
%%-----------------------------------------------------------------------
3
3
%% %CopyrightBegin%
4
 
%% 
5
 
%% Copyright Ericsson AB 2006-2009. All Rights Reserved.
6
 
%% 
 
4
%%
 
5
%% Copyright Ericsson AB 2006-2010. All Rights Reserved.
 
6
%%
7
7
%% The contents of this file are subject to the Erlang Public License,
8
8
%% Version 1.1, (the "License"); you may not use this file except in
9
9
%% compliance with the License. You should have received a copy of the
10
10
%% Erlang Public License along with this software. If not, it can be
11
11
%% retrieved online at http://www.erlang.org/.
12
 
%% 
 
12
%%
13
13
%% Software distributed under the License is distributed on an "AS IS"
14
14
%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
15
15
%% the License for the specific language governing rights and limitations
16
16
%% under the License.
17
 
%% 
 
17
%%
18
18
%% %CopyrightEnd%
19
19
%%
20
20
 
68
68
cl(["--no_check_plt"|T]) ->
69
69
  put(dialyzer_options_check_plt, false),
70
70
  cl(T);
 
71
cl(["-nn"|T]) ->
 
72
  cl(["--no_native"|T]);
 
73
cl(["--no_native"|T]) ->
 
74
  put(dialyzer_options_native, false),
 
75
  cl(T);
71
76
cl(["--plt_info"|T]) ->
72
77
  put(dialyzer_options_analysis_type, plt_info),
73
78
  cl(T);
181
186
      NewTail = command_line(L),
182
187
      cl(NewTail);
183
188
    false ->
184
 
      error("Unknown option: "++H)
 
189
      error("Unknown option: " ++ H)
185
190
  end;
186
191
cl([]) ->
187
192
  {RetTag, Opts} =
191
196
        {plt_info, cl_options()};
192
197
      false ->
193
198
        case get(dialyzer_options_mode) of
194
 
          {gui,_} = GUI -> {GUI, common_options()};
 
199
          {gui, _} = GUI -> {GUI, common_options()};
195
200
          cl ->
196
201
            case get(dialyzer_options_analysis_type) =:= plt_check of
197
202
              true  -> {check_init, cl_options()};
311
316
  S = "Usage: dialyzer [--help] [--version] [--shell] [--quiet] [--verbose]
312
317
                [-pa dir]* [--plt plt] [-Ddefine]* [-I include_dir]* 
313
318
                [--output_plt file] [-Wwarn]* [--src] [--gui | --wx]
314
 
                [-c applications] [-r applications] [-o outfile]
 
319
                [files_or_dirs] [-r dirs] [--apps applications] [-o outfile]
315
320
                [--build_plt] [--add_to_plt] [--remove_from_plt]
316
 
                [--check_plt] [--no_check_plt] [--plt_info] [--get_warnings]
317
 
Options: 
318
 
  -c applications (or --command-line applications)
319
 
      Use Dialyzer from the command line (no GUI) to detect defects in the
320
 
      specified applications (directories or .erl or .beam files)
321
 
  -r applications
322
 
      Same as -c only that directories are searched recursively for 
323
 
      subdirectories containing .erl or .beam files (depending on the 
324
 
      type of analysis)
 
321
                [--check_plt] [--no_check_plt] [--plt_info] [--get_warnings]
 
322
                [--no_native]
 
323
Options:
 
324
  files_or_dirs (for backwards compatibility also as: -c files_or_dirs)
 
325
      Use Dialyzer from the command line to detect defects in the
 
326
      specified files or directories containing .erl or .beam files,
 
327
      depending on the type of the analysis
 
328
  -r dirs
 
329
      Same as the previous but the specified directories are searched
 
330
      recursively for subdirectories containing .erl or .beam files in
 
331
      them, depending on the type of analysis
 
332
  --apps applications
 
333
      Option typically used when building or modifying a PLT as in:
 
334
        dialyzer --build_plt --apps erts kernel stdlib mnesia ...
 
335
      to conveniently refer to library applications corresponding to the
 
336
      Erlang/OTP installation. However, the option is general and can also
 
337
      be used during analysis in order to refer to Erlang/OTP applications.
 
338
      In addition, file or directory names can also be included, as in:
 
339
        dialyzer --apps inets ssl ./ebin ../other_lib/ebin/my_module.beam
325
340
  -o outfile (or --output outfile)
326
341
      When using Dialyzer from the command line, send the analysis
327
342
      results to the specified \"outfile\" rather than to stdout
389
404
      by the file name extension. Supported extensions are: raw, dot, and ps.
390
405
      If something else is used as file name extension, default format '.raw'
391
406
      will be used.
 
407
  --no_native (or -nn)
 
408
      Bypass the native code compilation of some key files that dialyzer
 
409
      heuristically performs when dialyzing many files; this avoids the
 
410
      compilation time but it may result in (much) longer analysis time.
392
411
  --gui
393
412
      Use the gs-based GUI.
394
413
  --wx
432
451
     Include warnings for functions that only return by means of an exception.
433
452
  -Wrace_conditions ***
434
453
     Include warnings for possible race conditions.
 
454
  -Wbehaviours ***
 
455
     Include warnings about behaviour callbacks which drift from the published
 
456
     recommended interfaces.
435
457
  -Wunderspecs ***
436
458
     Warn about underspecified functions 
437
459
     (those whose -spec is strictly more allowing than the success typing).