~ubuntu-branches/ubuntu/jaunty/aspectc++/jaunty

« back to all changes in this revision

Viewing changes to Puma/gen-release/step2/src/CSourceInfo.cc

  • Committer: Bazaar Package Importer
  • Author(s): Reinhard Tartler
  • Date: 2008-07-07 14:41:02 UTC
  • mfrom: (1.1.3 upstream) (6.1.1 lenny)
  • Revision ID: james.westby@ubuntu.com-20080707144102-lzml7t07f3sl00r5
Tags: 1.0pre4~svn.20080711-1
* new upstream snapshot.
* include all upstream documentation. Clarifying emails regarding
  licensing has been included into debian/copyright.
* reformat description following recomendations of
  http://www.debian.org/doc/debian-policy/ch-controlfields.html#s-f-Description
  (Closes: #480316)

Show diffs side-by-side

added added

removed removed

Lines of Context:
53
53
  return StartToken ()->token ()->location ().line (); 
54
54
}
55
55
 
 
56
int CSourceInfo::Column () const { 
 
57
  if (! StartToken ()) 
 
58
    return 0;
 
59
  return StartToken ()->token ()->location ().column (); 
 
60
}
 
61
 
56
62
bool CSourceInfo::operator ==(const Token *token) const {
57
63
  if (StartToken () && StartToken ()->token () == token) 
58
64
    return true;
80
86
bool CSourceInfo::operator ==(const CSourceInfo &info) const {
81
87
  if (! (*this == info.StartToken ()->token ()))
82
88
    if (Line () != info.Line () || 
 
89
        Column () != info.Column () || 
83
90
        ! FileName () || ! info.FileName () ||
84
91
        strcmp (FileName (), info.FileName ()) != 0)
85
92
      return false; 
89
96
bool CSourceInfo::operator <(const CSourceInfo &info) const {
90
97
  if (Line () >= info.Line ()) 
91
98
    return false;
 
99
  if (Column () >= info.Column ()) 
 
100
    return false;
92
101
  if (! FileName () || ! info.FileName ()) 
93
102
    return false;
94
103
  if (strcmp (FileName (), info.FileName ()) != 0) 
99
108
bool CSourceInfo::operator >(const CSourceInfo &info) const {
100
109
  if (Line () <= info.Line ()) 
101
110
    return false;
 
111
  if (Column () <= info.Column ()) 
 
112
    return false;
102
113
  if (! FileName () || ! info.FileName ()) 
103
114
    return false;
104
115
  if (strcmp (FileName (), info.FileName ()) != 0)