4

after searching the web i could not find an attribute grammar system for F#. Well there is fsyacc with inherited attributes but i am looking for something more expressive like Ox (Ox manual). Actually i would prefer an embedded approach (maybe coupled with fparsec). Well i could go with haskell and the excellent utrecht attribute grammar system (UHC attribute grammar system) but for some reasons i would like to stick with f#.

Note: right now i am using catamorphisms (and dozens of handwritten traversals) all the way in my compiler the code complexity is...just enormous ;-)

any hints?

h_s
  • 111
  • 7

1 Answers1

2

Regarding 'dozens of handwritten traversals', I don't know if it's exactly related, but check out

Scrap Your Boilerplate in f#

in case it helps or provides inspiration.

Community
  • 1
  • 1
Brian
  • 117,631
  • 17
  • 236
  • 300
  • well it is releated in the sense that the presented answer really reduces my code like suggested. Anyway i would prefer a more declarative approach for tree transformations. – h_s Sep 18 '11 at 07:33