MCPcopy Create free account
hub / github.com/boostorg/build / get_argument_index

Function get_argument_index

v2/engine/function.c:350–392  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

348 */
349
350static int get_argument_index( char const * s )
351{
352 if ( s[ 0 ] != '\0')
353 {
354 if ( s[ 1 ] == '\0' )
355 {
356 switch ( s[ 0 ] )
357 {
358 case '<': return 0;
359 case '>': return 1;
360
361 case '1':
362 case '2':
363 case '3':
364 case '4':
365 case '5':
366 case '6':
367 case '7':
368 case '8':
369 case '9':
370 return s[ 0 ] - '1';
371 }
372 }
373 else if ( s[ 0 ] == '1' && s[ 2 ] == '\0' )
374 {
375 switch( s[ 1 ] )
376 {
377 case '0':
378 case '1':
379 case '2':
380 case '3':
381 case '4':
382 case '5':
383 case '6':
384 case '7':
385 case '8':
386 case '9':
387 return s[ 1 ] - '0' + 10 - 1;
388 }
389 }
390 }
391 return -1;
392}
393
394static LIST * function_get_named_variable( JAM_FUNCTION * function,
395 FRAME * frame, OBJECT * name )

Callers 2

var_parse_var_compileFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected