Package kawa.standard

Class IfFeature

java.lang.Object
kawa.lang.Syntax
kawa.standard.IfFeature
All Implemented Interfaces:
gnu.kawa.format.Printable, Named

public class IfFeature extends Syntax
Implements the Scheme 'cond-expand' syntax. Also provides various static methods relating to "features".
  • Field Details

  • Constructor Details

    • IfFeature

      public IfFeature()
  • Method Details

    • scanForm

      public void scanForm(Pair st, ScopeExp defs, Translator tr)
      Overrides:
      scanForm in class Syntax
    • rewriteForm

      public Expression rewriteForm(Pair form, Translator tr)
      Overrides:
      rewriteForm in class Syntax
    • evaluateConditionCar

      public boolean evaluateConditionCar(Pair pair, Translator tr)
    • evaluateCondition

      public boolean evaluateCondition(Object form, Translator tr)
    • evaluate

      public Object evaluate(Object clauses, Translator tr)
    • hasFeature

      public static boolean hasFeature(String name)
      Check if we implement a named feature.
      Parameters:
      name - an interned feature name
    • featureList

      public static LList featureList()
      Return a (partial) list of features, The result does not include "provide" feature names - though it should. Feature names of the form class:CLASSNAME are not returned.
    • isProvide

      public static boolean isProvide(Declaration decl)