kouzdra (kouzdra) wrote,
kouzdra
kouzdra

Еще ml-ное в данном случае

Вроде бы напрашивающая конструкция: вместо

function
    | Crel (a, Clt, b) -> self#int_bin "<"  a b 
    | Crel (a, Cle, b) -> self#int_bin "<=" a b 
    | Crel (a, Cgt, b) -> self#int_bin ">"  a b 
    | Crel (a, Cge, b) -> self#int_bin ">=" a b 
    ...


Писать:

function
    | Crel (a, Clt => "<"  as op, b)
    | Crel (a, Cle => "<=" as op, b)
    | Crel (a, Cgt => ">"  as op, b)
    | Crel (a, Cge => ">=" as op, b) -> self#int_bin op a b 
...


Но не умеет...
Tags: #int_bin
Subscribe

Recent Posts from This Journal

  • Post a new comment

    Error

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

    When you submit the form an invisible reCAPTCHA check will be performed.
    You must follow the Privacy Policy and Google Terms of use.
  • 1 comment