Class CurryExp

All Implemented Interfaces:
gnu.kawa.format.Printable, Named, SourceLocator, SourceLocator, Locator

public class CurryExp extends ApplyExp
A specialized ApplyExp class for curried function calls. I.e. the actual arguments are only an initial subset of the needed arguments. The result is a new function that expects the remaining arguments.
  • Constructor Details

  • Method Details

    • calculateType

      protected Type calculateType()
      Overrides:
      calculateType in class ApplyExp
    • validateApply

      public Expression validateApply(ApplyExp exp, InlineCalls visitor, Type required, Declaration decl)
      Description copied from class: Expression
      Apply inlining transformations on a given ApplyExp. Assumes the ApplyExp's function is this expression, or can be optimized to this expression.
      Overrides:
      validateApply in class Expression
      Parameters:
      exp - an application whose function expression can be simplified to this expression.
      visitor - the context for the current inlining pass
      decl - if non-null, a Declaration bound to this expression.
      Returns:
      an Expression equivalent to the passed-in exp.