Left: | ||
Right: |
LEFT | RIGHT |
---|---|
1 /* | 1 /* |
2 This file is part of LilyPond, the GNU music typesetter. | 2 This file is part of LilyPond, the GNU music typesetter. |
3 | 3 |
4 Copyright (C) 1997--2019 Han-Wen Nienhuys <hanwen@xs4all.nl> | 4 Copyright (C) 1997--2019 Han-Wen Nienhuys <hanwen@xs4all.nl> |
5 Jan Nieuwenhuizen <janneke@gnu.org> | 5 Jan Nieuwenhuizen <janneke@gnu.org> |
6 | 6 |
7 LilyPond is free software: you can redistribute it and/or modify | 7 LilyPond is free software: you can redistribute it and/or modify |
8 it under the terms of the GNU General Public License as published by | 8 it under the terms of the GNU General Public License as published by |
9 the Free Software Foundation, either version 3 of the License, or | 9 the Free Software Foundation, either version 3 of the License, or |
10 (at your option) any later version. | 10 (at your option) any later version. |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
112 | 112 |
113 return s; | 113 return s; |
114 } | 114 } |
115 | 115 |
116 string | 116 string |
117 File_name::file_part () const | 117 File_name::file_part () const |
118 { | 118 { |
119 string s = base_; | 119 string s = base_; |
120 | 120 |
121 if (!ext_.empty ()) | 121 if (!ext_.empty ()) |
122 { | 122 s += EXTSEP + ext_; |
123 s += EXTSEP; | |
124 s += ext_; | |
lemzwerg
2020/01/11 22:20:34
any reason to use two lines? In other files you u
Dan Eble
2020/01/12 00:20:03
s += EXTSEP; // append a char to s
s += ext_; // a
| |
125 } | |
126 | 123 |
127 return s; | 124 return s; |
128 } | 125 } |
129 | 126 |
130 string | 127 string |
131 File_name::to_string () const | 128 File_name::to_string () const |
132 { | 129 { |
133 string d = dir_part (); | 130 string d = dir_part (); |
134 string f = file_part (); | 131 string f = file_part (); |
135 | 132 |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
215 new_components.push_back ("."); | 212 new_components.push_back ("."); |
216 } | 213 } |
217 } | 214 } |
218 else | 215 else |
219 new_components.push_back (components[i]); | 216 new_components.push_back (components[i]); |
220 } | 217 } |
221 | 218 |
222 c.dir_ = string_join (new_components, "/"); | 219 c.dir_ = string_join (new_components, "/"); |
223 return c; | 220 return c; |
224 } | 221 } |
LEFT | RIGHT |