ocsigen/deriving

Name: deriving

Owner: Ocsigen

Description: Extension to OCaml for deriving functions from type declarations.

Created: 2011-01-07 03:49:45.0

Updated: 2017-12-20 02:04:50.0

Pushed: 2017-12-22 17:34:49.0

Homepage: http://code.google.com/p/deriving/

Size: 360

Language: OCaml

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

Deriving (was Deriving-ocsigen)

This release of deriving is based on the library by Jeremy Yallop. See:

Compared to the original library, it adds:

See CHANGES for more details.

Requirements:
Build intructions:
/configure [--disable-tc]
ake

ake install
Documention and examples of the original library:
Examples:
caml
    Objective Caml version 4.01.0

use "topfind";;
 unit = ()
camlp4o;;
Camlp4 Parsing version 4.01.0

require "deriving";;
ype t = A of int | B of t deriving (Show);;
e t = A of int | B of t
ule rec Show_t : sig ... end
how.show<t> (B (A 4));;
 string = "B A 4"
Examples with type-conv:
caml
    Objective Caml version 4.01.0@

use "topfind";;
 unit = ()
camlp4o;;
Camlp4 Parsing version 4.01.0

require "deriving.tc";;
ype t = A of int | B of t with show;;
e t = A of int | B of t
ule rec Show_t : sig ... end

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.