亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? tmpltcmp.c

?? clips源代碼
?? C
字號:
   /*******************************************************/   /*      "C" Language Integrated Production System      */   /*                                                     */   /*             CLIPS Version 6.23  01/31/05            */   /*                                                     */   /*          DEFTEMPLATE CONSTRUCTS-TO-C MODULE         */   /*******************************************************//*************************************************************//* Purpose: Implements the constructs-to-c feature for the   *//*    deftemplate construct.                                 *//*                                                           *//* Principal Programmer(s):                                  *//*      Gary D. Riley                                        *//*                                                           *//* Contributing Programmer(s):                               *//*      Brian L. Donnell                                     *//*                                                           *//* Revision History:                                         *//*      6.23: Added support for templates maintaining their  *//*            own list of facts.                             *//*                                                           *//*************************************************************/#define _TMPLTCMP_SOURCE_#include "setup.h"#if DEFTEMPLATE_CONSTRUCT && CONSTRUCT_COMPILER && (! RUN_TIME)#define SlotPrefix() ArbitraryPrefix(DeftemplateData(theEnv)->DeftemplateCodeItem,2)#include <stdio.h>#define _STDIO_INCLUDED_#include "conscomp.h"#include "factcmp.h"#include "cstrncmp.h"#include "tmpltdef.h"#include "envrnmnt.h"#include "tmpltcmp.h"/***************************************//* LOCAL INTERNAL FUNCTION DEFINITIONS *//***************************************/   static int                     ConstructToCode(void *,char *,int,FILE *,int,int);   static void                    SlotToCode(void *,FILE *,struct templateSlot *,int,int,int);   static void                    DeftemplateModuleToCode(void *,FILE *,struct defmodule *,int,int,int);   static void                    DeftemplateToCode(void *,FILE *,struct deftemplate *,                                                 int,int,int,int);   static void                    CloseDeftemplateFiles(void *,FILE *,FILE *,FILE *,int);   static void                    InitDeftemplateCode(void *,FILE *,int,int);/*********************************************************//* DeftemplateCompilerSetup: Initializes the deftemplate *//*   construct for use with the constructs-to-c command. *//*********************************************************/globle void DeftemplateCompilerSetup(  void *theEnv)  {   DeftemplateData(theEnv)->DeftemplateCodeItem = AddCodeGeneratorItem(theEnv,"deftemplate",0,NULL,InitDeftemplateCode,ConstructToCode,3);  }/*************************************************************//* ConstructToCode: Produces deftemplate code for a run-time *//*   module created using the constructs-to-c function.      *//*************************************************************/static int ConstructToCode(  void *theEnv,  char *fileName,  int fileID,  FILE *headerFP,  int imageID,  int maxIndices)  {   int fileCount = 1;   struct defmodule *theModule;   struct deftemplate *theTemplate;   struct templateSlot *slotPtr;   int slotCount = 0, slotArrayCount = 0, slotArrayVersion = 1;   int moduleCount = 0, moduleArrayCount = 0, moduleArrayVersion = 1;   int templateArrayCount = 0, templateArrayVersion = 1;   FILE *slotFile = NULL, *moduleFile = NULL, *templateFile = NULL;   /*==================================================*/   /* Include the appropriate deftemplate header file. */   /*==================================================*/   fprintf(headerFP,"#include \"tmpltdef.h\"\n");   /*=============================================================*/   /* Loop through all the modules, all the deftemplates, and all */   /* the deftemplate slots writing their C code representation   */   /* to the file as they are traversed.                          */   /*=============================================================*/   theModule = (struct defmodule *) EnvGetNextDefmodule(theEnv,NULL);   while (theModule != NULL)     {      EnvSetCurrentModule(theEnv,(void *) theModule);      moduleFile = OpenFileIfNeeded(theEnv,moduleFile,fileName,fileID,imageID,&fileCount,                                    moduleArrayVersion,headerFP,                                    "struct deftemplateModule",ModulePrefix(DeftemplateData(theEnv)->DeftemplateCodeItem),                                    FALSE,NULL);      if (moduleFile == NULL)        {         CloseDeftemplateFiles(theEnv,moduleFile,templateFile,slotFile,maxIndices);         return(0);        }      DeftemplateModuleToCode(theEnv,moduleFile,theModule,imageID,maxIndices,moduleCount);      moduleFile = CloseFileIfNeeded(theEnv,moduleFile,&moduleArrayCount,&moduleArrayVersion,                                     maxIndices,NULL,NULL);      /*=======================================================*/      /* Loop through each of the deftemplates in this module. */      /*=======================================================*/      theTemplate = (struct deftemplate *) EnvGetNextDeftemplate(theEnv,NULL);      while (theTemplate != NULL)        {         templateFile = OpenFileIfNeeded(theEnv,templateFile,fileName,fileID,imageID,&fileCount,                                         templateArrayVersion,headerFP,                                         "struct deftemplate",ConstructPrefix(DeftemplateData(theEnv)->DeftemplateCodeItem),                                         FALSE,NULL);         if (templateFile == NULL)           {            CloseDeftemplateFiles(theEnv,moduleFile,templateFile,slotFile,maxIndices);            return(0);           }         DeftemplateToCode(theEnv,templateFile,theTemplate,imageID,maxIndices,                        moduleCount,slotCount);         templateArrayCount++;         templateFile = CloseFileIfNeeded(theEnv,templateFile,&templateArrayCount,&templateArrayVersion,                                          maxIndices,NULL,NULL);         /*======================================================*/         /* Loop through each of the slots for this deftemplate. */         /*======================================================*/         slotPtr = theTemplate->slotList;         while (slotPtr != NULL)           {            slotFile = OpenFileIfNeeded(theEnv,slotFile,fileName,fileID,imageID,&fileCount,                                        slotArrayVersion,headerFP,                                       "struct templateSlot",SlotPrefix(),FALSE,NULL);            if (slotFile == NULL)              {               CloseDeftemplateFiles(theEnv,moduleFile,templateFile,slotFile,maxIndices);               return(0);              }            SlotToCode(theEnv,slotFile,slotPtr,imageID,maxIndices,slotCount);            slotCount++;            slotArrayCount++;            slotFile = CloseFileIfNeeded(theEnv,slotFile,&slotArrayCount,&slotArrayVersion,                                         maxIndices,NULL,NULL);            slotPtr = slotPtr->next;           }         theTemplate = (struct deftemplate *) EnvGetNextDeftemplate(theEnv,theTemplate);        }      theModule = (struct defmodule *) EnvGetNextDefmodule(theEnv,theModule);      moduleCount++;      moduleArrayCount++;     }   CloseDeftemplateFiles(theEnv,moduleFile,templateFile,slotFile,maxIndices);   return(1);  }/************************************************************//* CloseDeftemplateFiles: Closes all of the C files created *//*   for deftemplates. Called when an error occurs or when  *//*   the deftemplates have all been written to the files.   *//************************************************************/static void CloseDeftemplateFiles(  void *theEnv,  FILE *moduleFile,  FILE *templateFile,  FILE *slotFile,  int maxIndices)  {   int count = maxIndices;   int arrayVersion = 0;   if (slotFile != NULL)     {      count = maxIndices;      CloseFileIfNeeded(theEnv,slotFile,&count,&arrayVersion,maxIndices,NULL,NULL);     }   if (templateFile != NULL)     {      count = maxIndices;      CloseFileIfNeeded(theEnv,templateFile,&count,&arrayVersion,maxIndices,NULL,NULL);     }   if (moduleFile != NULL)     {      count = maxIndices;      CloseFileIfNeeded(theEnv,moduleFile,&count,&arrayVersion,maxIndices,NULL,NULL);     }  }/*************************************************************//* DeftemplateModuleToCode: Writes the C code representation *//*   of a single deftemplate module to the specified file.   *//*************************************************************/#if IBM_TBC#pragma argsused#endifstatic void DeftemplateModuleToCode(  void *theEnv,  FILE *theFile,  struct defmodule *theModule,  int imageID,  int maxIndices,  int moduleCount)  {#if MAC_MCW || IBM_MCW || MAC_XCD#pragma unused(moduleCount)#endif   fprintf(theFile,"{");   ConstructModuleToCode(theEnv,theFile,theModule,imageID,maxIndices,                         DeftemplateData(theEnv)->DeftemplateModuleIndex,ConstructPrefix(DeftemplateData(theEnv)->DeftemplateCodeItem));   fprintf(theFile,"}");  }/************************************************************//* DeftemplateToCode: Writes the C code representation of a *//*   single deftemplate construct to the specified file.    *//************************************************************/static void DeftemplateToCode(  void *theEnv,  FILE *theFile,  struct deftemplate *theTemplate,  int imageID,  int maxIndices,  int moduleCount,  int slotCount)  {   /*====================*/   /* Deftemplate Header */   /*====================*/   fprintf(theFile,"{");   ConstructHeaderToCode(theEnv,theFile,&theTemplate->header,imageID,maxIndices,                                  moduleCount,ModulePrefix(DeftemplateData(theEnv)->DeftemplateCodeItem),                                  ConstructPrefix(DeftemplateData(theEnv)->DeftemplateCodeItem));   fprintf(theFile,",");   /*===========*/   /* Slot List */   /*===========*/   if (theTemplate->slotList == NULL)     { fprintf(theFile,"NULL,"); }   else     {      fprintf(theFile,"&%s%d_%d[%d],",SlotPrefix(),                 imageID,                 (slotCount / maxIndices) + 1,                 slotCount % maxIndices);     }   /*==========================================*/   /* Implied Flag, Watch Flag, In Scope Flag, */   /* Number of Slots, and Busy Count.         */   /*==========================================*/   fprintf(theFile,"%d,0,0,%d,%ld,",theTemplate->implied,theTemplate->numberOfSlots,theTemplate->busyCount);   /*=================*/   /* Pattern Network */   /*=================*/   if (theTemplate->patternNetwork == NULL)     { fprintf(theFile,"NULL"); }   else     { FactPatternNodeReference(theEnv,theTemplate->patternNetwork,theFile,imageID,maxIndices); }   /*============================================*/   /* Print the factList and lastFact references */   /* and close the structure.                   */   /*============================================*/      fprintf(theFile,",NULL,NULL}");  }/*****************************************************//* SlotToCode: Writes the C code representation of a *//*   single deftemplate slot to the specified file.  *//*****************************************************/static void SlotToCode(  void *theEnv,  FILE *theFile,  struct templateSlot *theSlot,  int imageID,  int maxIndices,  int slotCount)  {   /*===========*/   /* Slot Name */   /*===========*/   fprintf(theFile,"{");   PrintSymbolReference(theEnv,theFile,theSlot->slotName);   /*=============================*/   /* Multislot and Default Flags */   /*=============================*/   fprintf(theFile,",%d,%d,%d,%d,",theSlot->multislot,theSlot->noDefault,                                   theSlot->defaultPresent,theSlot->defaultDynamic);   /*=============*/   /* Constraints */   /*=============*/   PrintConstraintReference(theEnv,theFile,theSlot->constraints,imageID,maxIndices);   /*===============*/   /* Default Value */   /*===============*/   fprintf(theFile,",");   PrintHashedExpressionReference(theEnv,theFile,theSlot->defaultList,imageID,maxIndices);   fprintf(theFile,",");   /*===========*/   /* Next Slot */   /*===========*/   if (theSlot->next == NULL)     { fprintf(theFile,"NULL}"); }   else     {      fprintf(theFile,"&%s%d_%d[%d]}",SlotPrefix(),imageID,                               ((slotCount+1) / maxIndices) + 1,                                (slotCount+1) % maxIndices);     }  }/*****************************************************************//* DeftemplateCModuleReference: Writes the C code representation *//*   of a reference to a deftemplate module data structure.      *//*****************************************************************/globle void DeftemplateCModuleReference(  void *theEnv,  FILE *theFile,  int count,  int imageID,  int maxIndices)  {   fprintf(theFile,"MIHS &%s%d_%d[%d]",ModulePrefix(DeftemplateData(theEnv)->DeftemplateCodeItem),                      imageID,                      (count / maxIndices) + 1,                      (count % maxIndices));  }/********************************************************************//* DeftemplateCConstructReference: Writes the C code representation *//*   of a reference to a deftemplate data structure.                *//********************************************************************/globle void DeftemplateCConstructReference(  void *theEnv,  FILE *theFile,  void *vTheTemplate,  int imageID,  int maxIndices)  {   struct deftemplate *theTemplate = (struct deftemplate *) vTheTemplate;   if (theTemplate == NULL)     { fprintf(theFile,"NULL"); }   else     {      fprintf(theFile,"&%s%d_%ld[%ld]",ConstructPrefix(DeftemplateData(theEnv)->DeftemplateCodeItem),                      imageID,                      (theTemplate->header.bsaveID / maxIndices) + 1,                      theTemplate->header.bsaveID % maxIndices);     }  }  /*******************************************//* InitDeftemplateCode: Writes out runtime *//*   initialization code for deftemplates. *//*******************************************/#if IBM_TBC#pragma argsused#endifstatic void InitDeftemplateCode(  void *theEnv,  FILE *initFP,  int imageID,  int maxIndices)  {#if MAC_MCW || IBM_MCW || MAC_XCD#pragma unused(maxIndices)#endif   fprintf(initFP,"   DeftemplateRunTimeInitialize(theEnv);\n");  }#endif /* DEFTEMPLATE_CONSTRUCT && CONSTRUCT_COMPILER && (! RUN_TIME) */

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美一区二区三区免费视频| 色先锋aa成人| 91最新地址在线播放| 国产综合色精品一区二区三区| 日本一区二区免费在线| 亚洲国产精品ⅴa在线观看| 久久亚洲免费视频| 中文字幕乱码日本亚洲一区二区 | 69久久99精品久久久久婷婷| 欧洲一区二区av| 色噜噜狠狠一区二区三区果冻| av一区二区三区在线| 成人av免费网站| 欧美日韩一级二级三级| 日韩午夜精品电影| 国产精品三级av| 久久99精品久久久久久 | 99国产精品国产精品久久| 亚洲美女偷拍久久| 日本在线不卡一区| 成人看片黄a免费看在线| 在线精品亚洲一区二区不卡| 欧美一区二区久久| 亚洲欧美在线视频| 青椒成人免费视频| av不卡一区二区三区| 欧美电影免费观看高清完整版 | 蜜臀久久99精品久久久久宅男 | 一区二区三区免费在线观看| 激情六月婷婷久久| 欧美人成免费网站| 亚洲在线视频免费观看| 成人性生交大片免费| 久久午夜色播影院免费高清| 天使萌一区二区三区免费观看| 一本色道久久综合亚洲精品按摩| 久久久av毛片精品| 麻豆国产精品官网| 日韩欧美一级特黄在线播放| 午夜精品久久久久久久99樱桃| 91黄色小视频| 午夜日韩在线观看| 在线不卡的av| 日韩精品1区2区3区| 欧美高清性hdvideosex| 日本大胆欧美人术艺术动态| 欧美精选在线播放| 奇米精品一区二区三区四区 | 亚洲高清三级视频| 欧美国产1区2区| 精品美女一区二区| 欧美丰满少妇xxxxx高潮对白| 韩国一区二区视频| 亚洲一二三四区| 亚洲欧美偷拍三级| 欧美激情一区二区三区蜜桃视频| 91精品国产综合久久久久久久| 色婷婷国产精品综合在线观看| 高清国产午夜精品久久久久久| 久久99精品国产.久久久久 | 欧美国产激情一区二区三区蜜月| 欧美一级在线视频| eeuss鲁一区二区三区| 国产午夜亚洲精品理论片色戒| 国产成人av一区二区| 亚洲成a人片综合在线| 国产精品毛片无遮挡高清| 欧美日韩国产另类不卡| 国产凹凸在线观看一区二区| 日韩 欧美一区二区三区| 亚洲手机成人高清视频| 久久综合视频网| 日韩欧美国产三级电影视频| 欧美性xxxxx极品少妇| 不卡欧美aaaaa| 成人性视频免费网站| 欧美aaaaaa午夜精品| 调教+趴+乳夹+国产+精品| 亚洲欧美日韩在线不卡| 亚洲欧洲日产国码二区| 国产免费观看久久| 久久久激情视频| 国产农村妇女毛片精品久久麻豆| 精品sm捆绑视频| 久久久久久久久岛国免费| 欧美成人艳星乳罩| 国产精品福利影院| 日韩欧美亚洲国产另类 | 欧美大片日本大片免费观看| 激情综合色综合久久综合| 日本一区二区三区四区| av不卡免费在线观看| 亚洲成av人片在www色猫咪| 这里是久久伊人| 精品国产凹凸成av人网站| 欧美一级欧美三级| 久久只精品国产| 中文字幕欧美国产| 亚洲麻豆国产自偷在线| 亚洲精品美国一| 免费成人在线影院| 国产一区在线精品| 色综合久久综合中文综合网| 777奇米四色成人影色区| www国产亚洲精品久久麻豆| 中文字幕欧美一区| 三级不卡在线观看| 国产91丝袜在线播放九色| 色欧美88888久久久久久影院| 欧美视频一区二| 国产精品美女久久久久aⅴ国产馆 国产精品美女久久久久av爽李琼 国产精品美女久久久久高潮 | 欧美二区三区的天堂| 国产精品国产馆在线真实露脸 | 欧美日韩高清不卡| 国产精品妹子av| 精品亚洲国内自在自线福利| 一本色道久久综合狠狠躁的推荐| 91精品国产综合久久蜜臀| 亚洲国产成人一区二区三区| 男人的天堂亚洲一区| 欧美色图在线观看| 久久九九国产精品| 免费欧美日韩国产三级电影| 色欧美日韩亚洲| 亚洲欧美偷拍另类a∨色屁股| 国产精品一区二区免费不卡 | 免费看黄色91| 欧美群妇大交群的观看方式| 亚洲精品亚洲人成人网| eeuss国产一区二区三区| 国产精品午夜久久| 懂色av一区二区在线播放| 久久精品亚洲精品国产欧美| 经典一区二区三区| 精品99一区二区三区| 国产成人在线视频免费播放| 国产午夜一区二区三区| 成人免费的视频| 亚洲精品v日韩精品| 在线免费观看视频一区| 日韩电影在线免费| 欧美精品一区视频| 国产成人免费在线| 亚洲欧洲中文日韩久久av乱码| 在线看不卡av| 久久成人免费日本黄色| 中文字幕一区av| 欧美巨大另类极品videosbest | 日韩美女视频一区二区 | 国产一区二区美女诱惑| 亚洲欧美视频在线观看视频| 欧美高清www午色夜在线视频| 久久精品国产久精国产| 中文字幕国产一区| 3atv一区二区三区| 一本久久a久久免费精品不卡| 美女任你摸久久| 亚洲美女偷拍久久| 国产人妖乱国产精品人妖| 欧美日韩中文另类| 91一区二区三区在线播放| 国内精品自线一区二区三区视频| 亚洲综合在线电影| 国产欧美精品区一区二区三区| 欧美一区二区三区思思人| 99国产精品视频免费观看| 国产一区二区三区香蕉| 三级一区在线视频先锋| 一区二区成人在线| 亚洲素人一区二区| 欧美高清在线一区二区| 久久久99精品免费观看不卡| 精品少妇一区二区三区免费观看 | 国产美女精品一区二区三区| 婷婷成人激情在线网| 亚洲图片欧美视频| 丝袜美腿亚洲综合| 日本大胆欧美人术艺术动态| 亚洲不卡在线观看| 五月激情综合婷婷| 婷婷一区二区三区| 裸体在线国模精品偷拍| 蜜臀av在线播放一区二区三区| 婷婷综合久久一区二区三区| 天堂久久一区二区三区| 久久精品久久综合| 国产成人免费视| 色综合 综合色| 欧美一区二区精品| 国产精品私人影院| 亚洲精品老司机| 青青草原综合久久大伊人精品优势| 久久精品国产精品亚洲综合| 成人精品一区二区三区四区| 91免费看`日韩一区二区| 欧美一区二区三区视频在线 | 91久久奴性调教| 欧美va日韩va| 午夜视频一区二区| 成人黄色在线看|