Changeset 36680 in project


Ignore:
Timestamp:
10/05/18 18:16:50 (10 days ago)
Author:
megane
Message:

Fix markup

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wiki/scrutinizer

    r36679 r36680  
    2121It consists of three things:
    2222
    23 ; type database : This is populated from the .types files before the
    24 walking starts.
     23; type database : This is populated from the .types files before the walking starts.
    2524; e : The second argument to {{walk}}. id -> type alist
    26 ; blist : ("branch list"), when walking {{if}} nodes the variable
    27 types are updated only in the current {{if}} (tree) branch.
     25; blist : ("branch list"), when walking {{if}} nodes the variable types are updated only in the current {{if}} (tree) branch.
    2826
    2927New mappings are added to {{e}} when walking {{let}} nodes (only?).
    3028
    3129=== Some functions
    32 ==== {{(match-types t1 t2 #!optional (typeenv (type-typeenv `(or ,t1 ,t2))) all)}}
     30==== (match-types t1 t2 #!optional (typeenv (type-typeenv `(or ,t1 ,t2))) all)
    3331The heart of the scrutinizer. Basically returns {{#t}} iff {{t2}} is a
    3432subtype of (or of equal type to) {{t1}}.
     
    3836==== scrutinize -> (walk n e loc dest tail flow ctags)
    3937; {{n}} : the canonicalized node (tree)
    40 ; {{e}} : one part of "type environment". An alist from identifiers to
    41 type types.
     38; {{e}} : one part of "type environment". An alist from identifiers to type types.
    4239; {{flow}} and {{ctags}} : related to blist
    4340
     
    6764In {{<branch-c>}} we know {{x}}'s type is {{pair}} in addition to
    6865{{'(list-of symbol)}}. The variable's type will be updated, in {{blist}},
    69 to:
    70 {{(refine-types '(list-of symbol) 'pair)}} which would ideally return
     66to {{(refine-types '(list-of symbol) 'pair)}} which would ideally return
    7167{{(pair symbol (list-of symbol))}}.
    7268
    73 For {{<branch-a>}} {{x}}'s type will be:
    74 
    75 {{(refine-types '(list-of symbol) '(not pair))}} which would ideally
    76 return {{null}}.
     69For {{<branch-a>}} {{x}}'s type will be {{(refine-types '(list-of
     70symbol) '(not pair))}} which would ideally return {{null}}.
    7771
    7872This kind of reasoning is called {{occurence typing}} in the
     
    106100* what is type
    107101* subtype relation
    108 * typeenv / forall / type variables
     102* typeenv / forall / type variables / unification
    109103* how match-types works
Note: See TracChangeset for help on using the changeset viewer.