Changeset 0cfa768 for libcfa/src
- Timestamp:
- Aug 31, 2021, 1:49:10 AM (3 years ago)
- Branches:
- ADT, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, pthread-emulation, qualifiedEnum
- Children:
- 09fda91
- Parents:
- a0e142f
- git-author:
- Jacob Prud'homme <jafprudhomme@…> (08/03/21 00:18:19)
- git-committer:
- Jacob Prud'homme <jafprudhomme@…> (08/31/21 01:49:10)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/parseconfig.cfa
ra0e142f r0cfa768 128 128 // Right now doesn't handle duplicate keys. Should use hashmap for that 129 129 char c; 130 StringBuilder key_sb; 131 StringBuilder value_sb; 130 [1024] char key; 131 [1024] char value; 132 //StringBuilder key_sb; 133 //StringBuilder value_sb; 132 134 133 135 // Doesn't handle comments 136 in | key; 137 /* 134 138 while () { 135 139 in | c; … … 141 145 } 142 146 } 143 144 * char key = alloc( key_sb.size ); 145 strcpy( key, key_sb.string ); 147 */ 148 149 //* char key = alloc( key_sb.size ); 150 //strcpy( key, key_sb.string ); 146 151 147 152 // Doesn't handle comments 153 in | value; 154 /* 148 155 while () { 149 156 in | c; … … 151 158 add_char( value_sb, c ); 152 159 } 153 154 * char value = alloc( value_sb.size ); 155 strcpy( value, value_sb.string ); 160 */ 161 162 //* char value = alloc( value_sb.size ); 163 //strcpy( value, value_sb.string ); 156 164 157 165 add_kv_pair( kv_pairs, key, value );
Note: See TracChangeset
for help on using the changeset viewer.