Personal tools

Research area

From HaskellWiki

(Difference between revisions)
Jump to: navigation, search
(Rearch area = the golden mine of mine)
Line 5: Line 5:
 
a type , without recompiling existing code, and while retaining static type safety."
 
a type , without recompiling existing code, and while retaining static type safety."
   
A new,simple and clear solution (2008) was given by Dan Popa in a speech scheduled for [[AngloHaskell/2008]] http://www.haskell.org/haskellwiki/AngloHaskell/2008
+
[[Image:The_Expression_problem_Solved_untill_2008.png]]
  +
  +
  +
Ten years later a simple and clear solution (2008) was given by Dan Popa [[User:Ha$kell]] in a speech scheduled for [[AngloHaskell/2008]] http://www.haskell.org/haskellwiki/AngloHaskell/2008
 
You may download the presentation from http://www.haskell.org/sitewiki/images/1/1d/Prezentare-Anglo-Haskell-2008-draft2-more-slides.pdf
 
You may download the presentation from http://www.haskell.org/sitewiki/images/1/1d/Prezentare-Anglo-Haskell-2008-draft2-more-slides.pdf
   
   
 
Why this solution is so interesting and so new:
 
Why this solution is so interesting and so new:
- it did not use a fixpoint operator !!
+
* it did not use a fixpoint operator !!
- it did not use a Maybe (high level embeded) type !!
+
* it did not use a Maybe (high level embeded) type !!
- it did not use '''data''' declaration anymore !!
+
* it did not propose a Haskell extension !!
- it is introducing ''pseudoconstructors over monadic values'' because the chain of unevaluated (yet) functions is actually forming a datastructure . do not forget that Haskell is a lazy evaluation language !!
+
* it did not use '''data''' declaration anymore !!
  +
* as a consequence it did not use Data Constructors anymore !!
  +
* it is introducing ''pseudoconstructors over monadic values'' because the chain of unevaluated (yet) functions is actually forming a datastructure . do not forget that Haskell is a lazy evaluation language !!
   
 
Why this solution is valuable:
 
Why this solution is valuable:
- because we have already built modular languages like [[Rodin]] using it.
+
* because we have already built modular languages like [[Rodin]] using it.
- because it works with just a bit overloading of the system : See final pages of http://www.haskell.org/sitewiki/images/1/1d/Prezentare-Anglo-Haskell-2008-draft2-more-slides.pdf
+
* because it works with just a bit overloading of the system : See final pages of http://www.haskell.org/sitewiki/images/1/1d/Prezentare-Anglo-Haskell-2008-draft2-more-slides.pdf
- because it is modular
+
* because it is modular
- because language construction tools are valuable software (1000$ a Licence for a good language generator.)
+
* because language construction tools are valuable software (1000$ a Licence for a good language generator.)
- because it fits in the previous kind of systems with truee small modifications (just replace a single letter of a data constructor to transform it in a pseudoconstructor ...)
+
* because it fits in the previous kind of systems with truee small modifications (just replace a single letter of a data constructor to transform it in a pseudoconstructor ...)
- because my Ph.D Superviser is wishing to sell custom languages with a price of aprox 10 000$ / language - or at least he declared this some times ago.
+
* because my Ph.D Superviser is wishing to sell custom languages with a price of aprox 10 000$ / language - or at least he declared this some times ago.
   
 
References: see the .pdf of the latest papers from [[User:Ha$kell]]'s homepage.
 
References: see the .pdf of the latest papers from [[User:Ha$kell]]'s homepage.
Line 34: Line 34:
   
 
==. References ==
 
==. References ==
==. Lucrarile publicate in 2008 ==
+
Dan Popa, "Modular evaluation and interpreters using monads and type classes in Haskell" , Studii si Cercetari Ştiinţifice, Seria Matematica, Univ. Bacău, (18) 2008. An Open Office (.sxw) file ''including example code'' is available here:
Dan Popa, "Modular evaluation and interpreters using monads and type classes in Haskell" , Studii si Cercetari Ştiinţifice, Seria Matematica, Univ. Bacău, (18) 2008. An Open Office (.sxw) file is available here:
 
 
[http://www.haskell.org/sitewiki/images/1/15/Paper-v5.sxw Download .sxw ] After loading the .sxw in the Open Office, press the PDF button from the toolbar to produce your own .pdf file. Or
 
[http://www.haskell.org/sitewiki/images/1/15/Paper-v5.sxw Download .sxw ] After loading the .sxw in the Open Office, press the PDF button from the toolbar to produce your own .pdf file. Or
 
[http://www.haskell.org/sitewiki/images/7/7d/POPA_D.pdf Official PDF of the paper for <DOWNLOAD> ], having the following title:
 
[http://www.haskell.org/sitewiki/images/7/7d/POPA_D.pdf Official PDF of the paper for <DOWNLOAD> ], having the following title:

Revision as of 08:10, 3 June 2009

Contents

1 . The Expression Problem

In 1998 P.Wadler had defined "The Expresion Problem" (accordingly to Wouter Swierstra - Data types a la carte ).

"The goal is to define a data type by case, where one can add new cases to the data type and new functions over the dat a type , without recompiling existing code, and while retaining static type safety."

The Expression problem Solved untill 2008.png


Ten years later a simple and clear solution (2008) was given by Dan Popa User:Ha$kell in a speech scheduled for AngloHaskell/2008 http://www.haskell.org/haskellwiki/AngloHaskell/2008 You may download the presentation from http://www.haskell.org/sitewiki/images/1/1d/Prezentare-Anglo-Haskell-2008-draft2-more-slides.pdf


Why this solution is so interesting and so new:

  • it did not use a fixpoint operator !!
  • it did not use a Maybe (high level embeded) type !!
  • it did not propose a Haskell extension !!
  • it did not use data declaration anymore !!
  • as a consequence it did not use Data Constructors anymore !!
  • it is introducing pseudoconstructors over monadic values because the chain of unevaluated (yet) functions is actually forming a datastructure . do not forget that Haskell is a lazy evaluation language !!

Why this solution is valuable:

  • because we have already built modular languages like Rodin using it.
  • because it works with just a bit overloading of the system : See final pages of http://www.haskell.org/sitewiki/images/1/1d/Prezentare-Anglo-Haskell-2008-draft2-more-slides.pdf
  • because it is modular
  • because language construction tools are valuable software (1000$ a Licence for a good language generator.)
  • because it fits in the previous kind of systems with truee small modifications (just replace a single letter of a data constructor to transform it in a pseudoconstructor ...)
  • because my Ph.D Superviser is wishing to sell custom languages with a price of aprox 10 000$ / language - or at least he declared this some times ago.

References: see the .pdf of the latest papers from User:Ha$kell's homepage. Ill be back. Download and read the latest papers of Dan Popa from User:Ha$kell's homepage.

2 . Classic complex solutions

... will be added


3 . Monadic Interpretation

... will be added

4 . References

Dan Popa, "Modular evaluation and interpreters using monads and type classes in Haskell" , Studii si Cercetari Ştiinţifice, Seria Matematica, Univ. Bacău, (18) 2008. An Open Office (.sxw) file including example code is available here: Download .sxw After loading the .sxw in the Open Office, press the PDF button from the toolbar to produce your own .pdf file. Or Official PDF of the paper for <DOWNLOAD> , having the following title:

Direct modular evaluation of expressions using the monads and type classes in Haskell by DAN V. POPA UNIVERSITATEA DIN BACĂU STUDII ŞI CERCETĂRI ŞTIINŢIFICE Seria: MATEMATICĂ Nr. 18 (2008), pag. 233 – 248

The paper is introducing Pseudoconstructors over monadic values as a way of building modular trees without data or Haskell extensions. http://www.haskell.org/sitewiki/images/7/7d/POPA_D.pdf. Modular adaptable interpreters for extensible languages - like Rodin - become now easy to build, without the need of any Haskell extensions.


more ... will be added

5 . History of the domain

... will be added