Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Metaprogramming features #4608

Closed
vicuna opened this issue Aug 28, 2008 · 19 comments
Closed

Metaprogramming features #4608

vicuna opened this issue Aug 28, 2008 · 19 comments

Comments

@vicuna
Copy link

vicuna commented Aug 28, 2008

Original bug ID: 4608
Reporter: carette
Status: closed (set by @mshinwell on 2016-12-12T16:14:49Z)
Resolution: not a bug
Priority: normal
Severity: feature
Version: 3.10.2
Category: ~DO NOT USE (was: OCaml general)
Monitored by: @bobzhang ronan.lehy@gmail.com th5 pdonadeo moggi Yoric @glondu till @yallop @hcarty hirokawa @dbuenzli "Christoph Bauer" @oandrieu @mmottl

Bug description

I really wish that the basic features of metaocaml, namely .< >., .~ and .! were included in OCaml proper. The many other experimental features of metaocaml could stay 'experimental', those are the 3 which are sorely needed.

Note that OCaml could be really ahead of Haskell here (with its untyped Template Haskell, which is closer to camlp4 than to metaocaml) by being the first production language to have typed metaprogramming facilities.

@vicuna
Copy link
Author

vicuna commented Sep 12, 2008

Comment author: ccshan

Aye!

@vicuna
Copy link
Author

vicuna commented Sep 12, 2008

Comment author: jdh30

Agreed.

@vicuna
Copy link
Author

vicuna commented Sep 12, 2008

Comment author: philou

Yup would like to get it integrated in mainline ocaml too

@vicuna
Copy link
Author

vicuna commented Sep 12, 2008

Comment author: eaubin

It would be great if ocaml could incorporate basic metaprogramming!

@vicuna
Copy link
Author

vicuna commented Sep 15, 2008

Comment author: taha

I too would like to see this happen, and would be happy to help.

@vicuna
Copy link
Author

vicuna commented Sep 17, 2008

Comment author: ccris

Good idea.
It would also respond to a request appeared in the OCaml Journal:
Metaprogramming with MetaOCaml (27th July 2008)

@vicuna
Copy link
Author

vicuna commented Sep 17, 2008

Comment author: moggi

I support the proposal of making the basic meta-programming features of metaocaml part of OCaml

@vicuna
Copy link
Author

vicuna commented Sep 17, 2008

Comment author: jun0

This would be a fantastic addition to ocaml!

@vicuna
Copy link
Author

vicuna commented Sep 17, 2008

Comment author: ponderosaTX

I strongly support this initiative.

@vicuna
Copy link
Author

vicuna commented Sep 18, 2008

Comment author: bpr

I'd like to see these useful capabilities added to OCaml soon.

@vicuna
Copy link
Author

vicuna commented Sep 18, 2008

Comment author: John Malecki

I've used PE techniques at the companies VLSI Libraries and Artisan Components
to great effect but I used them with Scheme. It would be great to be able to
use them with Ocaml. Not having the PE capability in a production release of
Ocaml prevents me from using MetaOcaml at work.

@vicuna
Copy link
Author

vicuna commented Sep 19, 2008

Comment author: williamc

We'd be interested to use this in the investment bank where I work.

@vicuna
Copy link
Author

vicuna commented Oct 3, 2008

Comment author: herrmann

The metaprogramming constructs .< >., .~, .! are really
useful for type-safe run-time code generation and should
be made part of the standard OCaml distribution, to be sure
that they are available in all future versions of OCaml!

@vicuna
Copy link
Author

vicuna commented Oct 3, 2008

Comment author: squirrel

I think this is a wonderful idea.

@vicuna
Copy link
Author

vicuna commented Oct 3, 2008

Comment author: @yallop

I support this proposal!

@vicuna
Copy link
Author

vicuna commented Oct 3, 2008

Comment author: Yoric

I would simply love that. I can think of plenty of problems which could be solved by such a feature, from boilerplate stuff to optimizations. More than that: I can well see myself using this.

@vicuna
Copy link
Author

vicuna commented Oct 3, 2008

Comment author: pdonadeo

I think it would be great having typed metaprogramming into the standard OCaml distribution.

@vicuna
Copy link
Author

vicuna commented Oct 3, 2008

Comment author: warren

I think this would be great thing to have in the core distribution. It seems that as a feature it overlaps with camlp4 to a large extent, so it would be nice to see these brought more closely together into a unified meta/macro extension.

I've never been thrilled with the syntax chosen for metaocaml though. [|...|] would be a much more natural for quasi-quoting since this what all the academic papers use, although unfortunately it's already in use for arrays. (FWIW, I would probably use metaocaml features much more often than arrays!)

@vicuna
Copy link
Author

vicuna commented Dec 12, 2016

Comment author: @mshinwell

Discussion about incorporating parts of MetaOCaml comes up fairly regularly, but given there have been no specific patches proposed here, I think this old issue is redundant. When and if those responsible for MetaOCaml (or others) would like to pursue further the question of integration we will be pleased to receive patches and discussion via Github as is now usual. That will give a substantive basis on which to proceed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant