On 23/08/2013, at 10:03 AM, srean wrote:

> I have a simpler question, could naming scheme of $1, $2  be made more 
> informative, that is allow more verbose identifiers. I find them as a wart in 
> an otherwise pleasant syntax of Felix. Of course to do this one would have to 
> name the arguments in the signature, I think thats a good thing anyway as far 
> as readability and comprehension(human) is concerned.

I agree, actually I suggest if you use:

        fun f: int * int -> int

it stays with numbers but if you use

        fun f(x:int,y:int) : int = """ f ($x. $y) """;

it goes with names.

This would have to apply to type variables as well.


> 
>  Also it would be good to call the underlying C++ compiler on this snippets 
> early for the C++ snippets to get syntax and type checked before Felix 
> generates the entire C++ code and report the errors. The idea is to get 
> feedback on the more easy to understand Felix compilation phase, than at next 
> phase of compilation thats the C++ compilation phase.

This is really hard to do because C++ grammar is not even context free.
One needs to know what is a type name. I don't see how to complle
"snippets" of C++.

The best we can do is use separate compilation (plugins).

--
john skaller
skal...@users.sourceforge.net
http://felix-lang.org




------------------------------------------------------------------------------
Introducing Performance Central, a new site from SourceForge and 
AppDynamics. Performance Central is your source for news, insights, 
analysis and resources for efficient Application Performance Management. 
Visit us today!
http://pubads.g.doubleclick.net/gampad/clk?id=48897511&iu=/4140/ostg.clktrk
_______________________________________________
Felix-language mailing list
Felix-language@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/felix-language

Reply via email to