getablexprsupport(3)

getablexprsupport3

Gives the expression's support.

Synopsys

#include "abl101.h"
 void ∗getablexprsupport( Expr, Mode )
  chain_list ∗Expr;
  int         Mode;

Parameters

Expr

Expression.

Mode

The returned support's mode.

Overview

getablexprsupport gives the support of Expr. if Mode is ABL_SUPPORT_CHAIN the support is returned using chain_list else it is returned using ptype_list. The support must be freed using the freechain or freeptype functions.

Return value

getablexprsupport returns a pointer to a chain_list or a ptype_list.

Examples

#include "abl101.h"
  chain_list ∗Expr;
  ptype_list ∗Support;
  ptype_list ∗ScanSupport;
  Expr = createablbinexpr( ABL_AND,
                           createablatom( "a" ),
                           createablatom( "b" ) );
  Support = getablexprsupport( Expr, ABL_SUPPORT_PTYPE );
  /* displays a b */
  for ( ScanSupport  = Support; 
        ScanSupport != (ptype_list ∗)0;
        ScanSupport  = ScanSupport->NEXT )
  {
    printf( "%s ", (char *)ScanSupport->DATA );
  }
  freeptype( Support );

Releases

4 releases since Debian 7 (Wheezy); the text changed 1 time.

  1. 7–8
  2. 9–10

From alliance 5.1.1-3 in Debian 10 (Buster). Parsed by carta from the page's man source.