Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Download

open-axiom repository from github

24005 views

)abbrev package BUG Bug
Bug(): Public == Private where
  Public == with
    getCtorKindInString: Identifier -> String    
    getCtorKind:         Identifier -> ConstructorKind
  Private == add
    getCtorKind(c: Identifier): ConstructorKind == 
      kind(retract(findConstructor(c)$Constructor)$(Maybe Constructor))$Constructor

    getCtorKindInString(c: Identifier): String ==
      k : ConstructorKind := getCtorKind(c)
      k = category$ConstructorKind =>  "Category"
      k = package$ConstructorKind  =>  "Package"
      k = domain$ConstructorKind   => "Domain"
      "unknown constructor kind! "