Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] View of /branches/vis15/src/compiler/cfg-ir/global-var-kind.sml
ViewVC logotype

View of /branches/vis15/src/compiler/cfg-ir/global-var-kind.sml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3527 - (download) (annotate)
Tue Dec 22 16:44:18 2015 UTC (4 years ago) by jhr
File size: 556 byte(s)
working on merge: adding support for translate between IRs
(* global-var-kind.sml
 *
 * This code is part of the Diderot Project (http://diderot-language.cs.uchicago.edu)
 *
 * COPYRIGHT (c) 2015 The University of Chicago
 * All rights reserved.
 *)

structure GlobalVarKind : sig

    datatype t = ConstVar | InputVar | GlobalVar

    val toString : t -> string
    val same : t * t -> bool

  end = struct

    datatype t = ConstVar | InputVar | GlobalVar

    fun toString ConstVar = "const"
      | toString InputVar = "input"
      | toString GlobalVar = "global"

    fun same (k1 : t, k2) = (k1 = k2)

  end

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0