~ubuntu-branches/ubuntu/quantal/vala/quantal

« back to all changes in this revision

Viewing changes to vala/valasourcefile.vala

  • Committer: Bazaar Package Importer
  • Author(s): Michael Terry
  • Date: 2011-01-18 09:51:15 UTC
  • mfrom: (1.5.14 upstream)
  • Revision ID: james.westby@ubuntu.com-20110118095115-r2jr7c63lr0jzj0y
Tags: 0.11.4-0ubuntu1
New upstream release

Show diffs side-by-side

added added

removed removed

Lines of Context:
178
178
                        var basename = Path.get_basename (filename);
179
179
                        var subdir = filename.substring (context.basedir.length, filename.length - context.basedir.length - basename.length);
180
180
                        while (subdir[0] == '/') {
181
 
                                subdir = subdir.offset (1);
 
181
                                subdir = subdir.substring (1);
182
182
                        }
183
183
                        return subdir;
184
184
                }
193
193
        }
194
194
 
195
195
        private string get_basename () {
196
 
                long dot = filename.pointer_to_offset (filename.rchr (-1, '.'));
 
196
                long dot = (long) ((char*) filename.rchr (-1, '.') - (char*) filename);
197
197
                return Path.get_basename (filename.substring (0, dot));
198
198
        }
199
199