Changeset c1dafea for libcfa/src
- Timestamp:
 - Aug 31, 2021, 1:49:10 AM (4 years ago)
 - Branches:
 - ADT, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, pthread-emulation, qualifiedEnum
 - Children:
 - 82820da
 - Parents:
 - 1e05e09
 - git-author:
 - Jacob Prud'homme <jafprudhomme@…> (08/03/21 01:57:08)
 - git-committer:
 - Jacob Prud'homme <jafprudhomme@…> (08/31/21 01:49:10)
 - File:
 - 
      
- 1 edited
 
- 
          
  libcfa/src/parseconfig.cfa (modified) (3 diffs)
 
 
Legend:
- Unmodified
 - Added
 - Removed
 
- 
      
libcfa/src/parseconfig.cfa
r1e05e09 rc1dafea 34 34 kvp.data = alloc( size ); 35 35 } 36 /*37 void ?{}( KVPairs & kvp, KVPairs val ) with( val ) { // copy, deep38 kvp.[ size, max_size ] = [ size, max_size ];39 kvp.data = alloc( size, data );40 }41 */42 36 void ^?{}( KVPairs & kvp ) with ( kvp ) { // destructor 43 37 free( data ); … … 73 67 open( in, config_file ); // open the configuration file for input 74 68 75 while () { // parameter names can appear in any order69 while () { // parameter names can appear in any order 76 70 char key[64]; 77 71 char value[256]; 78 72 79 if ( comments( in, key ) ) break; // eof ? 80 // Must add check to see if we have already read in a key-value pair, once we switch to using hash table as intermediate storage 73 // Must add check to see if already read in a key-value pair, 74 // once we switch to using hash table as intermediate storage 75 if ( comments( in, key ) ) break; // eof ? 81 76 in | value; 82 77 … … 84 79 85 80 if ( eof( in ) ) break; 86 in | nl; // ignore remainder of line81 in | nl; // ignore remainder of line 87 82 } // for 88 83 } catch( Open_Failure * ex; ex->istream == &in ) {  
  Note:
 See   TracChangeset
 for help on using the changeset viewer.