Kiwi Script
KiwiScript Interpreter
 All Data Structures Files Functions Variables Typedefs Enumerations Macros
Data Structures | Enumerations | Functions
KSForStatement.h File Reference

IR for KSForStatement class. More...

#include <KiwiEngine/KiwiEngine.h>
#include "KSStatement.h"
#include "KSForwarders.h"

Go to the source code of this file.

Data Structures

struct  KSForStatement
 

Enumerations

enum  KSForStatementKind { KSForeachCollection, KSForeachRange }
 

Functions

struct KSForStatementKSAllocateForeachCollectionStatement (struct KSVariable *var, struct KSExpression *collection, struct KSCompoundStatement *bodystmt, struct KELineInfo *linfo, struct CNResource *resource)
 Allocate for statement. More...
 
struct KSForStatementKSAllocateForeachRangeStatement (struct KSVariable *var, struct KSExpression *minexp, struct KSExpression *maxexp, struct KSCompoundStatement *bodystmt, struct KELineInfo *linfo, struct CNResource *resource)
 Allocate for statement. More...
 

Detailed Description

IR for KSForStatement class.

Copyright
Copyright (C) 2014 Steel Wheels Project

Enumeration Type Documentation

Kind of for-statement

Function Documentation

struct KSForStatement* KSAllocateForeachCollectionStatement ( struct KSVariable var,
struct KSExpression collection,
struct KSCompoundStatement bodystmt,
struct KELineInfo *  linfo,
struct CNResource *  resource 
)

Allocate for statement.

Returns
Statement object
Parameters
varLoop index variable
collectionCollection expression
bodystmtBody statement
linfoLine information
resourceResource to allocate the object
struct KSForStatement* KSAllocateForeachRangeStatement ( struct KSVariable var,
struct KSExpression minexp,
struct KSExpression maxexp,
struct KSCompoundStatement bodystmt,
struct KELineInfo *  linfo,
struct CNResource *  resource 
)

Allocate for statement.

Returns
Statement object
Parameters
varLoop index variable
minexpMinumum value in range
maxexpMaximum value in range
bodystmtBody statement
linfoLine information
resourceResource to allocate the object