~ubuntu-branches/ubuntu/trusty/erlang/trusty

« back to all changes in this revision

Viewing changes to lib/hipe/icode/hipe_icode_type.erl

  • Committer: Bazaar Package Importer
  • Author(s): Clint Byrum
  • Date: 2011-05-05 15:48:43 UTC
  • mfrom: (3.5.13 sid)
  • Revision ID: james.westby@ubuntu.com-20110505154843-0om6ekzg6m7ugj27
Tags: 1:14.b.2-dfsg-3ubuntu1
* Merge from debian unstable.  Remaining changes:
  - Drop libwxgtk2.8-dev build dependency. Wx isn't in main, and not
    supposed to.
  - 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.
  - debian/patches/series: Do what I meant, and enable build-options.patch
    instead.
* Additional changes:
  - Drop erlang-wx from -et
* Dropped Changes:
  - patches/pcre-crash.patch: CVE-2008-2371: outer level option with
    alternatives caused crash. (Applied Upstream)
  - fix for ssl certificate verification in newSSL: 
    ssl_cacertfile_fix.patch (Applied Upstream)
  - debian/patches/series: Enable native.patch again, to get stripped beam
    files and reduce the package size again. (build-options is what
    actually accomplished this)
  - Remove build-options.patch on advice from upstream and because it caused
    odd build failures.

Show diffs side-by-side

added added

removed removed

Lines of Context:
2
2
%%
3
3
%% %CopyrightBegin%
4
4
%% 
5
 
%% Copyright Ericsson AB 2003-2009. All Rights Reserved.
6
 
%% 
 
5
%% Copyright Ericsson AB 2003-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
%%%--------------------------------------------------------------------
23
23
%%% Description : Propagate type information.
24
24
%%%
25
25
%%% Created : 25 Feb 2003 by Tobias Lindahl <Tobias.Lindahl@it.uu.se>
26
 
%%%
27
 
%%% $Id$
28
26
%%%--------------------------------------------------------------------
29
27
 
30
28
-module(hipe_icode_type).
78
76
%-define(server_debug, fun(X, Y) -> io:format("~p server: ~s ~p~n", [self(), X, Y]) end).
79
77
-define(server_debug, fun(_, _) -> ok end).
80
78
 
81
 
-import(erl_types, [min/2, max/2, number_min/1, number_max/1,
 
79
-import(erl_types, [number_min/1, number_max/1,
82
80
                    t_any/0, t_atom/1, t_atom/0, t_atom_vals/1,
83
81
                    t_binary/0, t_bitstr/0, t_bitstr_base/1, t_bitstr_unit/1, 
84
82
                    t_boolean/0, t_cons/0, t_constant/0,
494
492
  Min2 = number_min(IntArg2),
495
493
  Max2 = number_max(IntArg2),
496
494
  %% is this the same as erl_types:t_subtract?? no ... ??
497
 
  TrueMax1 = min(Max1, erl_bif_types:infinity_add(Max2, -1)),
498
 
  TrueMin2 = max(erl_bif_types:infinity_add(Min1, 1), Min2),
499
 
  FalseMin1 = max(Min1, Min2),
500
 
  FalseMax2 = min(Max1, Max2),
 
495
  TrueMax1 = erl_types:min(Max1, erl_bif_types:infinity_add(Max2, -1)),
 
496
  TrueMin2 = erl_types:max(erl_bif_types:infinity_add(Min1, 1), Min2),
 
497
  FalseMin1 = erl_types:max(Min1, Min2),
 
498
  FalseMax2 = erl_types:min(Max1, Max2),
501
499
  {t_from_range(Min1, TrueMax1),
502
500
   t_from_range(TrueMin2, Max2),
503
501
   t_from_range(FalseMin1, Max1),