/tutorial/backtracking/tiny_prolog/prolog_compound.e

http://github.com/tybor/Liberty · Specman e · 8 lines · 8 code · 0 blank · 0 comment · 0 complexity · 8a703f54f6fdc439fcfb4ec6887b3e67 MD5 · raw file

  1. class PROLOG_COMPOUND
  2. inherit PROLOG_TERM redefine arity end
  3. feature
  4. type: INTEGER is type_compound
  5. arity is do Result := args.count end
  6. atom: PROLOG_ATOM
  7. args: FAST_ARRAY[PROLOG_TERM]
  8. end