Ruby Dflat implementation