Opened 5 years ago

Closed 5 years ago

#336 closed defect (fixed)

Snip;Flatten;Forward removes original names

Reported by: amosrobinson Owned by:
Priority: normal Milestone: 0.4.2
Component: Unknown Version: 0.4.1
Keywords: Cc:

Description

Snip;Flatten;Forward with Snip.configSnipLetBody = True removes original names

:set Synth
:flow-lower..
module Test with
letrec {
  foo m
   = let y = add# [Nat#] 1# (add# [Nat#] 2# 1#) in
     let x = add# [Nat#] 5# y in
         x
}
;;

produces

module Test with
letrec {
  foo : ?1 -> Nat#
    = \(x0 : ?1).
      let x1 : Nat# = add# [Nat#] 2# 1# in
      let x2 : Nat# = add# [Nat#] 1# x1 in
      let x4 : Nat# = add# [Nat#] 5# x2 in
      x4
}

note that x and y both lose their names. this only happens when configSnipLetBody is true, which is why normal :set trans doesn't reproduce it.

Change History (1)

comment:1 Changed 5 years ago by amosrobinson

  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.