#include "international.hh"
#include "main.hh"
#include "source-file.hh"
-#include "source.hh"
+#include "sources.hh"
#include "warn.hh"
#ifndef YY_BUF_SIZE
-/*
- source.hh -- part of LilyPond
-
- (c) 1997--2007 Jan Nieuwenhuizen <janneke@gnu.org>
-*/
-
-#ifndef SOURCE_HH
-#define SOURCE_HH
-
-#include "flower-proto.hh"
-#include "std-vector.hh"
-
-/* A set of sourcefiles. */
-class Sources
-{
- Sources (Sources const &);
- vector<Source_file*> sourcefiles_;
-
-public:
- Sources ();
- ~Sources ();
-
- Source_file *get_file (string *file_name);
- Source_file *get_sourcefile (char const *);
- void add (Source_file *sourcefile);
- void set_path (File_path *);
-
- const File_path *path_;
-};
-
-#endif /* SOURCE_HH */
+#error
--- /dev/null
+/*
+ sources.hh -- part of LilyPond
+
+ (c) 1997--2007 Jan Nieuwenhuizen <janneke@gnu.org>
+*/
+
+#ifndef SOURCES_HH
+#define SOURCES_HH
+
+#include "flower-proto.hh"
+#include "std-vector.hh"
+
+class Sources
+{
+ Sources (Sources const &);
+ vector<Source_file*> sourcefiles_;
+
+public:
+ Sources ();
+ ~Sources ();
+
+ Source_file *get_file (string *file_name);
+ Source_file *get_sourcefile (char const *);
+ void add (Source_file *sourcefile);
+ void set_path (File_path *);
+
+ const File_path *path_;
+};
+
+#endif /* SOURCE_HH */
#include "international.hh"
#include "source-file.hh"
-#include "source.hh"
+#include "sources.hh"
#include "warn.hh"
Input::Input (Input const &i)
#include "ly-module.hh"
#include "main.hh"
#include "program-option.hh"
-#include "source.hh"
+#include "sources.hh"
#include "warn.hh"
/* Do not append `!' suffix, since 1st argument is not modified. */
#include "paper-book.hh"
#include "parser.hh"
#include "score.hh"
-#include "source.hh"
+#include "sources.hh"
#include "text-metrics.hh"
#include "warn.hh"
-/*
- source.cc -- implement Sources
-
- source file of the LilyPond music typesetter
-
- (c) 1997--2007 Han-Wen Nienhuys <hanwen@xs4all.nl>
-*/
-
-#include "source.hh"
-
-#include "source-file.hh"
-#include "file-path.hh"
-
-Sources::Sources ()
-{
- path_ = 0;
-}
-
-
-Sources::Sources (Sources const &)
-{
- assert (false);
-}
-
-
-void
-Sources::set_path (File_path *f)
-{
- path_ = f;
-}
-
-/**
- open a file
-
- File_string the file to be opened, name might be changed if it is
- found in a search path.
-*/
-Source_file *
-Sources::get_file (string *file_string) //UGH
-{
- if (*file_string != "-" && path_)
- {
- string file_string_o = path_->find (*file_string);
- if ((file_string_o == "") && (*file_string != ""))
- return 0;
- *file_string = file_string_o;
- }
- Source_file *f = new Source_file (*file_string);
- add (f);
- return f;
-}
-
-void
-Sources::add (Source_file *sourcefile)
-{
- sourcefiles_.push_back (sourcefile);
-}
-
-Sources::~Sources ()
-{
- for (vsize i = 0; i < sourcefiles_.size (); i++)
- {
- sourcefiles_[i]->unprotect ();
- }
-}
-
--- /dev/null
+/*
+ source.cc -- implement Sources
+
+ source file of the LilyPond music typesetter
+
+ (c) 1997--2007 Han-Wen Nienhuys <hanwen@xs4all.nl>
+*/
+
+#include "sources.hh"
+
+#include "source-file.hh"
+#include "file-path.hh"
+
+Sources::Sources ()
+{
+ path_ = 0;
+}
+
+
+Sources::Sources (Sources const &)
+{
+ assert (false);
+}
+
+
+void
+Sources::set_path (File_path *f)
+{
+ path_ = f;
+}
+
+/**
+ open a file
+
+ File_string the file to be opened, name might be changed if it is
+ found in a search path.
+*/
+Source_file *
+Sources::get_file (string *file_string) //UGH
+{
+ if (*file_string != "-" && path_)
+ {
+ string file_string_o = path_->find (*file_string);
+ if ((file_string_o == "") && (*file_string != ""))
+ return 0;
+ *file_string = file_string_o;
+ }
+ Source_file *f = new Source_file (*file_string);
+ add (f);
+ return f;
+}
+
+void
+Sources::add (Source_file *sourcefile)
+{
+ sourcefiles_.push_back (sourcefile);
+}
+
+Sources::~Sources ()
+{
+ for (vsize i = 0; i < sourcefiles_.size (); i++)
+ {
+ sourcefiles_[i]->unprotect ();
+ }
+}
+