]> git.donarmstrong.com Git - lilypond.git/blob - src/source.cc
release: 0.0.27
[lilypond.git] / src / source.cc
1 //
2 // source.cc
3 //
4
5 #include <assert.h>
6
7 #include "string.hh"
8 #include "proto.hh"
9 #include "plist.hh"
10
11 #include "sourcefile.hh"
12 #include "source.hh"
13
14 Source::Source()
15 {
16 }
17
18 Source::~Source()
19 {
20 }
21
22 void
23 Source::add( Source_file* sourcefile_p )
24 {
25     sourcefile_p_iplist_m.bottom().add( sourcefile_p );
26 }
27
28 Source_file*
29 Source::sourcefile_l( char const* ch_c_l )
30 {
31     PCursor<Source_file*> sourcefile_p_pcur( sourcefile_p_iplist_m.top() );
32     for ( ; sourcefile_p_pcur.ok(); sourcefile_p_pcur++ )
33         if ( sourcefile_p_pcur->in_b( ch_c_l ) )        
34             return *sourcefile_p_pcur;
35     return 0;
36 }