GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — stepcode/src/express/alg.c at develop · stepcode/stepcode Expand file tree/ Copy pathalg.cMore file actions 97 lines (87 loc) · 2.54 KB / Copy pathalg.cFile metadata and controls97 lines (87 loc) · 2.54 KB 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 /** ********************************************************************** ** Module: Algorithm \file alg.c ** This module implements the Algorithm abstraction. An ** algorithm can be a procedure, a function, or a rule. It consists ** of a name, a return type (for functions and rules), a list of ** formal parameters, and a list of statements (body). ** Constants: ** ALGORITHM_NULL - the null algorithm ** ************************************************************************/ /* * This code was developed with the support of the United States Government, * and is not subject to copyright. * * $Log: alg.c,v $ * Revision 1.5 1997/01/21 19:19:51 dar * made C++ compatible * * Revision 1.4 1995/04/05 15:11:02 clark * CADDETC preval * * Revision 1.3 1994/11/22 18:32:39 clark * Part 11 IS; group reference * * Revision 1.2 1993/10/15 18:48:48 libes * CADDETC certified * * Revision 1.5 1993/02/16 03:13:56 libes * add Where type * * Revision 1.4 1992/08/18 17:13:43 libes * rm'd extraneous error messages * * Revision 1.3 1992/06/08 18:06:57 libes * prettied up interface to print_objects_when_running */ #include "express/alg.h" #include "express/object.h" #include "express/schema.h" struct freelist_head ALG_fl; struct freelist_head FUNC_fl; struct freelist_head RULE_fl; struct freelist_head PROC_fl; struct freelist_head WHERE_fl; Scope ALGcreate( char type ) { Scope s = SCOPEcreate( type ); switch( type ) { case OBJ_PROCEDURE: s->u.proc = PROC_new(); break; case OBJ_FUNCTION: s->u.func = FUNC_new(); break; case OBJ_RULE: s->u.rule = RULE_new(); break; } return s; } /* ** Procedure: ALGinitialize ** Parameters: -- none -- ** Returns: void ** Description: Initialize the Algorithm module. */ /** Initialize the Algorithm module. */ void ALGinitialize( void ) { } void ALGput_full_text( Scope s, int start, int end ) { switch( s->type ) { case OBJ_FUNCTION: s->u.func->text.filename = s->symbol.filename; s->u.func->text.start = start; s->u.func->text.end = end; break; case OBJ_PROCEDURE: s->u.proc->text.filename = s->symbol.filename; s->u.proc->text.start = start; s->u.proc->text.end = end; break; case OBJ_RULE: s->u.rule->text.filename = s->symbol.filename; s->u.rule->text.start = start; s->u.rule->text.end = end; break; } } |
| You are visitor 01402520 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |