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

Function is_same_file

src/engine/debugger.cpp:356–377  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

354}
355
356static int is_same_file( OBJECT * file1, OBJECT * file2 )
357{
358 OBJECT * absolute1 = make_absolute_path( file1 );
359 OBJECT * absolute2 = make_absolute_path( file2 );
360 OBJECT * norm1 = path_as_key( absolute1 );
361 OBJECT * norm2 = path_as_key( absolute2 );
362 OBJECT * base1 = get_filename( file1 );
363 OBJECT * base2 = get_filename( file2 );
364 OBJECT * normbase1 = path_as_key( base1 );
365 OBJECT * normbase2 = path_as_key( base2 );
366 int result = object_equal( norm1, norm2 ) ||
367 ( object_equal( base1, file1 ) && object_equal( normbase1, normbase2 ) );
368 object_free( absolute1 );
369 object_free( absolute2 );
370 object_free( norm1 );
371 object_free( norm2 );
372 object_free( base1 );
373 object_free( base2 );
374 object_free( normbase1 );
375 object_free( normbase2 );
376 return result;
377}
378
379static void debug_print_source( OBJECT * filename, int line )
380{

Callers 1

handle_line_breakpointFunction · 0.85

Calls 5

make_absolute_pathFunction · 0.85
get_filenameFunction · 0.85
object_equalFunction · 0.85
object_freeFunction · 0.85
path_as_keyFunction · 0.70

Tested by

no test coverage detected