LtU Forum

a "thank you" to You

for some reason, this week while i've been reading LtU (and also because of some Reddit stuff, to be fair), i've had some important light-bulbs turning on in my head. usually about simple basic things, which is somewhat embarrassing but is also exciting-better-late-than-never.

at any rate, i just wanted to say a Thank You to everybody who has, does, and will continue to make LtU so wonderful.

Unifying map and mapM through subtyping?

In a Haskell-like language, could we unify map :: (a -> b) -> [a] -> [b] and mapM :: (Monad m) => (a -> b) -> [a] -> m [b] (and all the similar pairs like filter/filterM, fold/foldM, ...) by adopting the monadic definitions with the "normal" (suffix-free) names and extending the type system to allow implicit conversion into and out of the Identity monad?

It seems that such conversions aren't as problematic as a general subtyping system, since proving confluence isn't a problem. We'd have to do something to prevent the typechecker from looping indefinitely trying to unify a with Identity a by way of Identity (Identity (Identity (Identity (... a ...)))), but I'm not sure that this would be a problem in practice. (Perhaps by avoiding an explicit transitivity-of-subtyping deduction rule, keeping the Identity-introduction, Identity-elimination, and reflexivity rules as the only deduction rules, and proving that transitivity follows from this?)

Are there other difficulties that this approach might cause? What sort of trickery might be needed to convince an optimizer over a typed intermediate language that the Identity introduction and elimination functions should have no operational effect? (Furthermore, is it true that they should have no effect, or is there a useful distinction between _|_ :: Identity a and Identity _|_ :: Identity a?)

functional equivalance?

reading up on the ADT vs. OO debate, i came across an old comment that "function equality is actually decidable" if only some programming language would actually implement that particular approach. anybody understand that or know of any languages which might support it?

plt vs. something else for programming in the large?

cf. this coverity thread, i'm wondering what your favourite thing / biggest hope is for PLT applied to programming-in-the-large. what are some quantitative things (random e.g. more better typing maybe e.g. dependent or effect)? what are some qualitative things (random e.g. formal methods)? perhaps in other words, what interview questions would you use to suss if somebody knew good p-i-t-l? i'd be curious to know what you think the limits of PLT are here; what about large systems is a non language issue (e.g. managing a large team of people)?

Operational Research (OR)/ Constraint Programming (CP)using GPUs

Dear all:

Recently one sees lot of work on porting computational extensive algorithums on GPUs. I wonder if there is a work or interest with in the CP/OR area in this direction?

Thanks,
malik

Testing release of a platform for hosting pure functional web applications

I'd like to announce the public debut of a service I've been working on. Among other things, it provides "cloud hosting" for web applications written in Ur/Web, a domain-specific functional language for "Web 2.0 programming."

http://www.graftid.com/

This service (called Graftid) also enables communities of developers to work together to build tools that non-programmers can use to build customized web sites quickly. Anyone can upload a site-generator GUI, which is implemented in Ur/Web and also generates Ur/Web code, based on what a user enters into the GUI. Everything is statically-typed, and it's possible to use combinators to minimize the cost of building a new GUI. Every GUI inherits a platform for automatic deployment of applications, without the need to write a line of code that has a server-side side effect.

I'm looking for curious folks who might like to put this platform through its paces, finding bugs, security-oriented and otherwise. I hope that many LtU readers will find this a very pleasant platform for building buzzword-compliant web apps, without the need to learn much about the buzzwords and their associated technologies. :)

I also have a related question that I thought I'd include with this post: We're all used to encapsulation for examples like data structures: a class or module "owns" a representation, and the representation may only be accessed by going through the class or module's published interface. Ur/Web extends this facility to let you code a module that owns a cookie, a database table, a subtree of the client-side DOM for a particular page rendering, etc.. Think "Facebook apps" with static enforcement of which app may touch which resource, but without the need for any dynamic enforcement, and with the possibility for running all the apps on the same server; we just combine first-class web app pieces with standard encapsulation techniques. Does anyone know of any other systems that allow this? Has the desirability of this facility been articulated somewhere?

Embedded Domain-Specific Editors

A REPL can act as an end-user interface provided the language (or a DSL embedded therein) provides adequate support for the target domain.

For example, GHCi can be used as a simple calculator, and for this simple use-case a user needn't be familiar with intricacies of Haskell's type system. However, if necessary, a user can incrementally learn language features beyond that of a calculator, and code can be edited incrementally to utilize these advanced features with relative ease.

Are there any papers on visual languages or paradigms that attempt to bring this idea to GUIs? Specifically, I'm looking for a visual language which supports the creation of rich embedded domain-specific GUIs that, on the surface, behave like traditional GUIs but support powerful and incremental means of abstraction. Many, if not most, GUI applications could arguably benefit from some mechanism of abstraction, but textual interfaces are insufficient for a wide class of problems.

Do you know of any good summer schools on types/programming languages for 2010?

Hello all,

I am currently looking for good international summer schools with a focus on programming language theory and design. I'm a new PhD student, so I don't really know where to start looking other than a few recommendations from my supervisor. The best we have found so far seems to be the Oregon Programming Languages Summer School:

http://www.cs.uoregon.edu/research/summerschool/summer10/

This may be the wrong place to ask, but given the diversity of the community here I thought there may be a few academics or other PhD students who may be able to give me some pointers, at least to places where I can start looking. Is there any such thing as a directory of summer schools that anyone knows of?

Small PL Thought Experiment

Understand that, in addition to how the though experiment is formulated, this forum topic is also very much a question about the most profitable direction of my own future educational development regarding the theory, applicability, development pragmatics and implementation techniques of programming language "paradigms."

1) Imagine a simple language with features roughly the intersection of existing languages similar to ML or Haskell (and a host of similar, more obscure languages):

   * "mostly functional"
   * manifestly typed, 
   * a type inference system (maybe only "local" type inference)
   * algebraic data types
   * parametric polymorphism
   * a simple name space management oriented module system with the 
     possible addition of optional module level type parameters, 
     largely as a convenience feature - example) imagine something 
     simple such as: import ListLib[Int] as intls;
   * a "rich" pattern matching facility, perhaps with a pattern 
     variable unification feature included (.e.g., equality testing)
   * a "principle of least surprise" syntax friendly to constructing 
     manipulating lists, vectors, hash dictionaries, trees and other 
     sequences and data structures. 

2) Presume the accouterments of nicely supported modern language implementations:

 * a suitable FFI
 * common libraries such as regex, tcp/ip networking, a low level 
   interface to the operating system's preemptive threading system, 
 * library interface to all other common operating system features, such as
   memory mapped files, shared memory, process control, and so on and so forth.'
 * boring libraries for parsing the oodles of data formats floating around
   the world: XML and friends, JSON, text and numeric data files both text and
   and binary formatted, all the common RFC described file formats
 * some suitable full bore language parsing system
 * an Emacs major mode (or perhaps Visual Studio or Eclipse integration 
   if that floats your boat)
 * a source level debugger
 * at least some basic "from-source" documentation generation system
   such as Java Doc or its nicer brethren, whatever.

The goal here is to describe and envision a nice, but still mostly generic, simple and rather "innovation free" BASE LANGUAGE judged "practical and suitable to production development" by the criteria commonly applied to other (functional?) languages circa 2010.

THE THOUGHT EXPERIMENT: If one could add a significant new language feature or new additional "programming paradigm" (and thus, of course, attendant syntax extensions, compiler technology, runtime system, etc.) to this intentionally commonplace BASE LANGUAGE:

  * What would that new feature or new added language "paradigm" be?
  * What new problems would this language addition solve? 
  * Or perhaps an alternate motivation, what additional 
    "expressiveness" might it add to the language?
  * Why is this particular language technology "more important" than
    other options?
  * In what problem domains would this new feature or added paradigm
    be most useful (or is it mostly domain neutral/universal)
  * Does a "feature combination" or "multi paradigm" language such
    as, or similar to, this already exist?   

I truly appreciate any thoughtful answers, which may greatly influence where I "go next" in my ongoing studies of programming languages and their implementation.

Thanks a million in advance!

Historical question

We all know K&R begins with the Hello World program. But what is the earliest use of this as an example program?

XML feed