@@ -182,7 +182,6 @@ static const char* restrict function_stack_start;
182
182
183
183
// Variables and needed by functions.c defined in runtime.c
184
184
static void init_stack (void );
185
- static void expand_stack (void );
186
185
static STRING show_object (const ANY object , const _Bool );
187
186
static void _Noreturn __attribute__((format (printf , 1 , 2 ))) throw_error_fmt (const char * restrict const , ...);
188
187
static void _Noreturn throw_error (const char * restrict const );
@@ -223,7 +222,6 @@ static ANY box_DICT(DICT);
223
222
static NUMBER radians_to_degrees (NUMBER );
224
223
static NUMBER degrees_to_radians (NUMBER );
225
224
226
- static void init (int , char * * );
227
225
static void cleanup (void );
228
226
static void push (ANY );
229
227
static ANY pop (void );
@@ -233,7 +231,6 @@ static int stack_length(void);
233
231
234
232
// Builtin functions needed by compiled source file defined in functions.c
235
233
static DICT ___insert (STRING , ANY , DICT );
236
- static DICT ___emptyDdict (void );
237
234
static LIST ___empty (void );
238
235
static ANY ___if (BOOLEAN , ANY , ANY );
239
236
static void ___put (ANY );
@@ -281,7 +278,6 @@ static NUMBER ___stringDlength(STRING);
281
278
static STRING ___substring (NUMBER , NUMBER , STRING );
282
279
static STRING ___input (void );
283
280
static IO ___open (STRING , STRING );
284
- static void ___with (STRING , STRING , BLOCK );
285
281
static void ___close (IO );
286
282
static NUMBER ___number (STRING );
287
283
static STRING ___path (void );
@@ -296,8 +292,6 @@ static NUMBER ___floor(NUMBER);
296
292
static NUMBER ___round (NUMBER );
297
293
static NUMBER ___ceiling (NUMBER );
298
294
static void ___error (STRING );
299
- static LIST ___filter (BLOCK , LIST );
300
- static ANY ___index (NUMBER , LIST );
301
295
//static BLOCK ___precompute(BLOCK);
302
296
static void ___wait (NUMBER );
303
297
static LIST ___split (STRING , STRING );
@@ -343,7 +337,7 @@ static size_t debug_lineno = 0;
343
337
static int _argc ;
344
338
static char * * _argv ;
345
339
346
- void fn0 ();
340
+ static void fn0 ();
347
341
348
342
int main (int argc , char * * argv )
349
343
{
@@ -622,6 +616,7 @@ static STRING show_object (const ANY object, const _Bool raw_strings)
622
616
{
623
617
case NIL : throw_error ("This shouldn't happen" );
624
618
break ;
619
+ case dict : // TODO
625
620
case number : sprintf (buffer , "%.14g" , object .number );
626
621
buffer += strlen (buffer );
627
622
break ;
@@ -1174,7 +1169,6 @@ static NUMBER ___modulo(NUMBER a, NUMBER b) { return b - a * floor(b / a); }
1174
1169
static NUMBER ___sqrt (NUMBER a ) { return sqrt (a ); }
1175
1170
static NUMBER ___random (NUMBER low , NUMBER high )
1176
1171
{
1177
- NUMBER step = 1 ;
1178
1172
if unlikely ((high - low ) < 0 ) goto invalid_range ;
1179
1173
else if (high - low < 1 ) return low ;
1180
1174
// This is not cryptographically secure btw.
@@ -1818,7 +1812,6 @@ static void invalid_jump(void* env)
1818
1812
1819
1813
static void oh_no (void * env )
1820
1814
{
1821
- char a ;
1822
1815
longjmp (* (jmp_buf * )env , 1 );
1823
1816
}
1824
1817
@@ -1918,7 +1911,7 @@ static ANY ___get(STRING key, DICT d)
1918
1911
1919
1912
if (diff == 0 ) return d -> value ;
1920
1913
else if (diff > 0 ) return ___get (key , d -> child1 );
1921
- else if ( diff < 0 ) return ___get (key , d -> child2 );
1914
+ else return ___get (key , d -> child2 );
1922
1915
}
1923
1916
1924
1917
// ---------- ACTUAL PROGRAM ----------
0 commit comments