Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 13200b0d64
Fetching contributors…

Cannot retrieve contributors at this time

file 59 lines (49 sloc) 2.17 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59
name: xformat
version: 0.1.2
synopsis:

  Extensible, type-safe formatting with scanf- and printf-like functions

homepage: http://github.com/spl/xformat
description:

  /Warning:/ This version of the package is very experimental and the interface
  may change in later versions. I am seeking comments to improve it.
  .
  This package is composed of two functions for formatted conversion between
  strings and typed values. Each is defined as a type-indexed function using a
  type class with multiple parameters and functional dependencies along with
  format descriptors.
  .
  "Text.XFormat.Read" allows one to parse values from a formatted string. Its
  functionality is similar to the C @scanf@ function. Unlike @scanf@, however,
  the format descriptor is well-typed, ensuring that the output type is
  statically known.
  .
  "Text.XFormat.Show" allows one to print values to a formatted string. Its
  functionality is similar to the C @printf@ function. Unlike @printf@, however,
  the format descriptor is well-typed, ensuring that the variable number
  arguments are statically known.
  .
  These functions can be easily extended to support new formats and new types.
  Extension is simple: define a format descriptor and an instance of the
  appropriate class.

category: Text, Generics
copyright: (c) 2009 Sean Leather
license: BSD3
license-file: LICENSE
author: Sean Leather
maintainer: leather@cs.uu.nl
stability: experimental
build-type: Simple
cabal-version: >= 1.9.2
tested-with: GHC == 6.8.3, GHC == 6.10.1, GHC == 7.4.1

--------------------------------------------------------------------------------

Library
  hs-source-dirs: src

  exposed-modules: Text.XFormat.Read
                        Text.XFormat.Show

  build-depends: base >= 3.0 && < 5.0

  ghc-options: -Wall -O2

Test-Suite test
  type: exitcode-stdio-1.0
  hs-source-dirs: test, src
  main-is: Main.hs
  build-depends: base >= 3.0 && < 5.0
Something went wrong with that request. Please try again.